Page 1 of 1

Grayscale Linear vs Non-linear documentation Bug

Posted: 2017-10-21T19:43:08-07:00
by fmw42
At https://legacy.imagemagick.org/script/c ... gement.php and https://www.imagemagick.org/script/color-management.php
Normally, the conversion to separate each channel of an sRGB color image produces separate linear grayscale images. However the same concept can be applied, if it is desired to keep the separate channels as non-linear grayscale. For example, the following produces non-linear grayscale channels.

convert myimage.png -set colorspace RGB -separate myimage_channels_%d.png
To me this documentation is unclear as to what is being discussed and demonstrated. It does not read correctly if one is trying to convert non-linear image and separate into linear channels. So it could be a remnant from the time that grayscale images were linear and RGB and SRGB were swapped.

Thus it seems to me that linear and non-linear should be swapped in three places. Also -set colorspace RGB should be changed to -colorspace RGB (otherwise it just sets the colorspace to linear but does not change the pixel data to linear)

As of IM 6.8.6.0 (viewtopic.php?f=4&t=21269#p104277), it should read:
Normally, the conversion to separate each channel of an sRGB color image produces separate non-linear grayscale images. However the same concept can be applied, if it is desired to keep the separate channels as linear grayscale. For example, the following produces linear grayscale channels.

convert myimage.png -colorspace RGB -separate myimage_channels_%d.png

Re: Grayscale Linear vs Non-linear documentation Bug

Posted: 2017-10-22T05:33:02-07:00
by magick
We fixed the docs. Wait 24 hours for the updates to mirror.