pdfreader icon indicating copy to clipboard operation
pdfreader copied to clipboard

CCITTFaxDecoder: Support for pure one-dimensional encoding (Group 3, 1-D)

Open cdecompilador opened this issue 2 years ago • 2 comments

link to sample pdf The pdf is just a random image scanned from my printer, it fails at filters/ccittfax.py:548

cdecompilador avatar Oct 31 '22 17:10 cdecompilador

PDF specification supports 3 types of encoding depending on K value:

  • K<0 - Pure 2-dimensional encoding (Group 4), which is suported by pdfreader
  • K=0 - Pure one-dimensional encoding (Group 3, 1-D), - which is in use in this file and not supported at this point
  • K>0 - Mixed one and two dimensional, not supported.

I treat as a feature request to start supporting pure one dimensional encodings.

See https://www.fileformat.info/mirror/egff/ch09_05.htm#CH09-DMYID.1.1

maxpmaxp avatar Nov 08 '22 03:11 maxpmaxp

Attaching the sample file as the link in the first comment doesn't work. fax-G31D.pdf

maxpmaxp avatar Apr 30 '24 15:04 maxpmaxp