[poppler] Trying to extend pdftoppm to use CairoOutputDev

mpsuzuki at hiroshima-u.ac.jp mpsuzuki at hiroshima-u.ac.jp
Fri Dec 18 03:56:26 PST 2009

On Fri, 18 Dec 2009 21:16:55 +1030
Adrian Johnson <ajohnson at redneon.com> wrote:
>mpsuzuki at hiroshima-u.ac.jp wrote:
>> The pdf "cropped" by pdftocairo is
>>   http://home.hiroshima-u.ac.jp/mpsuzuki/cropped-pdftocairo.pdf
>> It was "cropped" aslike:
>>   pdftoppm -pdf -f 1 -l 1 -r 72 -x 80 -y 80 -W 215 -H 160 \
>>     tibetbt-chart.pdf cropped-pdftocairo.pdf
>I assume you meant "pdftocairo" instead of "pdftoppm".

Oops, I'm sorry for my mistypo.

>The resolution option "-r" is not required (and doesn't do
>anything) when using -pdf or -ps.

I see. When the positions to crop are calculated from the
options -x, -y, -W and -H , which unit is used? Fixed dpi
(150 or 72) is assumed?

>> It seems that the origin specified by -x & -y are reflected,
>> but the output is full sized, not cropped. What was wrong?
>Probably a bug. I copied pdftoppm.cc to create pdftocairo.cc so all the 
>relevant options were copied across. However many of the options have 
>not been tested as I only use pdftocairo for my testing purposes.
>Patches are welcome.

OK! I will try.


More information about the poppler mailing list