Hi
I have a programm (Insight Toolkit ITK) which cannot read 16 bit TIFF data in general. The data is stored in Lab color space. ITK is able to read 16 bit png data so i like to convert it to a png which works, but imagemagick automatically convert the color channels to RGB which i do not want, so
- is there any way to suspress this behavour so that Red channel is L, Green is a and Blue is b from originall input image
- or, if not, is there a way to extract L, a and b and store them seperatelly as grayscale 16 bit png's
Thanks a lot
			
			
									
						
										
						Extract L, a, and b channel from Tiff and store as grayscale
- fmw42
 - Posts: 25562
 - Joined: 2007-07-02T17:14:51-07:00
 - Authentication code: 1152
 - Location: Sunnyvale, California, USA
 
Re: Extract L, a, and b channel from Tiff and store as grays
try
convert image.tiff -separate -set colorspace Lab -combine -colorspace RGB image.png
or perhaps just
convert image.tiff -colorspace LAB -separate image_%d.png
see
http://www.imagemagick.org/Usage/color_basics/#separate
			
			
									
						
										
						convert image.tiff -separate -set colorspace Lab -combine -colorspace RGB image.png
or perhaps just
convert image.tiff -colorspace LAB -separate image_%d.png
see
http://www.imagemagick.org/Usage/color_basics/#separate
Re: Extract L, a, and b channel from Tiff and store as grays
thanks a lot, i did not checked that there is also a -set colorspace option...