FreeMat: vtkDijkstraImageContourLineInterpolator

FreeMat

- Main Page
- Related Pages

vtkDijkstraImageContourLineInterpolator

Section: Visualization Toolkit Widget Classes

# Usage

vtkDijkstraImageContourLineInterpolator interpolates and places contour points on images. The class interpolates nodes by computing a graph lying on the image data. By graph, we mean that the line interpolating the two end points traverses along pixels so as to form a shortest path. A Dijkstra algorithm is used to compute the path.

The class is meant to be used in conjunction with vtkImageActorPointPlacer. One reason for this coupling is a performance issue: both classes need to perform a cell pick, and coupling avoids multiple cell picks (cell picks are slow). Another issue is that the interpolator may need to set the image input to its vtkDijkstraImageGeodesicPath ivar.

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

      obj = vtkDijkstraImageContourLineInterpolator

# Methods

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

- `string = obj.GetClassName ()` - Standard methods for instances of this class.
- `int = obj.IsA (string name)` - Standard methods for instances of this class.
- `vtkDijkstraImageContourLineInterpolator = obj.NewInstance ()` - Standard methods for instances of this class.
- `vtkDijkstraImageContourLineInterpolator = obj.SafeDownCast (vtkObject o)` - Standard methods for instances of this class.
- `int = obj.InterpolateLine (vtkRenderer ren, vtkContourRepresentation rep, int idx1, int idx2)` - Subclasses that wish to interpolate a line segment must implement this. For instance vtkBezierContourLineInterpolator adds nodes between idx1 and idx2, that allow the contour to adhere to a bezier curve.
- `obj.SetCostImage (vtkImageData )` - Set the image data for the vtkDijkstraImageGeodesicPath. If not set, the interpolator uses the image data input to the image actor. The image actor is obtained from the expected vtkImageActorPointPlacer.
- `vtkImageData = obj.GetCostImage ()` - Set the image data for the vtkDijkstraImageGeodesicPath. If not set, the interpolator uses the image data input to the image actor. The image actor is obtained from the expected vtkImageActorPointPlacer.
- `vtkDijkstraImageGeodesicPath = obj.GetDijkstraImageGeodesicPath ()` - access to the internal dijkstra path