Image Processing Toolbox User's Guide Previous page   Next Page

Displaying Truecolor Images

Truecolor images, also called RGB images, represent color values directly, rather than through a colormap. A truecolor image is an m-by-n-by-3 array. For each pixel (r,c) in the image, the color is represented by the triplet (r,c,1:3).

To display a truecolor image, using either imshow or imtool, specify the image matrix as an argument. For example, this code reads a truecolor image into the MATLAB workspace and then displays the image. This documentation uses the variable name RGB to represent a truecolor image in the workspace

or

Systems that use 24 bits per screen pixel can display truecolor images directly, because they allocate 8 bits (256 levels) each to the red, green, and blue color planes. On systems with fewer colors, imshow displays the image using a combination of color approximation and dithering. See Working with Different Screen Bit Depths for more information.


Previous page  Displaying Binary Images Special Display Techniques Next page

© 1994-2005 The MathWorks, Inc.