On v6.9.2-5:
Code: Select all
convert im3.png -colorspace Gray im4.png -clut x1.png
convert im3.png -colorspace CMYK -colorspace Gray im4.png -clut x2.png
EDIT: My copy-paste removed the "-colorspace Gray" in the first command.
Code: Select all
convert im3.png -colorspace Gray im4.png -clut x1.png
convert im3.png -colorspace CMYK -colorspace Gray im4.png -clut x2.png
Code: Select all
f:\web\im>%IM%convert im3.png -colorspace CMYK -colorspace Gray im4.png -clut clt_x1.png
f:\web\im>%IM%convert im3.png -colorspace Gray im4.png -clut clt_x2.png
f:\web\im>%IM%compare -metric RMSE clt_x1.png clt_x2.png NULL:
0 (0)
Code: Select all
convert infile.tif -colorspace gray gradient.tif -clut -resize 602x602 -background white -gravity center outfile1.tif
im6883 convert infile.tif -colorspace gray gradient.tif -clut -resize 602x602 -background white -gravity center outfile2.tif
Code: Select all
type -a convert
Code: Select all
which -a convert
Good catch snibgo! I was just in the process of checking out the linear vs nonlinear issue when I saw your post. (Though I was (wrongly) trying to go the other way to make the old linear equivalent to the new non-linear gray using -set colorspace RGB and that did not seem to work). See viewtopic.php?f=4&t=21269 for a discussion of linear vs non-linear and the IM versions where things changed.To get a result that seems "perfect", use "-grayscale Rec709Luminance" instead of "-colorspace Gray". (The documentation http://www.imagemagick.org/script/comma ... #grayscale say these are the same, but it seems they are not the same.)
Code: Select all
convert infile.png -grayscale rec709luminance gradient.png -clut -resize 602x602 -background white -gravity center outfile4.png
convert infile.png -grayscale rec601luminance gradient.png -clut -resize 602x602 -background white -gravity center outfile5.png
Yes, I will try to do that tomorrow.snibgo wrote:Fred, can you correct http://www.imagemagick.org/script/comma ... #grayscale ?