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
 How to assign Alpha-IEBitmap to TBitmap
 New Topic  Reply to Topic
Author Previous Topic Topic Next Topic  

harry stahl

Germany
62 Posts

Posted - Jun 14 2017 :  11:51:05  Show Profile  Reply
When I open a layer-file, e.g. a PSD File, then The IEBitmap becomes to 24-Bit and has an Alpha-Bitmap with 8 Bit.

I want then assign this to a 32-Bit TBitmap.

Is there a ready to use function in ImageEn?

At the Moment I do it so:


  ievpic.IEBitmap.DrawToCanvas (wBitmap.canvas, 0,0);
  if (wBitmap.PixelFormat = pf32bit) and (ievpic.HasAlphaChannel) then
    SetBitMapToRGBAValues (ievpic.CurrentLayer.Bitmap.AlphaChannel.vclbitmap, 
    wBitmap);
  end;


The function "SetBitmaptoRGBAValues" use the AlphaChannel.vclbitmap to set the Alpha-Values in wBitmap.

HS

xequte

38615 Posts

Posted - Jun 14 2017 :  20:01:43  Show Profile  Reply

Hi Harry

You can SynchronizeRGBA to handle this.

Please see examples at:

https://www.imageen.com/help/TIEBitmap.SynchronizeRGBA.html

Nigel
Xequte Software
www.xequte.com
nigel@xequte.com
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
Jump To: