FreeMat

- Main Page
- Related Pages

vtkScalarTree

Section: Visualization Toolkit Filtering Classes

# Usage

vtkScalarTree is an abstract class that defines the API to concrete scalar tree subclasses. A scalar tree is a data structure that organizes data according to its scalar value. This allows rapid access to data for those algorithms that access the data based on scalar value. For example, isocontouring operates on cells based on the scalar (isocontour) value.

To use subclasses of this class, you must specify a dataset to operate on, and then specify a scalar value in the InitTraversal() method. Then calls to GetNextCell() return cells whose scalar data contains the scalar value specified.

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

      obj = vtkScalarTree

# Methods

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

- `string = obj.GetClassName ()`
- `int = obj.IsA (string name)`
- `vtkScalarTree = obj.NewInstance ()`
- `vtkScalarTree = obj.SafeDownCast (vtkObject o)`
- `obj.SetDataSet (vtkDataSet )` - Build the tree from the points/cells defining this dataset.
- `vtkDataSet = obj.GetDataSet ()` - Build the tree from the points/cells defining this dataset.
- `obj.BuildTree ()` - Construct the scalar tree from the dataset provided. Checks build times and modified time from input and reconstructs the tree if necessary.
- `obj.Initialize ()` - Initialize locator. Frees memory and resets object as appropriate.
- `obj.InitTraversal (double scalarValue)` - Begin to traverse the cells based on a scalar value. Returned cells will have scalar values that span the scalar value specified.