How does IM convert transparent PNG to PDF?
Posted: 2013-02-27T19:13:01-07:00
For embedding PNG inside PDF, it is necessary to separate alpha channel. I used IM to convert a transparent PNG to PDF, and the output PDF file contains
I want to know how IM captures the PNG data to be inserted into PDF document. In other words, if creating the PDF document manually, how to generate the CAPTURED_PNG_DATA from the original PNG by IM?
Code: Select all
8 0 obj
<<
/Type /XObject
/Subtype /Image
/Name /Im0
/Filter [ /FlateDecode ]
/Width 75
/Height 65
/ColorSpace 10 0 R
/BitsPerComponent 8
/SMask 15 0 R
/Length 9 0 R
>>
stream
CAPTURED_PNG_DATA
endstream
endobj
15 0 obj
<<
/Type /XObject
/Subtype /Image
/Name /Ma0
/Filter [ /FlateDecode ]
/Width 75
/Height 65
/ColorSpace /DeviceGray
/BitsPerComponent 8
/Length 16 0 R
>>
stream
CAPTURED_PNG_DATA
endstream
endobj