Differences
This shows you the differences between two versions of the page.
Next revision | Previous revision | ||
docs:pdf:pdf_workflow [2007/05/15 13:18] – created billh | docs:pdf:pdf_workflow [2009/04/24 22:53] (current) – billh | ||
---|---|---|---|
Line 1: | Line 1: | ||
====== PDF Workflow ====== | ====== PDF Workflow ====== | ||
+ | |||
+ | ===== Undocumented PDF Common Workflow Issues ===== | ||
+ | * < | ||
+ | * < | ||
+ | * remove all comments/ | ||
+ | * remove or flatten forms | ||
+ | * pdf/x standard (no transparency, | ||
+ | * document exact pdf procedure for creating valid files with every company program (create a standard) | ||
+ | * flatten all comments/ | ||
+ | * print bookmarks list | ||
+ | |||
===== Burst PDF pages into individual files ===== | ===== Burst PDF pages into individual files ===== | ||
- | This gives you the ability to work with each page on an individual basis. | + | This gives you the ability to work with each page on an individual basis. |
* requires pdftk | * requires pdftk | ||
* example:< | * example:< | ||
pdftk input.pdf burst | pdftk input.pdf burst | ||
</ | </ | ||
+ | |||
===== Convert PDF to PS (PostScript) ===== | ===== Convert PDF to PS (PostScript) ===== | ||
+ | * these tools come with ghostscript | ||
+ | * this step can be the source of problems, so make sure to read the " | ||
* example:< | * example:< | ||
pdf2ps input.pdf output.ps | pdf2ps input.pdf output.ps | ||
+ | |||
+ | or | ||
+ | |||
+ | pdf2ps -dLanguageLevel=1 input.pdf output.ps | ||
</ | </ | ||
===== Optimize individual PDF page ===== | ===== Optimize individual PDF page ===== | ||
+ | * these tools come with ghostscript | ||
* burst a multi-page pdf file into single files | * burst a multi-page pdf file into single files | ||
* options: | * options: | ||
- | * convert the pdf file to ps, then use ps2pdf to write a new pdf file with image compression optimizations:< | + | * convert the pdf file to ps, then use ps2pdf to write a new pdf file with image compression optimizations: |
- | ps2pdf | + | (force zip/flate image compression) |
+ | ps2pdf | ||
+ | |||
+ | or | ||
+ | |||
+ | (force jpeg compression) | ||
+ | ps2pdf -dAutoFilterColorImages=false -dColorImageFilter=/ | ||
</ | </ | ||
- | * use GhostScript to convert and write a new pdf file with image compression optimizations (see section below) | + | * use GhostScript to convert and write a new pdf file with image compression optimizations (see section below):< |
+ | gs -dNOPAUSE -sDEVICE=pdfwrite -dAutoFilterColorImages=false -dColorImageFilter=/ | ||
+ | </ | ||
===== Image Compression with Ghostscript ===== | ===== Image Compression with Ghostscript ===== | ||
Line 25: | Line 53: | ||
* http:// | * http:// | ||
- | The ghostscript defaults -dAutoFilterColorImages=true and -dAutoFilterGrayImage=true cause ghostscript to automatically detect whether JPEG or Flate compression is most suitable for each image. JPEG is good for photo images. Flate is good for line drawings, cartoons and computer screen shots. | + | The ghostscript defaults -dAutoFilterColorImages=true and -dAutoFilterGrayImages=true cause ghostscript to automatically detect whether JPEG or Flate compression is most suitable for each image. JPEG is good for photo images. Flate is good for line drawings, cartoons and computer screen shots. |
The compression can be forced to JPEG with< | The compression can be forced to JPEG with< | ||
Line 42: | Line 70: | ||
Using -dPDFSETTINGS=/ | Using -dPDFSETTINGS=/ | ||
+ | ===== Troubleshooting / Large Files ===== | ||
+ | This process failed to work for me on a particular document when text was over an underlying image (the file was very large as a result). | ||
+ | * open pdf file and save as pdf file using Adobe Illustrator, | ||
+ | * open pdf file and save as ps file (via Print -> Save PDF as Postscript) using Apple Preview, then ps2pdf | ||
+ | * open pdf file and save as ps file using Adobe Acrobat, then ps2pdf | ||
+ | |||
+ | It should also be noted that resaving the file (even using optimization) in Acrobat 6 did not make a usable pdf file. The best indicator I can think of for this problem is to watch for unusually large Postscript files, when compared to others in the same file. | ||
+ | |||
+ | ===== Export Images ===== | ||
+ | You can export all images from a PDF file using the Advanced -> Export All Images... function in Adobe Acrobat 6 |