ImageEn for Delphi and C++ Builder ImageEn for Delphi and C++ Builder

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 Iterate ieVect polygon objects - get/set X,Y

Note: You must be registered in order to post a reply.
To register, click here. Registration is FREE!

View 
UserName:
Password:
Format  Bold Italicized Underline  Align Left Centered Align Right  Horizontal Rule  Insert Hyperlink   Browse for an image to attach to your post Browse for a zip to attach to your post Insert Code  Insert Quote Insert List
   
Message 

 

Emoji
Smile [:)] Big Smile [:D] Cool [8D] Blush [:I]
Tongue [:P] Evil [):] Wink [;)] Black Eye [B)]
Frown [:(] Shocked [:0] Angry [:(!] Sleepy [|)]
Kisses [:X] Approve [^] Disapprove [V] Question [?]

 
Check here to subscribe to this topic.
   

T O P I C    R E V I E W
andyhill Posted - Apr 23 2016 : 20:46:06
Please show me how to iterate ImageEnVect Polygon Objects reading each objects Point X,Y values and changing and saving the Point X,Y values.

for i:= 0 to ieVect.ObjectCount-1 do begin
  if ieVect.Object[i] = Polygon then begin
    for j:= 0 to ieVect.Object[i].PointsCount-1 do begin
      ieVect.Object[i].Points[j].X:= ieVect.Object[i].Points[j].X+10;
    end;
  end;
end;

Thanks



Andy
4   L A T E S T    R E P L I E S    (Newest First)
andyhill Posted - Apr 26 2016 : 22:13:31
Thanks, I had expected fetching a TPoint array but I can do it one point at a time if I must.

Andy
xequte Posted - Apr 25 2016 : 23:55:21
Hi Andy,

Please see ObjPolylinePoints:

http://www.imageen.com/help/TImageEnVect.ObjPolylinePoints.html

Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
andyhill Posted - Apr 25 2016 : 17:53:29
Bill, I understand that but how do I get the points ?

GetObjPolylinePoints



Andy
w2m Posted - Apr 25 2016 : 08:56:13
Try:
TImageEnVect.SetObjPolylinePoints

Declaration
procedure SetObjPolylinePoints(hobj: integer; Points: array of TPoint);

Description
SetObjPolylinePoints specifies the points that compose the polyline for the polyline object hobj.
The points are specified in bitmap coordinates.

hobj is the ID of the object. You can also specify IEV_NEXT_INSERTED_OBJECT (-1) which refers to the next object to be inserted or IEV_PREVIOUS_INSERTED_OBJECT (-2) for the last object inserted.

Bill Miller
Adirondack Software & Graphics
Email: w2m@hughes.net
EBook: http://www.imageen.com/ebook/
Custom Commercial ImageEn Development