rivu
rivu

Reputation: 2514

imagemagick "convert" command different outputs

I am trying to convert a 8 page pdf to 8 separate pbm files, using imagemagick. When I do convert test.pdf test.jpg, 8 jpg files (test-0.jpg, test-1.jpg ..) are created, but when I use the command convert test.pdf test.pbm only 1 pbm file (test.pbm) is created. What should I do?

Upvotes: 0

Views: 826

Answers (1)

Iamiuru
Iamiuru

Reputation: 479

convert test.pdf out-%0d.pbm

This will give you out-0.pbm out-1.pbm... I don't know why imagemagick does this automatically for jpg but not for pbm.. If you want to pad the number to be 000-999 then add a "3" in front of the d.

Example:

convert test.pdf out-%03d.pbm

Upvotes: 1

Related Questions