-grayscale documentation

Post any defects you find in the released or beta versions of the ImageMagick software here. Include the ImageMagick version, OS, and any command-line required to reproduce the problem. Got a patch for a bug? Post it here.
Post Reply
User avatar
fmw42
Posts: 25562
Joined: 2007-07-02T17:14:51-07:00
Authentication code: 1152
Location: Sunnyvale, California, USA

-grayscale documentation

Post by fmw42 »

The page at http://www.imagemagick.org/script/comma ... #grayscale is wrong, I believe, since -colorspace gray is currently non-linear.

The page says:

Code: Select all

This will use one of the -intensity methods to convert the given image into a linear-grayscale image.

For example, to convert an image to (linear) Rec709Luminance grayscale, type:

convert in.png -grayscale Rec709Luminance out.png
which is equivalent to:

convert in.png -colorspace gray out.png
Similarly, to convert an image to (non-linear) Rec709Luma grayscale, type:

convert in.png -grayscale Rec709Luma out.png
which is equivalent to:

convert in.png -set colorspace RGB -colorspace gray out.png
But should say

Code: Select all

This will use one of the -intensity methods to convert the given image into a grayscale image.

For example, to convert an image to (linear) Rec709Luminance grayscale, type:

convert in.png -grayscale Rec709Luminance out.png
which is equivalent to:

convert in.png -set colorspace RGB -colorspace gray out.png

Similarly, to convert an image to (non-linear) Rec709Luma grayscale, type:

convert in.png -grayscale Rec709Luma out.png
which is equivalent to:

convert in.png -colorspace gray out.png
Post Reply