convert multiple page PDF to single image

Questions and postings pertaining to the usage of ImageMagick regardless of the interface. This includes the command-line utilities, as well as the C and C++ APIs. Usage questions are like "How do I use ImageMagick to create drop shadows?".
Post Reply
pentium10

convert multiple page PDF to single image

Post by pentium10 »

I use this command:

Code: Select all

/usr/local/bin/convert -density 150 -quality 100 -resize 800x "tsfilename.pdf" "tsfilename.pdf.jpg"
My problem with multiple page PDF is, that multiple images are created.
I would like to have one single very long image to be created.

I use this feature as a print preview. So it's essential to be one image.
Is there a command to convert multiple paged PDF to one long image?
If not, how can I create one long image from the N ones, that are created after conversion?

Or if you have better idea, let me know.
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: convert multiple page PDF to single image

Post by fmw42 »

pentium10 wrote:I use this command:

Code: Select all

/usr/local/bin/convert -density 150 -quality 100 -resize 800x "tsfilename.pdf" "tsfilename.pdf.jpg"
My problem with multiple page PDF is, that multiple images are created.
I would like to have one single very long image to be created.

I use this feature as a print preview. So it's essential to be one image.
Is there a command to convert multiple paged PDF to one long image?
If not, how can I create one long image from the N ones, that are created after conversion?

Or if you have better idea, let me know.
Create all your separate jpg images from the pdf first, then you can take all the jpgs and use -append to stack them into one tall image. That will be two steps unless you write a script to extract each page separately and then stack it onto the previous stack.
pentium10

Re: convert multiple page PDF to single image

Post by pentium10 »

How do I know how many images were created?
Is there a return value from imagemagick?
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

Re: convert multiple page PDF to single image

Post by fmw42 »

pentium10 wrote:How do I know how many images were created?
Is there a return value from imagemagick?
Each jpg will end in an number image-0.jpg image-1.jpg etc
Post Reply