Correct - a colormap does not apply for a true color RGB image. RGB images don't have colormaps, which are essentially lookup tables to convert a gray level into a color. To change the color of a pixel in an RGB image you just do it directly by changing the R, G, and B values. There is no single "index" or gray level like there is with an indexed image. If you want to convert your RGB image into an indexed image, you can do so with the rgb2gray() function. Or you can do color segmentation (like in my File Exchangehttp://www.mathworks.com/matlabcentral/fileexchange/?term=authorid%3A31862 ) to identify some region of the image that matches some criteria you specify, and then create a binary image to change whole regions into the desired color.
Best Answer