#include <vtkDataArray.h>
Inheritance diagram for vtkDataArray:
Public Methods | |
virtual const char * | GetClassName () |
virtual int | IsA (const char *type) |
void | PrintSelf (ostream &os, vtkIndent indent) |
virtual int | Allocate (const int sz, const int ext=1000)=0 |
virtual void | Initialize ()=0 |
virtual vtkDataArray * | MakeObject ()=0 |
virtual int | GetDataType ()=0 |
virtual void | SetNumberOfComponents (int) |
int | GetNumberOfComponents () |
virtual void | SetNumberOfTuples (const int number)=0 |
int | GetNumberOfTuples () |
virtual float * | GetTuple (const int i)=0 |
virtual void | GetTuple (const int i, float *tuple)=0 |
virtual void | GetTuple (const int i, double *tuple) |
virtual void | SetTuple (const int i, const float *tuple)=0 |
virtual void | SetTuple (const int i, const double *tuple) |
virtual void | InsertTuple (const int i, const float *tuple)=0 |
virtual void | InsertTuple (const int i, const double *tuple) |
virtual int | InsertNextTuple (const float *tuple)=0 |
virtual int | InsertNextTuple (const double *tuple) |
virtual float | GetComponent (const int i, const int j) |
virtual void | SetComponent (const int i, const int j, const float c) |
virtual void | InsertComponent (const int i, const int j, const float c) |
virtual void | GetData (int tupleMin, int tupleMax, int compMin, int compMax, vtkFloatArray &data) |
virtual void | DeepCopy (vtkDataArray *da) |
virtual void * | GetVoidPointer (const int id)=0 |
virtual void | Squeeze ()=0 |
void | Reset () |
int | GetSize () |
int | GetMaxId () |
int | GetExtend () |
virtual void | SetVoidArray (void *vtkNotUsed(array), int vtkNotUsed(size), int vtkNotUsed(save)) |
unsigned long | GetActualMemorySize () |
void | DeepCopy (vtkDataArray &da) |
Static Public Methods | |
int | IsTypeOf (const char *type) |
vtkDataArray * | SafeDownCast (vtkObject *o) |
Protected Methods | |
vtkDataArray (int numComp=1) | |
~vtkDataArray () | |
vtkDataArray (const vtkDataArray &) | |
void | operator= (const vtkDataArray &) |
Protected Attributes | |
int | Size |
int | MaxId |
int | Extend |
int | NumberOfComponents |
vtkDataArray is an abstract superclass for data array objects. This class defines an API that all array objects must support. Note that the concrete subclasses of this class represent data in native form (char, int, etc.) and often have specialized more efficient methods for operating on this data (for example, getting pointers to data or getting/inserting data in native form).
The logical structure of this class is an array of tuples, where each tuple is made up of n-components (also called a component group), and n is the number of component values in a tuple(n >= 1). Another view of this class is a mxn matrix, where m is the number of tuples, and n is the number of components in a tuple. Thus vtkDataArray can be used to represent scalars (1-4 components), 3D vectors (3 components), texture coordinates (1-3 components), tensors, (9 components) and so on.
Definition at line 76 of file vtkDataArray.h.
|
|
|
Definition at line 215 of file vtkDataArray.h. |
|
Definition at line 216 of file vtkDataArray.h. |
|
Return the class name as a string. This method is defined in all subclasses of vtkObject with the vtkTypeMacro found in vtkSetGet.h. Reimplemented from vtkObject. Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray. |
|
Return 1 if this class type is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h. Reimplemented from vtkObject. Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray. |
|
Return 1 if this class is the same type of (or a subclass of) the named class. Returns 0 otherwise. This method works in combination with vtkTypeMacro found in vtkSetGet.h. Reimplemented from vtkObject. Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray. |
|
Will cast the supplied object to vtkObject* is this is a safe operation (i.e., a safe downcast); otherwise NULL is returned. This method is defined in all subclasses of vtkObject with the vtkTypeMacro found in vtkSetGet.h. Reimplemented from vtkObject. Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray. |
|
Methods invoked by print to print information about the object including superclasses. Typically not called by the user (use Print() instead) but used in the hierarchical print process to combine the output of several classes. Reimplemented from vtkObject. Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray. |
|
|
|
Virtual constructor creates an object of the same type as this one. The created object also has the same number of components. You are responsible for freeing the object. Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray. |
|
Return the underlying data type. An integer indicating data type is returned as specified in vtkSetGet.h. Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray. Referenced by vtkFloatVectors::SetData(), vtkFloatTensors::SetData(), vtkFloatTCoords::SetData(), vtkFloatScalars::SetData(), vtkFloatPoints::SetData(), and vtkFloatNormals::SetData().
|
|
Set/Get the dimension (n) of the components. Must be >= 1. Make sure that this is set before allocation. |
|
Definition at line 97 of file vtkDataArray.h. |
|
Set the number of tuples (a component group) in the array. Note that this may allocate space depending on the number of components. Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray. |
|
Get the number of tuples (a component group) in the array. Definition at line 104 of file vtkDataArray.h. |
|
Get the data tuple at ith location. Return it as a pointer to an array. Note: this method is not thread-safe, and the pointer is only valid as long as another method invocation to a vtk object is not performed. Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray. |
|
Get the data tuple at ith location by filling in a user-provided array, Make sure that your array is large enough to hold the NumberOfComponents amount of data being returned. Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray. |
|
|
Set the data tuple at ith location. Note that range checking or memory allocation is not performed; use this method in conjunction with SetNumberOfTuples() to allocate space. Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray. |
|
|
Insert the data tuple at ith location. Note that memory allocation is performed as necessary to hold the data. Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray. |
|
|
Insert the data tuple at the end of the array and return the location at which the data was inserted. Memory is allocated as necessary to hold the data. Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray. |
|
|
Return the data component at the ith tuple and jth component location. Note that i is less than NumberOfTuples and j is less than NumberOfComponents. Reimplemented in vtkCharArray, vtkFloatArray, vtkShortArray, vtkUnsignedCharArray, and vtkUnsignedShortArray. |
|
Set the data component at the ith tuple and jth component location. Note that i is less than NumberOfTuples and j is less than NumberOfComponents. Make sure enough memory has been allocated (use SetNumberOfTuples() and SetNumberOfComponents()). Reimplemented in vtkCharArray, vtkFloatArray, vtkShortArray, vtkUnsignedCharArray, and vtkUnsignedShortArray. |
|
Insert the data component at ith tuple and jth component location. Note that memory allocation is performed as necessary to hold the data. Reimplemented in vtkCharArray, vtkFloatArray, vtkShortArray, vtkUnsignedCharArray, and vtkUnsignedShortArray. |
|
Get the data as a float array in the range (tupleMin,tupleMax) and (compMin, compMax). The resulting float array consists of all data in the tuple range specified and only the component range specified. This process typically requires casting the data from native form into floating point values. This method is provided as a convenience for data exchange, and is not very fast. |
|
Deep copy of data. Copies data from different data arrays even if they are different types (using floating-point exchange). Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray. Referenced by vtkVoidArray::DeepCopy(), vtkUnsignedShortArray::DeepCopy(), vtkUnsignedLongArray::DeepCopy(), vtkUnsignedIntArray::DeepCopy(), vtkUnsignedCharArray::DeepCopy(), vtkShortArray::DeepCopy(), vtkLongArray::DeepCopy(), vtkIntArray::DeepCopy(), vtkFloatArray::DeepCopy(), vtkDoubleArray::DeepCopy(), vtkCharArray::DeepCopy(), vtkBitArray::DeepCopy(), and vtkBitArray::SaveUserArray().
|
|
Return a void pointer. For image pipeline interface and other special pointer manipulation. Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray. |
|
Free any unnecessary memory. Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray. |
|
Reset to an empty state, without freeing any memory. Definition at line 173 of file vtkDataArray.h. Referenced by vtkCellArray::Reset().
|
|
Return the size of the data. Definition at line 177 of file vtkDataArray.h. |
|
What is the maximum id currently in the array. Definition at line 181 of file vtkDataArray.h. Referenced by vtkPriorityQueue::DeleteId(), vtkCellArray::GetNextCell(), vtkPriorityQueue::GetPriority(), and vtkCellArray::InsertNextCell().
|
|
By how many elements should the array increase when more memory is required. Definition at line 186 of file vtkDataArray.h. |
|
This method lets the user specify data to be held by the array. The array argument is a pointer to the data. size is the size of the array supplied by the user. Set save to 1 to keep the class from deleting the array when it cleans up or reallocates memory. The class uses the actual array provided; it does not copy the data from the suppled array. Definition at line 195 of file vtkDataArray.h. |
|
Return the memory in kilobytes consumed by this data array. Used to support streaming and reading/writing data. The value returned is guaranteed to be greater than or equal to the memory required to actually represent the data represented by this object. The information returned is valid only after the pipeline has been updated. |
|
For legacy compatibility. Do not use. Reimplemented in vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray. Definition at line 208 of file vtkDataArray.h. |
|
Definition at line 217 of file vtkDataArray.h. |
|
Definition at line 219 of file vtkDataArray.h. |
|
Definition at line 220 of file vtkDataArray.h. |
|
Definition at line 221 of file vtkDataArray.h. |
|
Definition at line 222 of file vtkDataArray.h. |