FreeMat: vtkSphericalDirectionEncoder

FreeMat

- Main Page
- Related Pages

vtkSphericalDirectionEncoder

Section: Visualization Toolkit Volume Rendering Classes

# Usage

vtkSphericalDirectionEncoder is a direction encoder which uses spherical coordinates for mapping (nx, ny, nz) into an azimuth, elevation pair.

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

      obj = vtkSphericalDirectionEncoder

# Methods

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

- `string = obj.GetClassName ()`
- `int = obj.IsA (string name)`
- `vtkSphericalDirectionEncoder = obj.NewInstance ()`
- `vtkSphericalDirectionEncoder = obj.SafeDownCast (vtkObject o)`
- `int = obj.GetEncodedDirection (float n[3])` - Given a normal vector n, return the encoded direction
- `float = obj.GetDecodedGradient (int value)` - / Given an encoded value, return a pointer to the normal vector
- `int = obj.GetNumberOfEncodedDirections (void )` - Get the decoded gradient table. There are this->GetNumberOfEncodedDirections() entries in the table, each containing a normal (direction) vector. This is a flat structure - 3 times the number of directions floats in an array.