Convert 300 dpi image to 72 dpi but maintain original WxH

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
jburkhart68
Posts: 13
Joined: 2011-03-08T17:34:27-07:00
Authentication code: 8675308

Convert 300 dpi image to 72 dpi but maintain original WxH

Post by jburkhart68 »

With the following comand I am trying to flatten a 300 dpi psd file and set resolution to 72 dpi.

-flatten -units pixelsperinch -density 72 filename.tif

I seem to be missing somethng but not sure what it is. I get a tif file ok but the size is still 300 dpi.

Thanks,
Jeff
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Re: Convert 300 dpi image to 72 dpi but maintain original Wx

Post by anthony »

Photoshop stores its 'density' in a different place to the normal position for TIFF file formats. Try stripping the TIFF of extra profiles. (using -strip)

See the note for TIFF file format
http://www.imagemagick.org/Usage/formats/#tiff
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
jburkhart68
Posts: 13
Joined: 2011-03-08T17:34:27-07:00
Authentication code: 8675308

Re: Convert 300 dpi image to 72 dpi but maintain original Wx

Post by jburkhart68 »

Using -strip gives me the correct resolution. Now I need to constrain the proportions so that the demensions do no change. Trying to create a fpo for highrez replacement.

Thanks for the help,
Jeff
jburkhart68
Posts: 13
Joined: 2011-03-08T17:34:27-07:00
Authentication code: 8675308

Re: Convert 300 dpi image to 72 dpi but maintain original Wx

Post by jburkhart68 »

-strip is not going to work for me either. It removes the clipping path that I need to have included with the output file. arrg
User avatar
anthony
Posts: 8883
Joined: 2004-05-31T19:27:03-07:00
Authentication code: 8675308
Location: Brisbane, Australia

Re: Convert 300 dpi image to 72 dpi but maintain original Wx

Post by anthony »

jburkhart68 wrote:Using -strip gives me the correct resolution. Now I need to constrain the proportions so that the demensions do no change. Trying to create a fpo for highrez replacement.
Good the command you want to resize the image to the correct density at the same REAL WORLD dimensions, is -resample
See http://www.imagemagick.org/Usage/resize/#resample
Anthony Thyssen -- Webmaster for ImageMagick Example Pages
https://imagemagick.org/Usage/
Post Reply