vtkPPMREAD Function

Reads a PPM file.

Usage

image = vtkPPMREAD (filename)

Input Parameters

filename—File path of PPM file.

Returned Value

image—An array (3, width, height) of bytes containing the 24-bit image.

Keywords

None.

Discussion

This function is used to read the rudimentary PPM binary files created by VTK and containing images stored as RGB values. The images can be displayed with TV, image, True=1 or converted to an 8-bit image using ipcolor_24_8.

Example

Example of reading the file wave.ppm and storing an image.

Image=vtkppmread('wave.ppm')

See Also

vtkPPMWRITEvtkTVRD