[Lazarus] Extract the color data and alpha from a PNG image

José Mejuto joshyfun at gmail.com
Wed Feb 6 13:32:39 CET 2013


El 05/02/2013 23:49, silvioprog escribió:

> You have puted a PNG image into a PDF? That's what I'm trying to do, and
> it needs of the uncompressed data too (or compressed as gzip).

Hello,

Hmmm... No I had not reached that point, in fact I'm too far, but I 
still think you do not need the uncompressed data, you should post the 
compressed one and add the /FlateDecode filter to the XObject. Maybe 
except the situation where PNG compressed data uses a color format or 
alike that is not supported in PDF (I do not know if that case exists at 
all).

Anyway I must check documentation as images are too far in my project.

>     That PHP code is a toy and can handle only a subset of PNGs.
> FPDF is a very good library, and it does what it promises. It handles a
> good range of PNG formats, indexeds, grayed, with or without palette
> etc. So, if is so easy to do, how I it do then?

For PDF insert it could be fine, of course. I can convert that PHP to 
pascal, but I can not today.

-- 





More information about the Lazarus mailing list