Main Page   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Related Pages  

vtkDataArray Class Reference

abstract superclass for arrays. More...

#include <vtkDataArray.h>

Inheritance diagram for vtkDataArray:

Inheritance graph
[legend]
Collaboration diagram for vtkDataArray:

Collaboration graph
[legend]
List of all members.

Public Methods

virtual const char * GetClassName ()
virtual int IsA (const char *type)
void PrintSelf (ostream &os, vtkIndent indent)
virtual vtkDataArray * MakeObject ()=0
virtual int GetDataType ()=0
virtual void SetNumberOfTuples (const vtkIdType number)=0
virtual float * GetTuple (const vtkIdType i)=0
void GetTuples (vtkIdList *ptIds, vtkDataArray *output)
void GetTuples (vtkIdType p1, vtkIdType p2, vtkDataArray *output)
virtual float GetComponent (const vtkIdType i, const int j)
virtual void SetComponent (const vtkIdType i, const int j, const float c)
virtual void InsertComponent (const vtkIdType i, const int j, const float c)
virtual void DeepCopy (vtkDataArray *da)
virtual void FillComponent (const int j, const float c)
virtual void * GetVoidPointer (const vtkIdType id)=0
virtual void Squeeze ()=0
virtual void Resize (vtkIdType numTuples)=0
unsigned long GetActualMemorySize ()
void CreateDefaultLookupTable ()
virtual void ComputeRange (int comp)
virtual float GetMaxNorm ()
virtual int Allocate (const vtkIdType sz, const vtkIdType ext=1000)=0
virtual void Initialize ()=0
virtual void SetNumberOfComponents (int)
int GetNumberOfComponents ()
vtkIdType GetNumberOfTuples ()
virtual void GetTuple (const vtkIdType i, float *tuple)=0
virtual void GetTuple (const vtkIdType i, double *tuple)
float GetTuple1 (const vtkIdType i)
float * GetTuple2 (const vtkIdType i)
float * GetTuple3 (const vtkIdType i)
float * GetTuple4 (const vtkIdType i)
float * GetTuple9 (const vtkIdType i)
virtual void SetTuple (const vtkIdType i, const float *tuple)=0
virtual void SetTuple (const vtkIdType i, const double *tuple)
void SetTuple1 (const vtkIdType i, float value)
void SetTuple2 (const vtkIdType i, float val0, float val1)
void SetTuple3 (const vtkIdType i, float val0, float val1, float val2)
void SetTuple4 (const vtkIdType i, float val0, float val1, float val2, float val3)
void SetTuple9 (const vtkIdType i, float val0, float val1, float val2, float val3, float val4, float val5, float val6, float val7, float val8)
virtual void InsertTuple (const vtkIdType i, const float *tuple)=0
virtual void InsertTuple (const vtkIdType i, const double *tuple)
void InsertTuple1 (const vtkIdType i, float value)
void InsertTuple2 (const vtkIdType i, float val0, float val1)
void InsertTuple3 (const vtkIdType i, float val0, float val1, float val2)
void InsertTuple4 (const vtkIdType i, float val0, float val1, float val2, float val3)
void InsertTuple9 (const vtkIdType i, float val0, float val1, float val2, float val3, float val4, float val5, float val6, float val7, float val8)
virtual vtkIdType InsertNextTuple (const float *tuple)=0
virtual vtkIdType InsertNextTuple (const double *tuple)
void InsertNextTuple1 (float value)
void InsertNextTuple2 (float val0, float val1)
void InsertNextTuple3 (float val0, float val1, float val2)
void InsertNextTuple4 (float val0, float val1, float val2, float val3)
void InsertNextTuple9 (float val0, float val1, float val2, float val3, float val4, float val5, float val6, float val7, float val8)
virtual void GetData (vtkIdType tupleMin, vtkIdType tupleMax, int compMin, int compMax, vtkFloatArray *data)
virtual void CopyComponent (const int j, vtkDataArray *from, const int fromComponent)
void Reset ()
vtkIdType GetSize ()
vtkIdType GetMaxId ()
virtual void SetVoidArray (void *vtkNotUsed(array), vtkIdType vtkNotUsed(size), int vtkNotUsed(save))
void SetLookupTable (vtkLookupTable *lut)
virtual vtkLookupTableGetLookupTable ()
void SetName (const char *name)
const char * GetName ()
void GetRange (float range[2], int comp)
float * GetRange (int comp)
float * GetRange ()
void GetRange (float range[2])
void GetDataTypeRange (double range[2])
double GetDataTypeMin ()
double GetDataTypeMax ()

