FreeMat: vtkImageWriter

FreeMat

- Main Page
- Related Pages

vtkImageWriter

Section: Visualization Toolkit IO Classes

# Usage

vtkImageWriter writes images to files with any data type. The data type of the file is the same scalar type as the input. The dimensionality determines whether the data will be written in one or multiple files. This class is used as the superclass of most image writing classes such as vtkBMPWriter etc. It supports streaming.

To create an instance of class vtkImageWriter, simply invoke its constructor as follows

      obj = vtkImageWriter

# Methods

The class vtkImageWriter has several methods that can be used. They are listed below. Note that the documentation is translated automatically from the VTK sources, and may not be completely intelligible. When in doubt, consult the VTK website. In the methods listed below, `obj` is an instance of the vtkImageWriter class.

- `string = obj.GetClassName ()`
- `int = obj.IsA (string name)`
- `vtkImageWriter = obj.NewInstance ()`
- `vtkImageWriter = obj.SafeDownCast (vtkObject o)`
- `obj.SetFileName (string )` - Specify file name for the image file. You should specify either a FileName or a FilePrefix. Use FilePrefix if the data is stored in multiple files.
- `string = obj.GetFileName ()` - Specify file name for the image file. You should specify either a FileName or a FilePrefix. Use FilePrefix if the data is stored in multiple files.
- `obj.SetFilePrefix (string )` - Specify file prefix for the image file(s).You should specify either a FileName or FilePrefix. Use FilePrefix if the data is stored in multiple files.
- `string = obj.GetFilePrefix ()` - Specify file prefix for the image file(s).You should specify either a FileName or FilePrefix. Use FilePrefix if the data is stored in multiple files.
- `obj.SetFilePattern (string )` - The sprintf format used to build filename from FilePrefix and number.
- `string = obj.GetFilePattern ()` - The sprintf format used to build filename from FilePrefix and number.
- `obj.SetFileDimensionality (int )` - What dimension are the files to be written. Usually this is 2, or 3. If it is 2 and the input is a volume then the volume will be written as a series of 2d slices.
- `int = obj.GetFileDimensionality ()` - What dimension are the files to be written. Usually this is 2, or 3. If it is 2 and the input is a volume then the volume will be written as a series of 2d slices.
- `obj.Write ()` - The main interface which triggers the writer to start.
- `obj.DeleteFiles ()`