LoginSignup
19
18

More than 5 years have passed since last update.

PDFのファイルサイズをGhostscriptのコマンドで小さくする

Last updated at Posted at 2016-12-13

大きいファイルサイズのPDFはEメールに添付して送付すると、メールサーバーで弾き返され、送付できないことがある。そのような場合は、PDFの画像の解像度を落としてファイルサイズを小さくするGhostscriptのコマンドが役立つ。

gs -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -dCompatibilityLevel=1.4 \
   -dPDFSETTINGS=/screen -sOutputFile=output.pdf input.pdf

output.pdfは出力ファイル名、input.pdfは入力ファイル名である。-dPDFSETTINGSでPDFファイルの解像度を指定してファイルサイズを小さくできる。/screenが一番解像度が低く、/ebookは中間程度、/printer/prepressは高解像度である。

参考

19
18
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
19
18