Static Public Methods

int IsTypeOf (const char *type)
vtkDataArray * SafeDownCast (vtkObject *o)
vtkDataArray * CreateDataArray (int dataType)

Protected Methods

 vtkDataArray (vtkIdType numComp=1)
 ~vtkDataArray ()

Protected Attributes

vtkLookupTableLookupTable
vtkIdType Size
vtkIdType MaxId
int NumberOfComponents
char * Name

Detailed Description

abstract superclass for arrays.

Date:
2001/11/13 14:09:24
Revision:
1.41

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.

Each data array is required to have a character-string name. The naming of the array occurs automatically when it is instantiated, but you are free to name arrays using the SetName() method. (The array name is used for data manipulation.)

See also:
vtkBitArray vtkCharArray vtkUnsignedCharArray vtkShortArray vtkUnsignedShortArray vtkIntArray vtkUnsignedIntArray vtkLongArray vtkUnsignedLongArray vtkFloatArray vtkDoubleArray vtkVoidArray
Tests:
vtkDataArray (Tests)

Definition at line 85 of file vtkDataArray.h.


Constructor & Destructor Documentation

vtkDataArray::vtkDataArray vtkIdType    numComp = 1 [protected]
 

vtkDataArray::~vtkDataArray   [protected]
 


Member Function Documentation

virtual const char* vtkDataArray::GetClassName   [virtual]
 

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, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

int vtkDataArray::IsTypeOf const char *    type [static]
 

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, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

virtual int vtkDataArray::IsA const char *    type [virtual]
 

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, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

vtkDataArray* vtkDataArray::SafeDownCast vtkObject   o [static]
 

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, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

void vtkDataArray::PrintSelf ostream &    os,
vtkIndent    indent
[virtual]
 

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, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

virtual int vtkDataArray::Allocate const vtkIdType    sz,
const vtkIdType    ext = 1000
[pure virtual]
 

Allocate memory for this array. Delete old storage only if necessary. Note that ext is no longer used.

Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

virtual void vtkDataArray::Initialize   [pure virtual]
 

Allocate memory for this array. Delete old storage only if necessary. Note that ext is no longer used.

Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

virtual vtkDataArray* vtkDataArray::MakeObject   [pure virtual]
 

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, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

virtual int vtkDataArray::GetDataType   [pure virtual]
 

Return the underlying data type. An integer indicating data type is returned as specified in vtkSetGet.h.

Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

virtual void vtkDataArray::SetNumberOfComponents int    [virtual]
 

Set/Get the dimension (n) of the components. Must be >= 1. Make sure that this is set before allocation.

Referenced by vtkPoints::SetNumberOfPoints().

int vtkDataArray::GetNumberOfComponents   [inline]
 

Set/Get the dimension (n) of the components. Must be >= 1. Make sure that this is set before allocation.

Definition at line 111 of file vtkDataArray.h.

virtual void vtkDataArray::SetNumberOfTuples const vtkIdType    number [pure virtual]
 

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, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

Referenced by vtkPoints::SetNumberOfPoints().

vtkIdType vtkDataArray::GetNumberOfTuples   [inline]
 

Get the number of tuples (a component group) in the array.

Definition at line 120 of file vtkDataArray.h.

virtual float* vtkDataArray::GetTuple const vtkIdType    i [pure virtual]
 

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, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

virtual void vtkDataArray::GetTuple const vtkIdType    i,
float *    tuple
[pure virtual]
 

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, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

virtual void vtkDataArray::GetTuple const vtkIdType    i,
double *    tuple
[virtual]
 

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, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

float vtkDataArray::GetTuple1 const vtkIdType    i
 

These methods are included as convenience for the wrappers. GetTuple() and SetTuple() which return/take arrays can not be used from wrapped languages. These methods can be used instead.

float* vtkDataArray::GetTuple2 const vtkIdType    i
 

These methods are included as convenience for the wrappers. GetTuple() and SetTuple() which return/take arrays can not be used from wrapped languages. These methods can be used instead.

