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

 

ImageEn Forum
Profile    Join    Active Topics    Forum FAQ    Search this forumSearch
Forum membership is Free!  Click Join to sign-up
Username:
Password:
Save Password
Forgot your Password?

 All Forums
 ImageEn Library for Delphi, C++ and .Net
 ImageEn and IEvolution Support Forum
 location of Objects
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

pierrotsc

USA
499 Posts

Posted - Jun 24 2013 :  12:55:02  Show Profile  Reply
Is there a way to memorize the location of ellipses? I need to create registration marks on images I print. When i drop 4 circle on an image (At the corner), i would like to memorize their location. Like that next time I print another image, I can recall the location of the 4 ellipses.

Can it be done?

I was thinking about saving a layer with only the objects inside it and then recall them.
The location can be saved in memory. When the program closes, it is ok to be lost.
Thanks.
P

w2m

USA
1990 Posts

Posted - Jun 24 2013 :  13:21:48  Show Profile  Reply
You could save the object positions (Left and Top) to an ini file then reload them biased on the Left and Top values in the ini file.

iterate through the objects to save the object positions:
ImageEnVect1.ObjLeft[hObj];
ImageEnVect1.ObjTop [hObj];
then restore the object positions by reading
ImageEnVect1.ObjLeft[hObj];
ImageEnVect1.ObjTop [hObj];

You could also save the objects and there positions with SaveToFileIEV, then restore them with LoadFromFileIEV.

You could also save the objects and positions to a memory stream with SaveToStreamIEV and then reload the objects with LoadFromStreamIEV.

William Miller
Adirondack Software & Graphics
Email: w2m@frontiernet.net
EBook: http://www.imageen.com/ebook/
Apprehend: http://www.frontiernet.net/~w2m/index.html
Go to Top of Page

pierrotsc

USA
499 Posts

Posted - Jun 24 2013 :  13:41:41  Show Profile  Reply
Thanks Bill. I like the stream approach. Let me work on that.
P
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: