FreeMat
|
Section: Visualization Toolkit Filtering Classes
vtkGenericAttribute is an abstract class that defines an API for attribute data. Attribute data is data associated with the topology or geometry of a dataset (i.e., points, cells, etc.). vtkGenericAttribute is part of the adaptor framework (see GenericFiltering/README.html).
vtkGenericAttribute provides a more general interface to attribute data than its counterpart vtkDataArray (which assumes a linear, contiguous array). It adopts an iterator interface, and allows attributes to be associated with points, edges, faces, or edges.
To create an instance of class vtkGenericAttribute, simply invoke its constructor as follows
obj = vtkGenericAttribute
The class vtkGenericAttribute 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 vtkGenericAttribute class.
string = obj.GetClassName ()
int = obj.IsA (string name)
vtkGenericAttribute = obj.NewInstance ()
vtkGenericAttribute = obj.SafeDownCast (vtkObject o)
string = obj.GetName ()
- Name of the attribute. (e.g. "velocity") int = obj.GetNumberOfComponents ()
- Dimension of the attribute. (1 for scalar, 3 for velocity) int = obj.GetCentering ()
- Is the attribute centered either on points, cells or boundaries? int = obj.GetType ()
- Type of the attribute: scalar, vector, normal, texture coordinate, tensor int = obj.GetComponentType ()
- Type of the components of the attribute: int, float, double vtkIdType = obj.GetSize ()
- Number of tuples. long = obj.GetActualMemorySize ()
- Size in kilobytes taken by the attribute. obj.GetRange (int component, double range[2])
- Range of the attribute component `component'. If `component'==-1, it returns the range of the magnitude (euclidean norm). THREAD SAFE double = obj.GetMaxNorm ()
- Return the maximum euclidean norm for the tuples. obj.GetTuple (vtkGenericAdaptorCell c, double tuple)
- Put attribute at all points of cell `c' in `tuple'. obj.GetTuple (vtkGenericCellIterator c, double tuple)
- Put attribute at all points of cell `c' in `tuple'. obj.GetTuple (vtkGenericPointIterator p, double tuple)
- Put the value of the attribute at position `p' into `tuple'. obj.GetComponent (int i, vtkGenericCellIterator c, double values)
- Put component `i' of the attribute at all points of cell `c' in `values'. double = obj.GetComponent (int i, vtkGenericPointIterator p)
- Value of the component `i' of the attribute at position `p'. obj.DeepCopy (vtkGenericAttribute other)
- Recursive duplication of `other' in `this'. obj.ShallowCopy (vtkGenericAttribute other)
- Update `this' using fields of `other'.