float* vtkDataArray::GetTuple3 const vtkIdType    i
 

These methods are included as convenience for the wrappers. GetTuple() and SetTuple() which return/take arrays can not be used from wrapped languages. These methods can be used instead.

float* vtkDataArray::GetTuple4 const vtkIdType    i
 

These methods are included as convenience for the wrappers. GetTuple() and SetTuple() which return/take arrays can not be used from wrapped languages. These methods can be used instead.

float* vtkDataArray::GetTuple9 const vtkIdType    i
 

These methods are included as convenience for the wrappers. GetTuple() and SetTuple() which return/take arrays can not be used from wrapped languages. These methods can be used instead.

void vtkDataArray::GetTuples vtkIdList   ptIds,
vtkDataArray *    output
 

Given a list of point ids, return an array of tuples. You must insure that the output array has been previously allocated with enough space to hold the data.

void vtkDataArray::GetTuples vtkIdType    p1,
vtkIdType    p2,
vtkDataArray *    output
 

Get the tuples for the range of points ids specified (i.e., p1->p2 inclusive). You must insure that the output array has been previously allocated with enough space to hold the data.

virtual void vtkDataArray::SetTuple const vtkIdType    i,
const float *    tuple
[pure virtual]
 

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, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

Referenced by vtkPoints::SetPoint().

virtual void vtkDataArray::SetTuple const vtkIdType    i,
const double *    tuple
[virtual]
 

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, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

void vtkDataArray::SetTuple1 const vtkIdType    i,
float    value
 

These methods are included as convenience for the wrappers. GetTuple() and SetTuple() which return/take arrays can not be used from wrapped languages. These methods can be used instead.

void vtkDataArray::SetTuple2 const vtkIdType    i,
float    val0,
float    val1
 

These methods are included as convenience for the wrappers. GetTuple() and SetTuple() which return/take arrays can not be used from wrapped languages. These methods can be used instead.

void vtkDataArray::SetTuple3 const vtkIdType    i,
float    val0,
float    val1,
float    val2
 

These methods are included as convenience for the wrappers. GetTuple() and SetTuple() which return/take arrays can not be used from wrapped languages. These methods can be used instead.

void vtkDataArray::SetTuple4 const vtkIdType    i,
float    val0,
float    val1,
float    val2,
float    val3
 

These methods are included as convenience for the wrappers. GetTuple() and SetTuple() which return/take arrays can not be used from wrapped languages. These methods can be used instead.

void vtkDataArray::SetTuple9 const vtkIdType    i,
float    val0,
float    val1,
float    val2,
float    val3,
float    val4,
float    val5,
float    val6,
float    val7,
float    val8
 

These methods are included as convenience for the wrappers. GetTuple() and SetTuple() which return/take arrays can not be used from wrapped languages. These methods can be used instead.

virtual void vtkDataArray::InsertTuple const vtkIdType    i,
const float *    tuple
[pure virtual]
 

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, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

Referenced by vtkPoints::InsertPoint().

virtual void vtkDataArray::InsertTuple const vtkIdType    i,
const double *    tuple
[virtual]
 

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, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

void vtkDataArray::InsertTuple1 const vtkIdType    i,
float    value
 

These methods are included as convenience for the wrappers. InsertTuple() which takes arrays can not be used from wrapped languages. These methods can be used instead.

void vtkDataArray::InsertTuple2 const vtkIdType    i,
float    val0,
float    val1
 

These methods are included as convenience for the wrappers. InsertTuple() which takes arrays can not be used from wrapped languages. These methods can be used instead.

void vtkDataArray::InsertTuple3 const vtkIdType    i,
float    val0,
float    val1,
float    val2
 

These methods are included as convenience for the wrappers. InsertTuple() which takes arrays can not be used from wrapped languages. These methods can be used instead.

void vtkDataArray::InsertTuple4 const vtkIdType    i,
float    val0,
float    val1,
float    val2,
float    val3
 

These methods are included as convenience for the wrappers. InsertTuple() which takes arrays can not be used from wrapped languages. These methods can be used instead.

void vtkDataArray::InsertTuple9 const vtkIdType    i,
float    val0,
float    val1,
float    val2,
float    val3,
float    val4,
float    val5,
float    val6,
float    val7,
float    val8
 

