pdftk compression option

前端 未结 10 1098
一向
一向 2020-12-04 04:55

I use pdftk to compress a pdf using the following command line

pdftk file1.pdf output file2.pdf compress

It works as the w

10条回答
  •  北海茫月
    2020-12-04 06:01

    If file size is still too large it could help using ps2pdf to downscale the resolution of the produced pdf file:

    pdf2ps input.pdf tmp.ps
    ps2pdf -dPDFSETTINGS=/screen -dDownsampleColorImages=true -dColorImageResolution=200 -dColorImageDownsampleType=/Bicubic tmp.ps output.pdf
    

    Adjust the value of the -dColorImageResolution option to achieve a result that fits your needs (the value describes the image resolution in DPIs). If your input file is in grayscale, replacing Color through Gray or using both options in the above command could also help. Further fine-tuning is possible by changing the -dPDFSETTINGS option to /default or /printer. For explanations of the all possible options consult the ps2pdf manual.

提交回复
热议问题