Page 1 of 1

Stripping color profiles from images for use on the web?

Posted: 2013-05-09T16:57:36-07:00
by dunglan
I am using imagemagick for resizing images for use on the web so that they are faster to load.

One of the problems I have is that we have images that contain massive color profiles that can be have half a megabyte in size. When these images are re-sized the file is still huge since that half megabyte color profile is embedded into the re-sized image.

For web use can safely strip these profiles or can we normalize that massive color profiles to smaller profile?

We dont have any control of the color profiles in the image since they are submitted to the application by 3rd parties.

Re: Stripping color profiles from images for use on the web?

Posted: 2013-05-09T17:22:22-07:00
by fmw42

Re: Stripping color profiles from images for use on the web?

Posted: 2013-05-09T18:59:51-07:00
by snibgo
If you merely strip the profile, browsers will assume the image is sRGB. But the image might not have been sRGB.

It might be safer to:

Code: Select all

convert {blah blah} -profile sRGB.icc -strip outfile

Re: Stripping color profiles from images for use on the web?

Posted: 2013-05-12T18:50:13-07:00
by anthony
-resize does not remove ANY profile info. Nor does most other IM operations.

The -strip and -thumbnail does remove most profiles, but leaves the color profile so images still display correctly. For example the EXIF cammera info, and Photoshop profiles is removed.

sRGB is the default profile and PNG will not save images with that profile. As such the solution snibgo gives will handle the color profile.