MATLAB: Save TIFF with Look Up Table

imwritelook up tablestacktiff

Hello,
I'm trying to save my images as 16-bits tiff files using the imwrite function. I can create this file but I didn't find the option to save it with a desired LUT.
begin of my code
imwrite(channel1, fullname_tif_output,output_format,'WriteMode','overwrite','Compression','none');
imwrite(channel4,fullname_tif_output,output_format,'WriteMode','append', 'Compression','none');
imwrite(channel3, fullname_tif_output,output_format,'WriteMode','append', 'Compression','none');
imwrite(channel4, fullname_tif_output,output_format,'WriteMode','append', 'Compression','none');
end of my code

Best Answer

Hi Sébastien,
I assume that by lookup tables you mean Red-Green-Blue (RGB) color maps associated with the TIFF image. The function "imwrite" allows you to save the images as TIFF files; unfortunately, this function does not support writing the associated lookup tables with the files. You may want to explore MATLAB's Tiff class, which provides access to many of the capabilities of the LibTIFF library.
I hope this helps.
Matt