FreeMat

- Main Page
- Related Pages

vtkImageDataLIC2D

Section: Visualization Toolkit Hybrid Classes

# Usage

GPU implementation of a Line Integral Convolution, a technique for imaging vector fields.

The input on port 0 is an vtkImageData with extents of a 2D image. It needs a vector field on point data. Port 1 is a special port for customized noise input. It is an optional port. If not present, noise is generated by the filter. Even if none-power-of-two texture are supported, giving a power-of-two image may result in faster execution on the GPU. If noise input is not specified, then the filter using vtkImageNoiseSource to generate a 128x128 noise texture. This filter only works on point vectors. One can use a vtkCellDataToPointData filter to convert cell vectors to point vectors.

.SECTION Required OpenGL Extensins GL_ARB_texture_non_power_of_two GL_VERSION_2_0 GL_ARB_texture_float GL_ARB_draw_buffers GL_EXT_framebuffer_object GL_ARB_pixel_buffer_object

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

      obj = vtkImageDataLIC2D

# Methods

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

- `string = obj.GetClassName ()`
- `int = obj.IsA (string name)`
- `vtkImageDataLIC2D = obj.NewInstance ()`
- `vtkImageDataLIC2D = obj.SafeDownCast (vtkObject o)`
- `int = obj.SetContext (vtkRenderWindow context)` - Get/Set the context. Context must be a vtkOpenGLRenderWindow. This does not increase the reference count of the context to avoid reference loops. SetContext() may raise an error is the OpenGL context does not support the required OpenGL extensions. Return 0 upon failure and 1 upon success.
- `vtkRenderWindow = obj.GetContext ()` - Get/Set the context. Context must be a vtkOpenGLRenderWindow. This does not increase the reference count of the context to avoid reference loops. SetContext() may raise an error is the OpenGL context does not support the required OpenGL extensions. Return 0 upon failure and 1 upon success.
- `obj.SetSteps (int )` - Number of steps. Initial value is 20. class invariant: Steps>0. In term of visual quality, the greater the better.
- `int = obj.GetSteps ()` - Number of steps. Initial value is 20. class invariant: Steps>0. In term of visual quality, the greater the better.
- `obj.SetStepSize (double )` - Step size. Specify the step size as a unit of the cell length of the input vector field. Cell lenghth is the length of the diagonal of a cell. Initial value is 1.0. class invariant: StepSize>0.0. In term of visual quality, the smaller the better. The type for the interface is double as VTK interface is double but GPU only supports float. This value will be converted to float in the execution of the algorithm.
- `double = obj.GetStepSizeMinValue ()` - Step size. Specify the step size as a unit of the cell length of the input vector field. Cell lenghth is the length of the diagonal of a cell. Initial value is 1.0. class invariant: StepSize>0.0. In term of visual quality, the smaller the better. The type for the interface is double as VTK interface is double but GPU only supports float. This value will be converted to float in the execution of the algorithm.
- `double = obj.GetStepSizeMaxValue ()` - Step size. Specify the step size as a unit of the cell length of the input vector field. Cell lenghth is the length of the diagonal of a cell. Initial value is 1.0. class invariant: StepSize>0.0. In term of visual quality, the smaller the better. The type for the interface is double as VTK interface is double but GPU only supports float. This value will be converted to float in the execution of the algorithm.
- `double = obj.GetStepSize ()` - Step size. Specify the step size as a unit of the cell length of the input vector field. Cell lenghth is the length of the diagonal of a cell. Initial value is 1.0. class invariant: StepSize>0.0. In term of visual quality, the smaller the better. The type for the interface is double as VTK interface is double but GPU only supports float. This value will be converted to float in the execution of the algorithm.
- `obj.SetMagnification (int )` - The the magnification factor. Default is 1
- `int = obj.GetMagnificationMinValue ()` - The the magnification factor. Default is 1
- `int = obj.GetMagnificationMaxValue ()` - The the magnification factor. Default is 1
- `int = obj.GetMagnification ()` - The the magnification factor. Default is 1
- `int = obj.GetOpenGLExtensionsSupported ()` - Check if the required OpenGL extensions / GPU are supported.
- `int = obj.GetFBOSuccess ()` - Check if LIC runs properly.
- `int = obj.GetLICSuccess ()`
- `obj.TranslateInputExtent (int inExt, int inWholeExtent, int outExt)`