IMSHOW(1)

NAME
imshow - displays images in scilab graphic window

SYNOPSIS
imshow(Img)
imshow(Img,n)
imshow(Img,[low high])
imshow(Img,Map)
imshow(RGBImg)
imshow filename

PARAMETERS

filename
    A String, the image filename to be displayed. The extension determines the type of the image.

Img MxN matrix, a grayscale or pseudo-color (indexed) image.

n   A scalar, the number of levels of gray to display Img.

[low high]
    1x2 array corresponding to the grayscale range to be considered.

Map Mx3 matrix containing the image colormap (for indexed images). Entries range from 0 to 65535.

RGBImg
    MxNx3 hypermatrix in 0-65535 range.

DESCRIPTION
imshow(Img,n) displays Img using n gray levels. Img is an MxN matrix in 0 - (n-1) range. If n is omitted, it will be assumed to be 256.

imshow(Img,[low high]) displays Img using a grayscale within the specified range. Elements <= low will map onto black, Elements >= high will map onto white, and elements in between will map as a shade of gray. If an empty matrix '[]' is used, [low,high] will be assumed to be [mini(Img), maxi(Img)].

imshow(Img,Map) displays Img using the specified colormap.

imshow(RGBImg) displays the RGBImg MxNx3 (0-65535) truecolor image.

imshow(filename) displays the image (filename) in scilab graphic. Any raster image format is accepted (see REMARKS section).

EXAMPLE
initial_dir = PWD;
chdir (SIPDIR + 'examples');
a = int(255*rand(100,100));   // create random image
xbasc();
imshow(a);
imshow(a,hotcolormap(256));
imshow(a,[100 150]);
imshow(a,[]);
xbasc();
imshow('example.png');
chdir(initial_dir);

REMARKS
In theory, imshow(filename) will work with any raster image format. In practice, it has been tested only for BMP, GIF, JPEG, PNG, PCX, TIFF, XPM, and MIFF. Displaying other file formats will probably work, but this case have not been tested by the developers of the SIP toolbox.

BUGS AND SHORTCOMINGS
The display of truecolor images is somewhat inefficient.

Images are stored in double precision matrices. Hopefully, the next release will make usage of integer types.

AUTHORS
Ricardo Fabbri <rfabbri@if.sc.usp.br>

AVAILABILITY
The latest version of the Scilab Image Processing toolbox can be found at

    http://cyvision.if.sc.usp.br/~rfabbri/sip/

SEE ALSO
imread, imwrite, imfinfo