[poppler] pdftops creates huge file with simple color background (attached examples)

Albert Astals Cid aacid at kde.org
Tue Feb 2 13:44:13 PST 2016


El Tuesday 02 February 2016, a les 16:28:37, William Bader va escriure:
> I looked at it a little, and I merged the LZW from xpdf 3.04 into poppler.
> In LZWEncoder, I changed getBlock(buf, len) to doGetChars(len, buf), but
> otherwise, poppler and xpdf are still close enough that it was not
> complicated. Was there some reason why no one merged in the code before?

Noone has ever had time to diff xpdf 3.03 against xpdf 3.04 and merge the 
useful bits into poppler, someone should do it, hint, hint, wink, wink.

Cheers,
  Albert

> Are there LZW patent issues? I'll send a patch tomorrow.
> $ ./pdftops tux-yellow.pdf
> $ ls -l tux-yellow.ps
> -rw-rw-rw- 1 william william 1126366 Feb  2 22:25 tux-yellow.ps
> $ /usr/local/bin/pdftops tux-yellow.pdf
> $ ls -l tux-yellow.ps
> -rw-rw-rw- 1 william william 27552291 Feb  2 22:25 tux-yellow.ps
> William
> 
> > To: ajohnson at redneon.com; poppler at lists.freedesktop.org
> > From: Pierre-Luc.Samuel at ticketmaster.com
> > Date: Mon, 1 Feb 2016 16:39:21 -0500
> > Subject: Re: [poppler] pdftops creates huge file with simple color
> > background (attached examples)> 
> > On 01/29/2016 05:29 PM, Adrian Johnson wrote:
> >  > "pdftocairo -ps tux-yellow.pdf" creates a 112KB file.
> >  > "pdftocairo -ps -level2 tux-yellow.pdf" creates a 345KB file.
> >  > 
> >  > So you should be able to get significantly better compression out of
> > 
> > pdftops by using the /FlateDecode filter for PS level 3 and fallback to
> > /LZWDecode for level 2.
> > 
> > Exactly, LZWDecode would be great in pdftops; do you imply there's a way
> > to do that with pdftops?  Using pdftocairo is not possible because of
> > other issues with fonts...
> > 
> > Also, I noticed https://bugs.freedesktop.org/show_bug.cgi?id=81760
> > mentions that LZW was implemented in xpdf and may be eventually merged
> > back to poppler, any news on that front?
> > 
> > Pierre-Luc
> > _______________________________________________
> > poppler mailing list
> > poppler at lists.freedesktop.org
> > http://lists.freedesktop.org/mailman/listinfo/poppler



More information about the poppler mailing list