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
 help me, how to save layers one by one

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
atwisahs Posted - Mar 22 2021 : 19:23:30
I have a wallpaper and 3 layers, how to save one by one layers in file jpeg


2   L A T E S T    R E P L I E S    (Newest First)
atwisahs Posted - Mar 23 2021 : 00:41:40
thanks
xequte Posted - Mar 22 2021 : 21:45:29
Hi

There are multiple methods, but the easiest is just to write the layer bitmap:

// Prompt user to save current layer as an image
fn := ImageEnView1.IO.ExecuteSaveDialog();
if fn <> '' then
  ImageEnView1.CurrentLayer.Bitmap.Write( fn );



If you want to iterate through all the layers, you could use:

for i := 1 {!!!} to ImageEnView1.LayersCount - 1 do
  if ImageEnView1.Layers[i].Selected then
    ImageEnView1.Layers[i].Bitmap.Write( format( 'D:\Layer%d.jpg', [i] );


Nigel
Xequte Software
www.imageen.com