ImageEn, unit ievision

TIEVisionObjectsFinder.mergeRects

TIEVisionObjectsFinder.mergeRects


Declaration

function mergeRects(name1: PAnsiChar; name2: PAnsiChar): TIEVisionVectorRect; safecall;


Description

Merges rectangles that intersect of the specified objects detectors.

Parameter Description
name1 Name of an object detector.
name2 Name of an object detector.


Example

// detect objects
objectsFinder.findIn(image);

// merge intersecting rectangles of "face1" and "face2" detectors
rects := objectsFinder.mergeRects("face1", "face2");

// loop among rectangles
for i := 0 to rects.size-1 do
begin
  ImageEnView1.ObjPenWidth[-1] := 2;
  with rects.getRect(i) do
  begin
    ... do something with the rectangle coordinates and size
  end;
end;


See Also

- findIn
- getFoundRect
- getFoundRectCount
- mergeAllRects