Page 1 of 1

decode pdf image /FlateDecode /RunLengthDecode

Posted: 2016-11-03T03:52:22-07:00
by martin0
Hi,
I have a pdf with an image having the filters /FlateDecode /RunLengthDecode (in that order)


I've seen table PS/PDF Compression Meanings
in http://www.imagemagick.org/Usage/formats/

which explains they are equivalent to
"-compress zip"
and
"+compress"
"-compress rle"
    any thing else

respectively.

I'm unclear what the + means in +compress. Also I'm unclear whether these filters should be run sequentially or are alternatives.
I need to decode this image programmatically.

Any advice received most gratefully
Kind Regards
Martin

Re: decode pdf image /FlateDecode /RunLengthDecode

Posted: 2016-11-03T04:18:22-07:00
by snibgo
"-compress" specifies a type of compression for an output. Each output can have only one compression type. Not all file format types can use all compression methods. See http://www.imagemagick.org/script/comma ... p#compress

"+compress" means the same as "-compress None", no compression.

"-compress RLE" is run-length encoding. This can be effective for solid-colour graphics, but not photographs.

Re: decode pdf image /FlateDecode /RunLengthDecode

Posted: 2016-11-04T04:26:25-07:00
by martin0
Hi snibgo, Thanks for that. I'll try to make more sense of the pdf.

Martin