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
 GetTIEBitmap and ReleaseBitmap

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
AndNit Posted - Oct 23 2023 : 19:55:47
Hello,

I don't know how to use the GetTIEBitmap and ReleaseBitmap functions

I need that when clicking on the thumbnail in my TimageEnMViewer the image is loaded into a TimageEnViewer. With this image loaded, I will add some layers to it. After adding these
layers, I need to update my TimageEnMViewer with the updated image in the TimageEnViewer. How should I proceed in this scenario?

I've already looked at the help, but I really can't reproduce it.

https://www.imageen.com/help/index.php?topic=TImageEnMView.GetTIEBitmap&m=10

Thanks.
2   L A T E S T    R E P L I E S    (Newest First)
AndNit Posted - Oct 25 2023 : 09:32:20
Oh you taught my friend... thank you very much.
xequte Posted - Oct 25 2023 : 02:16:25
Hi

Layers are external to the bitmap, so to see them in the TImageEnMView you need to either:

1. Merge the layers into the bitmap and update the TImageEnMView
2. Save the ImageEnView content (image + layers) to a stream or file and replace the file in the TImageEnMView (by loading from the stream or file).

This is how to do method 1...

//Set idx as the selected image

// Assign the current image to an ImageEnView
bmp := ImageEnMView1.GetTIEBitmap( idx ); 
ImageEnView1.Assign( bmp );
ImageEnMView1.ReleaseBitmap(idx, False);

// Merge layers in ImageEnView and assign back to MView
ImageEnView1.LayersMergeAll(); 
ImageEnMView1.SetImage( idx, ImageEnView1.IEBitmap );


Nigel
Xequte Software
www.imageen.com