Apple Intelligence now features Image Playground, Genmoji, Writing Tools enhancements, seamless support for ChatGPT, and visual intelligence.

Apple Intelligence has also begun language expansion with localized English support for Australia, Canada, Ireland, New Zealand, South Africa, and the U.K. Learn more >

You can make a difference in the Apple Support Community!

When you sign up with your Apple Account, you can provide valuable feedback to other community members by upvoting helpful replies and User Tips.

Looks like no one’s replied in a while. To start the conversation again, simply ask a new question.

sips not setting dpi to 72 of jpg images

Hi All,

I'm using sips -s dpiWidth 72.0 -s dpiHeight 72.0 Beach.jpg, it is not working on this.


Please test with following steps.


* Copy /Library/Desktop Pictures/Beach.JPG to ~/Desktop.

* open terminal

* cd ~/Desktop

* sips -g dpiWidth -g dpiHeight Beach.jpg // it shows 300.0, 300.0

* sips -s dpiWidth 72.0 -s dpiHeight 72.0 Beach.jpg

* sips -g dpiWidth -g dpiHeight Beach.jpg // it shows 300.0, 300.0 instead of 72.0, 72.0


I don't know why it is not working, I've tested this on iMac with 10.7.4 and 10.8.4

sips-h shows "sips 10.4.4 - scriptable image processing system."


Please help me to resolve this. Am I missing something here ?


Thanks

Posted on Jan 22, 2013 2:03 AM

Reply
Question marked as Top-ranking reply

Posted on Jan 22, 2013 4:03 PM

jpeg-2000 (*.jp2) also works.


sips -s format jp2 -s formatOptions normal foo.tiff -s dpiHeight 72.0 -s dpiWidth 72.0 --out foo.jp2
11 replies

Jan 22, 2013 8:08 AM in response to pmaks

I'm seeing the same thing as the OP. Sips version is 10.4.4 on 10.8.2


When I run the -g to set the dpi sips pauses for a moment as if it is doing sowmthing and the modified date on the jpg is changed to reflect the current time so it seems sips did something to the file


the command I used is


sips -s dpiHeight 72.0 -s dpiWidth 72.0 Scan.jpeg

and

sips -g dpiHeight -g dpiWidth Scan.jpeg

Dec 4, 2013 2:35 PM in response to etresoft

It does not seem to work in my case: I am trying to set the dpi while converting a PDG file to PNG and it does not make any difference when I experiment with different values with dpiHeight and dpiWidth. Maybe I am doing something wrong, but I not get any error message.

I go to the folder where I have the pdf file and execute:


sips --setProperty dpiHeight 128.0 --setProperty dpiWidth 128.0 --setProperty format png --out myfile.png ./myfile.pdf

or

sips --setProperty dpiHeight 12.0 --setProperty dpiWidth 12.0 --setProperty format png --out myfile.png ./myfile.pdf


In both case I get the same size for the PNG file. It is also the case for other values than 128. or 12. The property is set to the value I give, but the size of the converted image does nos take it into account. My file is always of size 2498x1871 in my case.


--setProperty formatOptions high/low etc. seems to work for the JPEGs, but I need a PNG unfortunately and the compression ratio is not relevant for the PNGs of course...

Any idea on how I can change the effective dpi of the converted image using spis?

sips not setting dpi to 72 of jpg images

Welcome to Apple Support Community
A forum where Apple customers help each other with their products. Get started with your Apple Account.