Printing with ImageMagick

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
Bonzo
Posts: 2971
Joined: 2006-05-20T08:08:19-07:00
Location: Cambridge, England

Re: Printing with ImageMagick

Post by Bonzo »

I think this is how you do it:
Setting the size in resize to print an image 6"x4"



The sizes used in ImageMagick are in pixels; to get an image into a size for printing e.g. 6"x4" you need to do something like this:

Code: Select all

convert input.jpg -resize 600x400 -density 100x100 output.jpg
The default pixel value in ImageMagick is DPI ( dots per inch ) so that will not need setting.
The -density sets the pixels per inch; you can have a different value for the height and width if required
The values in -resize are set by multiplying the required size by the DPI:
6 x 100 = 600 and 4 x 100 = 400
If you were working on 300 dpi it would be 6 x 300 = 1800 and 4 x 300 = 1200
Post Reply