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
 reading 8 bit BMP files with RLE compression

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
jacq59 Posted - Sep 14 2012 : 05:18:19
Hello
I have bmp image files with a palette (8 bits per pixels) and RLE 8 bits encoding
I want to find in the image all the pixels for a given index of the palette.
I have loaded the file in a bitmap with type tIEbitmap and then used pixels to scan the image
but the bitmap is imposed as a 24bit format
and I do not have access to the palette indexes.
Is there any other approach?

jack
1   L A T E S T    R E P L I E S    (Newest First)
fab Posted - Sep 18 2012 : 03:53:04
Hello,
load the image using:

ImageEnView1.LegacyBitmap := false;
ImageEnView1.IO.NativePixelFormat := true;
ImageEnView1.IO.LoadFromFile('input.bmp');

Now you have a pure 8 bits per pixels paletted image. You can access color indices with:
index := ImageEnView1.IO.IEBitmap.Pixels_ie8[col, row];

The color palette is in ImageEnView1.IO.IEBitmap.Palette[] array.