These methods are included as convenience for the wrappers. InsertTuple() which takes arrays can not be used from wrapped languages. These methods can be used instead.

virtual vtkIdType vtkDataArray::InsertNextTuple const float *    tuple [pure virtual]
 

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, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

Referenced by vtkPoints::InsertNextPoint().

virtual vtkIdType vtkDataArray::InsertNextTuple const double *    tuple [virtual]
 

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, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

void vtkDataArray::InsertNextTuple1 float    value
 

These methods are included as convenience for the wrappers. InsertTuple() which takes arrays can not be used from wrapped languages. These methods can be used instead.

void vtkDataArray::InsertNextTuple2 float    val0,
float    val1
 

These methods are included as convenience for the wrappers. InsertTuple() which takes arrays can not be used from wrapped languages. These methods can be used instead.

void vtkDataArray::InsertNextTuple3 float    val0,
float    val1,
float    val2
 

These methods are included as convenience for the wrappers. InsertTuple() which takes arrays can not be used from wrapped languages. These methods can be used instead.

void vtkDataArray::InsertNextTuple4 float    val0,
float    val1,
float    val2,
float    val3
 

These methods are included as convenience for the wrappers. InsertTuple() which takes arrays can not be used from wrapped languages. These methods can be used instead.

void vtkDataArray::InsertNextTuple9 float    val0,
float    val1,
float    val2,
float    val3,
float    val4,
float    val5,
float    val6,
float    val7,
float    val8
 

These methods are included as convenience for the wrappers. InsertTuple() which takes arrays can not be used from wrapped languages. These methods can be used instead.

virtual float vtkDataArray::GetComponent const vtkIdType    i,
const int    j
[virtual]
 

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.

virtual void vtkDataArray::SetComponent const vtkIdType    i,
const int    j,
const float    c
[virtual]
 

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 vtkBitArray, vtkCharArray, vtkFloatArray, vtkShortArray, vtkUnsignedCharArray, and vtkUnsignedShortArray.

virtual void vtkDataArray::InsertComponent const vtkIdType    i,
const int    j,
const float    c
[virtual]
 

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 vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, and vtkUnsignedShortArray.

virtual void vtkDataArray::GetData vtkIdType    tupleMin,
vtkIdType    tupleMax,
int    compMin,
int    compMax,
vtkFloatArray   data
[virtual]
 

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.

virtual void vtkDataArray::DeepCopy vtkDataArray *    da [virtual]
 

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, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

Referenced by vtkUnsignedShortArray::DeepCopy(), vtkUnsignedLongArray::DeepCopy(), vtkUnsignedIntArray::DeepCopy(), and vtkBitArray::SaveUserArray().

virtual void vtkDataArray::FillComponent const int    j,
const float    c
[virtual]
 

Fill a component of a data array with a specified value. This method sets the specified component to specified value for all tuples in the data array. This methods can be used to initialize or reinitialize a single component of a multi-component array.

virtual void vtkDataArray::CopyComponent const int    j,
vtkDataArray *    from,
const int    fromComponent
[virtual]
 

Copy a component from one data array into a component on this data array. This method copies the specified component ("fromComponent") from the specified data array ("from") to the specified component ("j") over all the tuples in this data array. This method can be used to extract a component (column) from one data array and paste that data into a component on this data array.

virtual void* vtkDataArray::GetVoidPointer const vtkIdType    id [pure virtual]
 

Return a void pointer. For image pipeline interface and other special pointer manipulation.

Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

virtual void vtkDataArray::Squeeze   [pure virtual]
 

Free any unnecessary memory.

Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

virtual void vtkDataArray::Resize vtkIdType    numTuples [pure virtual]
 

Resize the array while conserving the data.

Reimplemented in vtkBitArray, vtkCharArray, vtkDoubleArray, vtkFloatArray, vtkIdTypeArray, vtkIntArray, vtkLongArray, vtkShortArray, vtkUnsignedCharArray, vtkUnsignedIntArray, vtkUnsignedLongArray, vtkUnsignedShortArray, and vtkVoidArray.

void vtkDataArray::Reset   [inline]
 

Reset to an empty state, without freeing any memory.

Definition at line 284 of file vtkDataArray.h.

