FreeMat: vtkJPEGWriter

FreeMat

- Main Page
- Related Pages

vtkJPEGWriter

Section: Visualization Toolkit IO Classes

# Usage

vtkJPEGWriter writes JPEG files. It supports 1 and 3 component data of unsigned char. It relies on the IJG's libjpeg. Thanks to IJG for supplying a public jpeg IO library.

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

      obj = vtkJPEGWriter

# Methods

The class vtkJPEGWriter 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 vtkJPEGWriter class.

- `string = obj.GetClassName ()`
- `int = obj.IsA (string name)`
- `vtkJPEGWriter = obj.NewInstance ()`
- `vtkJPEGWriter = obj.SafeDownCast (vtkObject o)`
- `obj.Write ()` - The main interface which triggers the writer to start.
- `obj.SetQuality (int )` - Compression quality. 0 = Low quality, 100 = High quality
- `int = obj.GetQualityMinValue ()` - Compression quality. 0 = Low quality, 100 = High quality
- `int = obj.GetQualityMaxValue ()` - Compression quality. 0 = Low quality, 100 = High quality
- `int = obj.GetQuality ()` - Compression quality. 0 = Low quality, 100 = High quality
- `obj.SetProgressive (int )` - Progressive JPEG generation.
- `int = obj.GetProgressive ()` - Progressive JPEG generation.
- `obj.ProgressiveOn ()` - Progressive JPEG generation.
- `obj.ProgressiveOff ()` - Progressive JPEG generation.
- `obj.SetWriteToMemory (int )` - Write the image to memory (a vtkUnsignedCharArray)
- `int = obj.GetWriteToMemory ()` - Write the image to memory (a vtkUnsignedCharArray)
- `obj.WriteToMemoryOn ()` - Write the image to memory (a vtkUnsignedCharArray)
- `obj.WriteToMemoryOff ()` - Write the image to memory (a vtkUnsignedCharArray)
- `obj.SetResult (vtkUnsignedCharArray )` - When writing to memory this is the result, it will be NULL until the data is written the first time
- `vtkUnsignedCharArray = obj.GetResult ()` - When writing to memory this is the result, it will be NULL until the data is written the first time