Take the 2-minute tour ×
Graphic Design Stack Exchange is a question and answer site for Graphic Design professionals, students, and enthusiasts. It's 100% free, no registration required.

Is it possible to find out what compression algorithms have been used for images in a PDF document?

share|improve this question

1 Answer 1

Sort of.

If you open a PDF in a text editor, you'll find a line like this for each image:

<</Subtype/Image/Length 7986/Filter/FlateDecode/BitsPerComponent 8/ColorSpace 34 0 R/Width 368/Height 110/Type/XObject>>stream
...

This image uses the FlateDecode filter, "a commonly used filter based on the zlib/deflate algorithm (a.k.a. gzip, but not zip)"

<</Subtype/Image/Length 892/Filter/DCTDecode/BitsPerComponent 8/ColorSpace 34 0 R/Width 44/Height 23/Type/XObject>>stream
...

This image uses the DCTDecode filter, "a lossy filter based on the JPEG standard"

Filter definitions are from the Portable Document Format Wikipedia page, which has a list of all the supported filters.

However, it can be difficult to work out which image is which in a text editor - the objects do not necessarily occur in reading order. Breaking the PDF into single pages might help here.

I think Enfocus Pitstop Pro, an Acrobat plugin, may well give you this info (along with dimensions, position, DPI etc) in its object inspector, but I no longer have it, and can't seem to find any mention of this specific attribute in their manual.

share|improve this answer
1  
Acrobat also has a myriad of predefined preflight reports. Not sure if they are available in the free version (?) –  horatio Sep 4 '12 at 16:30
    
Note that PNG also uses the DEFLATE compression algorithm (zlib is an implementation of DEFLATE). So you can think of the first example as being like a PNG image in many respects such as how well it will compress. –  thomasrutter Sep 5 '12 at 0:30
    
@horatio: They are not. Also the free version is called "Adobe Reader" not "Adobe Acrobat Reader" these days. –  e100 Sep 5 '12 at 18:03
    
I thought it was Acrobat X or AcrobatZ or something :) –  horatio Sep 5 '12 at 18:08
    
It's always been confusing. It's currently Adobe Reader X, Adobe Acrobat X, Adobe Acrobat X Pro. What really annoys me is when people refer to "Adobe" when they mean a single app. –  e100 Sep 5 '12 at 18:22

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.