Referenced by vtkCellArray::Reset().

vtkIdType vtkDataArray::GetSize   [inline]
 

Return the size of the data.

Definition at line 290 of file vtkDataArray.h.

vtkIdType vtkDataArray::GetMaxId   [inline]
 

What is the maximum id currently in the array.

Definition at line 296 of file vtkDataArray.h.

Referenced by vtkPriorityQueue::DeleteId(), vtkCellArray::GetNextCell(), vtkPriorityQueue::GetPriority(), and vtkCellArray::InsertNextCell().

virtual void vtkDataArray::SetVoidArray void *vtkNotUsed(array)   ,
vtkIdType vtkNotUsed(size)   ,
int vtkNotUsed(save)   
[inline, virtual]
 

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 supplied array.

Definition at line 307 of file vtkDataArray.h.

unsigned long vtkDataArray::GetActualMemorySize  
 

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.

void vtkDataArray::CreateDefaultLookupTable  
 

Create default lookup table. Generally used to create one when none is available.

void vtkDataArray::SetLookupTable vtkLookupTable   lut
 

Set/get the lookup table associated with this scalar data, if any.

virtual vtkLookupTable* vtkDataArray::GetLookupTable   [virtual]
 

Set/get the lookup table associated with this scalar data, if any.

void vtkDataArray::SetName const char *    name
 

Set/get array's name

const char* vtkDataArray::GetName  
 

Set/get array's name

Referenced by vtkFieldData::GetArrayName().

void vtkDataArray::GetRange float    range[2],
int    comp
[inline]
 

Return the range of the array values for the given component. Range is copied into the array provided.

Definition at line 339 of file vtkDataArray.h.

float* vtkDataArray::GetRange int    comp [inline]
 

Return the range of the array values for the given component. Range is copied into the array provided.

Definition at line 344 of file vtkDataArray.h.

virtual void vtkDataArray::ComputeRange int    comp [virtual]
 

float* vtkDataArray::GetRange   [inline]
 

Return the range of the array values for the 0th component. Range is copied into the array provided.

Definition at line 355 of file vtkDataArray.h.

void vtkDataArray::GetRange float    range[2] [inline]
 

Return the range of the array values for the 0th component. Range is copied into the array provided.

Definition at line 360 of file vtkDataArray.h.

void vtkDataArray::GetDataTypeRange double    range[2]
 

These methods return the Min and Max possible range of the native data type. For example if a vtkScalars consists of unsigned char data these will return (0,255).

double vtkDataArray::GetDataTypeMin  
 

These methods return the Min and Max possible range of the native data type. For example if a vtkScalars consists of unsigned char data these will return (0,255).

double vtkDataArray::GetDataTypeMax  
 

These methods return the Min and Max possible range of the native data type. For example if a vtkScalars consists of unsigned char data these will return (0,255).

virtual float vtkDataArray::GetMaxNorm   [virtual]
 

Return the maximum norm for the tuples. Note that the max. is computed everytime GetMaxNorm is called.

vtkDataArray* vtkDataArray::CreateDataArray int    dataType [static]
 

Creates an array for dataType where dataType is one of VTK_BIT, VTK_CHAR, VTK_UNSIGNED_CHAR, VTK_SHORT, VTK_UNSIGNED_SHORT, VTK_INT, VTK_UNSIGNED_INT, VTK_LONG, VTK_UNSIGNED_LONG, VTK_FLOAT, VTK_DOUBLE, VTK_ID_TYPE. Note that the data array returned has be deleted by the user.


Member Data Documentation

vtkLookupTable* vtkDataArray::LookupTable [protected]
 

Definition at line 391 of file vtkDataArray.h.

vtkIdType vtkDataArray::Size [protected]
 

Definition at line 393 of file vtkDataArray.h.

vtkIdType vtkDataArray::MaxId [protected]
 

Definition at line 394 of file vtkDataArray.h.

int vtkDataArray::NumberOfComponents [protected]
 

Definition at line 395 of file vtkDataArray.h.

char* vtkDataArray::Name [protected]
 

Definition at line 397 of file vtkDataArray.h.


The documentation for this class was generated from the following file:
Generated on Thu Mar 28 14:28:28 2002 for VTK by doxygen1.2.11.1 written by Dimitri van Heesch, © 1997-2001