Last updated
Was this helpful?
Last updated
Was this helpful?
Type the following command ()$ gs -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=setting -sOutputFile=output.pdf input.pdf
Set the input file name properly as well as the output file name if wanted.
in -dPDFSETTINGS
use:
/screen
for lowest quality
/ebook
for medium quality
/printer
and /prepress for high quality
command $ convert input.pdf output.pdf
Options:
density
image resolution
rotate
rotation angle degrees
attenuate
noise addition
noise
noise peak reduction
flatten
no virtual offline across layers
sharpen
Gaussin operator to sharpen the image
Example (): $ convert -density 150 input.pdf -rotate "$([ $((RANDOM % 2)) -eq 1 ] && echo -)0.$(($RANDOM % 3))" -attenuate 0.15 +noise Multiplicative -flatten -attenuate 0.02 +noise Multiplicative -sharpen 0x1.0 output.pdf
command pdfinfo: $ pdfinfo file.pdf