Skip to content

Instantly share code, notes, and snippets.

@tschmidt
Created October 18, 2012 18:16
Show Gist options
  • Save tschmidt/3913877 to your computer and use it in GitHub Desktop.
Save tschmidt/3913877 to your computer and use it in GitHub Desktop.
ImageMagick PDF to PNG convert
To convert a multipage PDF document to a single image using ImageMagick, do the following:
# Replace <document> with name of actual document.
# The '%04d' will add four digits that will increment and have leading 0's (e.g. document_0000.png, document_0001.png, document_0002.png, etc)
-> convert <document>.pdf <document>_%04d.png
-> convert <document>_0*.png -append -flatten final.png
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment