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.
- Posts: 10281
- Joined: 2010-01-23T23:01:33-07:00
- Authentication code: 1151
- Location: England, UK
The page http://www.imagemagick.org/script/comma ... #intensity
Typically the linear Rec709Luminance formula is used, which is the same formula used when converting images to -colorspace gray.
This is wrong, as "-colorspace gray" uses the Rec709Luma formula. It always has. This can be shown:
Code: Select all
f:\web\im>%IMG7%magick ( toes.png -colorspace Gray ) ( toes.png -grayscale Rec709Luma ) -metric RMSE -format %[distortion] -compare info:
f:\web\im>%IMG7%magick ( toes.png -colorspace Gray ) ( toes.png -grayscale Rec709Luminance ) -metric RMSE -format %[distortion] -compare info:
- Posts: 23246
- Joined: 2007-07-02T17:14:51-07:00
- Authentication code: 1152
- Location: Sunnyvale, California, USA
You are correct. It must be a typo or a remnant from when grayscale was linear.
Also I would have expected these formulae to be using non-liner, R', G' and B' values rather than the linear R, G, B
Average (R + G + B) / 3.0
MS (R^2 + G^2 + B^2) / 3.0
RMS sqrt( (R^2 + G^2 + B^2) / 3.0 )
Was it intended to use linear combinations here or is this also a remnant form the days when single channels were linear?