If I called once TImageDraw.Draw method then the PaintControlPoints is called several times, and why? This is normal?
constructor TImageDraw.Create(AOwner: TImgView32);
begin
//Create layer object
FControlLayer := TPositionedLayer.Create(AOwner.Layers);
FControlLayer.LayerOptions := LOB_VISIBLE;
FControlLayer.OnPaint := PaintControlPoints;
end;
procedure TImageDraw.PaintControlPoints(Sender: TObject; Buffer: TBitmap32);
begin
//Draw control points
//.....
end;
procedure TImageDraw.Draw;
begin
//Draw something
//.....
FControlLayer.Changed;
end;