
But with PNG it gives PixelsPerCentimeter regardless of how I created/saved it in Photoshop. In Imagick (Version: ImageMagick 6.9.11-60 Q16 x86_64) - it is able to see the difference between a JPG saved at PixelsPerCentimeter and the JPG saved as PixelsPerInch. In windows (11) I can only see Resolution in the properties for JPG, not on PNG's and regardless of whether you make the PSD as a PixelsPerCentimeter or PixelsPerInch it's displayed as (300 dpi). I am doing a lot of work with images (JPG's, PNG's and Tiff) and detecting their resolution.įor example I can run this on an image in Imagick: $imagick = new Imagick($filename) Īnd it will give me the resolution and the units (PixelsPerCentimeter or PixelsPerInch)

This isn't a problem but rather trying to improve my understanding of how DPI is stored in various file formats and discussion as to why it works the way it does.
