ImageEn, unit imageenview

TImageEnView.PolySel

TImageEnView.PolySel

Declaration

property PolySel[Index: Integer]: TPoint;

Description

Returns a point of the current polygonal selection. The point is specified in bitmap coordinates.

Note:
If there are multiple selections, they will be separated by the Point($FFFFF, $FFFFF)
PolySel will only be valid if a polygonal/vectorial selection has been made, e.g. by using miSelectPolygon. A vectorial selection is a series of lines forming a vectorial selection shape. It is not valid for non-vectorial selections, i.e. selections that are represented by a bitmap, e.g. when using SelectColors or SelectNonAlpha. For non-vectorial/bitmap selections use IsPointInsideSelection to determine whether specific pixels are selected.
To create a polygonal selection in code see AddSelPoint

Read-only

Example

var
  myPolySelArray: array of TPoint;
  i: Integer;
begin
  // Create an array of TPoints of the polygon selection in a TImageEnView
  SetLength( myPolySelArray, ImageEnView1.PolySelCount );
  for i := 0 to ImageEnView1.PolySelCount - 1 do
    myPolySelArray[ i ] := ImageEnView1.PolySel[ i ];
end;

See Also

PolySelCount
PolySelPoints
AddSelPoint