Posts

Showing posts with the label PDF

Linux Compress PDF batch

#### gs gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/ebook -dNOPAUSE -dQUIET -dBATCH -sOutputFile=output.pdf $INPUTFILE ### pdf2ps && ps2pdf pdf2ps input.pdf output.ps && ps2pdf output.ps output.pdf ### Webservice http://compress.smallpdf.com/de For linux #!/bin/sh gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 -dPDFSETTINGS=/default -dNOPAUSE -dQUIET -dBATCH -dDetectDuplicateImages -dCompressFonts=true -r150 -sOutputFile="compress_$@" "$@" ./compresspdf.sh file.pdf find -type f -name "*.pdf" -exec ./compresspdf.sh {} \; #!/bin/sh INPUT = $1 ; shift OUTPUT = $1 ; shift GS_BIN =/ usr / bin / gs QFACTOR = "0.40" # Image Compression Quality # # Quality HSamples VSamples QFactor # Minimum [2 1 1 2] [2 1 1 2] 2.40 # Low [2 1 1 2] [2 1 1 2] 1.30 # Medium [2 1 1 2] [2 1 1 2] 0.76 # High [1 1 1 1] [1 1 1 1] 0.40 # Maximum [1 1 1 1] [1 1 1 1] 0.15 $ { GS_BIN } - dBATCH - dSAFER - DNOPAUSE -...