Page 1 of 1

Converting from AdobeRGB to sRGB using mogrify

Posted: 2010-06-21T04:34:31-07:00
by dws21
I'm trying to convert in place from AdobeRGB JPGs with Mogrify using the following command line:

mogrify 1_aRGB.jpg -profile sRGB.icc

This updates the file but does not seem to do the conversion, looking with Inspect it still lists:

Profiles:
Profile-8bim: 8158 bytes
Profile-exif: 6751 bytes
Profile-icc: 560 bytes
Description: Adobe RGB (1998)
Manufacturer: Adobe RGB (1998)
Model: Adobe RGB (1998)
Copyright: Copyright 1999 Adobe Systems Incorporated

And visually when checked in a non-colour managed browser (IE8) it's still very obviously in AdobeRGB.

However I can get an image in sRGB by using Convert:

convert 1_aRGB.jpg -profile sRGB.icc sRGB_image.jpg

So am I using Mogrify correctly here, or is there a bug?

I am using: http://www.imagemagick.org/download/bin ... ws-dll.exe

Thanks!

Re: Converting from AdobeRGB to sRGB using mogrify does not

Posted: 2010-06-21T04:42:17-07:00
by dws21
Ah, it appears to work if you specify the same filename as the output:

mogrify 1_aRGB.jpg -profile sRGB.icc 1_aRGB.jpg

So without writing a script is there an easy way to get Mogrify to recurse a folder tree converting all images in it to sRGB?

Re: Converting from AdobeRGB to sRGB using mogrify does not

Posted: 2010-06-21T04:57:20-07:00
by dws21
I seem to be answering my own questions here. :)

A little more play and it seems that with Mogrify you need to specify the filename at the end, so for a simple batch file to Mogrify images to sRGB and recurse sub folders:

FOR /R %%a IN (*.jpg) DO mogrify -profile sRGB.icc "%%a"

Hope this helps someone else.

Re: Converting from AdobeRGB to sRGB using mogrify

Posted: 2010-06-21T08:23:37-07:00
by snibgo
Welcome to the forum. The act of formulating a question often helps us find the answer. I have a bunch of questions I have never posted for that reason.