Image Processing Toolbox    

Troubleshooting

This section contains three common scenarios (in bold text) which can occur unexpectedly, and what you can do to derive the expected results.

Color Image Displays as Grayscale

If a color image displays as a grayscale image, it can indicate that the image is an indexed image and you have not specified the associated colormap.

To display an indexed image using imshow, you must specify the colormap, using this syntax:

You should also make sure that you used the correct syntax for loading an indexed image, which is,

For more information about displaying indexed images, see Displaying Indexed Images.

Displaying Multiframe Images

If you load a multiframe image and display it, MATLAB only displays one frame.

To view the other frames in a multiframe image, you must load each frame separately. This can be done using a for loop. It may be helpful to first use imfinfo to find out how many frames the image file contains, and what their dimensions are. To see an example, go to Displaying the Frames of a Multiframe Image Individually.


  Printing Images Spatial Transformations