VTK
Public Member Functions | Static Public Member Functions | Protected Member Functions | List of all members
vtkMappedDataArray< Scalar > Class Template Referenceabstract

Map non-contiguous data structures into the vtkDataArray API. More...

#include <vtkMappedDataArray.h>

Inheritance diagram for vtkMappedDataArray< Scalar >:
[legend]
Collaboration diagram for vtkMappedDataArray< Scalar >:
[legend]

Public Member Functions

void PrintSelf (ostream &os, vtkIndent indent)
 Methods invoked by print to print information about the object including superclasses. More...
 
void DeepCopy (vtkAbstractArray *aa)=0
 Deep copy of data. More...
 
vtkVariant GetVariantValue (vtkIdType idx)=0
 Retrieve value from the array as a variant. More...
 
void SetVariantValue (vtkIdType idx, vtkVariant value)=0
 Set a value in the array from a variant. More...
 
void GetTuples (vtkIdList *ptIds, vtkAbstractArray *output)=0
 Given a list of tuple ids, return an array of tuples. More...
 
void GetTuples (vtkIdType p1, vtkIdType p2, vtkAbstractArray *output)=0
 Get the tuples for the range of tuple ids specified (i.e., p1->p2 inclusive). More...
 
void InterpolateTuple (vtkIdType i, vtkIdList *ptIndices, vtkAbstractArray *source, double *weights)=0
 Set the tuple at dstTupleIdx in this array to the interpolated tuple value, given the ptIndices in the source array and associated interpolation weights. More...
 
void InterpolateTuple (vtkIdType i, vtkIdType id1, vtkAbstractArray *source1, vtkIdType id2, vtkAbstractArray *source2, double t)=0
 Insert the tuple at dstTupleIdx in this array to the tuple interpolated from the two tuple indices, srcTupleIdx1 and srcTupleIdx2, and an interpolation factor, t. More...
 
void DeepCopy (vtkDataArray *da)=0
 Deep copy of data. More...
 
void * GetVoidPointer (vtkIdType id)
 Print an error and create an internal, long-lived temporary array. More...
 
void ExportToVoidPointer (void *ptr)
 Copy the internal data to the void pointer. More...
 
void DataChanged ()
 Read the data from the internal temporary array (created by GetVoidPointer) back into the mapped array. More...
 
void Modified ()
 Invalidate the internal temporary array and call superclass method. More...
 
bool HasStandardMemoryLayout ()
 Returns true if this array uses the standard memory layout defined in the VTK user guide, e.g. More...
 
void SetVoidArray (void *, vtkIdType, int)
 These methods don't make sense for mapped data array. More...
 
void SetVoidArray (void *, vtkIdType, int, int)
 These methods don't make sense for mapped data array. More...
 
void * WriteVoidPointer (vtkIdType, vtkIdType)
 Not implemented. More...
 
- Public Member Functions inherited from vtkTypedDataArray< Scalar >
Iterator Begin ()
 Return an iterator initialized to the first element of the data. More...
 
Iterator End ()
 Return an iterator initialized to first element past the end of the data. More...
 
int GetDataType () override
 Return the VTK data type held by this array. More...
 
int GetDataTypeSize () override
 Return the size of the element type in bytes. More...
 
void SetNumberOfValues (vtkIdType num) override
 Specify the number of values for this object to hold. More...
 
virtual void SetTypedTuple (vtkIdType i, const ValueType *t)=0
 Set the tuple value at the ith location in the array. More...
 
virtual void InsertTypedTuple (vtkIdType i, const ValueType *t)=0
 Insert (memory allocation performed) the tuple into the ith location in the array. More...
 
virtual vtkIdType InsertNextTypedTuple (const ValueType *t)=0
 Insert (memory allocation performed) the tuple onto the end of the array. More...
 
virtual ValueType GetValue (vtkIdType idx) const =0
 Get the data at a particular index. More...
 
virtual ValueTypeGetValueReference (vtkIdType idx)=0
 Get a reference to the scalar value at a particular index. More...
 
virtual void SetValue (vtkIdType idx, ValueType value)=0
 Set the data at a particular index. More...
 
virtual void GetTypedTuple (vtkIdType idx, ValueType *t) const =0
 Copy the tuple value into a user-provided array. More...
 
virtual vtkIdType InsertNextValue (ValueType v)=0
 Insert data at the end of the array. More...
 
virtual void InsertValue (vtkIdType idx, ValueType v)=0
 Insert data at a specified position in the array. More...
 
virtual ValueType GetTypedComponent (vtkIdType tupleIdx, int comp) const
 
virtual void SetTypedComponent (vtkIdType tupleIdx, int comp, ValueType v)
 
int GetArrayType () override
 Method for type-checking in FastDownCast implementations. More...
 
virtual int Allocate (vtkIdType size, vtkIdType ext=1000)=0
 Allocate memory for this array. More...
 
virtual int Resize (vtkIdType numTuples)=0
 Resize the array to the requested number of tuples and preserve data. More...
 
- Public Member Functions inherited from vtkGenericDataArray< vtkTypedDataArray< Scalar >, Scalar >
 vtkTemplateTypeMacro (SelfType, vtkDataArray) enum
 Compile time access to the VTK type identifier. More...
 
ValueType GetValue (vtkIdType valueIdx) const
 Get the value at valueIdx. More...
 
void SetValue (vtkIdType valueIdx, ValueType value)
 Set the value at valueIdx to value. More...
 
void GetTypedTuple (vtkIdType tupleIdx, ValueType *tuple) const
 Copy the tuple at tupleIdx into tuple. More...
 
void SetTypedTuple (vtkIdType tupleIdx, const ValueType *tuple)
 Set this array's tuple at tupleIdx to the values in tuple. More...
 
ValueType GetTypedComponent (vtkIdType tupleIdx, int compIdx) const
 Get component compIdx of the tuple at tupleIdx. More...
 
void SetTypedComponent (vtkIdType tupleIdx, int compIdx, ValueType value)
 Set component compIdx of the tuple at tupleIdx to value. More...
 
void RemoveTuple (vtkIdType tupleIdx) override
 Removes a tuple at the given index. More...
 
vtkIdType InsertNextValue (ValueType value)
 Insert data at the end of the array. More...
 
void InsertValue (vtkIdType valueIdx, ValueType value)
 Insert data at a specified position in the array. More...
 
void InsertTypedTuple (vtkIdType tupleIdx, const ValueType *t)
 Insert (memory allocation performed) the tuple t at tupleIdx. More...
 
vtkIdType InsertNextTypedTuple (const ValueType *t)
 Insert (memory allocation performed) the tuple onto the end of the array. More...
 
void InsertTypedComponent (vtkIdType tupleIdx, int compIdx, ValueType val)
 Insert (memory allocation performed) the value at the specified tuple and component location. More...
 
ValueTypeGetValueRange ()
 Get the range of array values for the 0th component in the native data type. More...
 
void GetValueRange (ValueType range[2])
 
vtkIdType Capacity ()
 Return the capacity in typeof T units of the current array. More...
 
int GetDataType () override
 Return the underlying data type. More...
 
int GetDataTypeSize () override
 Return the size of the underlying data type. More...
 
bool HasStandardMemoryLayout () override
 Returns true if this array uses the standard memory layout defined in the VTK user guide, e.g. More...
 
int Allocate (vtkIdType size, vtkIdType ext=1000) override
 Allocate memory for this array. More...
 
int Resize (vtkIdType numTuples) override
 Resize the array to the requested number of tuples and preserve data. More...
 
void SetNumberOfComponents (int num) override
 Set/Get the dimension (n) of the components. More...
 
void SetNumberOfTuples (vtkIdType number) override
 Set the number of tuples (a component group) in the array. More...
 
void Initialize () override
 Release storage and reset array to initial state. More...
 
void Squeeze () override
 Free any unnecessary memory. More...
 
void SetTuple (vtkIdType dstTupleIdx, vtkIdType srcTupleIdx, vtkAbstractArray *source) override
 Set the tuple at dstTupleIdx in this array to the tuple at srcTupleIdx in the source array. More...
 
void SetTuple (vtkIdType tupleIdx, const float *tuple) override
 Set the data tuple at tupleIdx. More...
 
void SetTuple (vtkIdType tupleIdx, const double *tuple) override
 Set the data tuple at tupleIdx. More...
 
void InsertTuples (vtkIdList *dstIds, vtkIdList *srcIds, vtkAbstractArray *source) override
 Copy the tuples indexed in srcIds from the source array to the tuple locations indexed by dstIds in this array. More...
 
void InsertTuples (vtkIdType dstStart, vtkIdType n, vtkIdType srcStart, vtkAbstractArray *source) override
 Copy n consecutive tuples starting at srcStart from the source array to this array, starting at the dstStart location. More...
 
void InsertTuple (vtkIdType dstTupleIdx, vtkIdType srcTupleIdx, vtkAbstractArray *source) override
 Insert the tuple at srcTupleIdx in the source array into this array at dstTupleIdx. More...
 
void InsertTuple (vtkIdType tupleIdx, const float *source) override
 Insert the data tuple at tupleIdx. More...
 
void InsertTuple (vtkIdType tupleIdx, const double *source) override
 Insert the data tuple at tupleIdx. More...
 
void InsertComponent (vtkIdType tupleIdx, int compIdx, double value) override
 Insert value at the location specified by tupleIdx and compIdx. More...
 
vtkIdType InsertNextTuple (vtkIdType srcTupleIdx, vtkAbstractArray *source) override
 Insert the tuple from srcTupleIdx in the source array at the end of this array. More...
 
vtkIdType InsertNextTuple (const float *tuple) override
 Insert the data tuple at the end of the array and return the tuple index at which the data was inserted. More...
 
vtkIdType InsertNextTuple (const double *tuple) override
 Insert the data tuple at the end of the array and return the tuple index at which the data was inserted. More...
 
void GetTuples (vtkIdList *tupleIds, vtkAbstractArray *output) override
 Given a list of tuple ids, return an array of tuples. More...
 
void GetTuples (vtkIdType p1, vtkIdType p2, vtkAbstractArray *output) override
 Get the tuples for the range of tuple ids specified (i.e., p1->p2 inclusive). More...
 
doubleGetTuple (vtkIdType tupleIdx) override
 Get the data tuple at tupleIdx. More...
 
void GetTuple (vtkIdType tupleIdx, double *tuple) override
 Get the data tuple at tupleIdx by filling in a user-provided array, Make sure that your array is large enough to hold the NumberOfComponents amount of data being returned. More...
 
void InterpolateTuple (vtkIdType dstTupleIdx, vtkIdList *ptIndices, vtkAbstractArray *source, double *weights) override
 Set the tuple at dstTupleIdx in this array to the interpolated tuple value, given the ptIndices in the source array and associated interpolation weights. More...
 
void InterpolateTuple (vtkIdType dstTupleIdx, vtkIdType srcTupleIdx1, vtkAbstractArray *source1, vtkIdType srcTupleIdx2, vtkAbstractArray *source2, double t) override
 Insert the tuple at dstTupleIdx in this array to the tuple interpolated from the two tuple indices, srcTupleIdx1 and srcTupleIdx2, and an interpolation factor, t. More...
 
void SetComponent (vtkIdType tupleIdx, int compIdx, double value) override
 Set the data component at the location specified by tupleIdx and compIdx to value. More...
 
double GetComponent (vtkIdType tupleIdx, int compIdx) override
 Return the data component at the location specified by tupleIdx and compIdx. More...
 
void SetVariantValue (vtkIdType valueIdx, vtkVariant value) override
 Set a value in the array from a variant. More...
 
vtkVariant GetVariantValue (vtkIdType valueIdx) override
 Retrieve value from the array as a variant. More...
 
void InsertVariantValue (vtkIdType valueIdx, vtkVariant value) override
 Insert a value into the array from a variant. More...
 
vtkIdType LookupValue (vtkVariant value) override
 Return the value indices where a specific value appears. More...
 
void LookupValue (vtkVariant value, vtkIdList *valueIds) override
 Return the value indices where a specific value appears. More...
 
virtual vtkIdType LookupTypedValue (ValueType value)
 
virtual void LookupTypedValue (ValueType value, vtkIdList *valueIds)
 
void ClearLookup () override
 Delete the associated fast lookup data structure on this array, if it exists. More...
 
void DataChanged () override
 Tell the array explicitly that the data has changed. More...
 
VTK_NEWINSTANCE vtkArrayIteratorNewIterator () override
 Subclasses must override this method and provide the right kind of templated vtkArrayIteratorTemplate. More...
 
void * GetVoidPointer (vtkIdType valueIdx) override
 Default implementation raises a runtime error. More...
 
ValueTypeGetPointer (vtkIdType valueIdx)
 Default implementation raises a runtime error. More...
 
void SetVoidArray (void *, vtkIdType, int) override
 Default implementation raises a runtime error. More...
 
void SetVoidArray (void *, vtkIdType, int, int) override
 Default implementation raises a runtime error. More...
 
void * WriteVoidPointer (vtkIdType valueIdx, vtkIdType numValues) override
 Default implementation raises a runtime error. More...
 
ValueTypeWritePointer (vtkIdType valueIdx, vtkIdType numValues)
 Default implementation raises a runtime error. More...
 
void GetValueRange (ValueType range[2], int comp)
 Get the range of array values for the given component in the native data type. More...
 
ValueTypeGetValueRange (int comp)
 Get the range of array values for the given component in the native data type. More...
 
- Public Member Functions inherited from vtkDataArray
virtual int IsA (const char *type)
 Return 1 if this class is the same type of (or a subclass of) the named class. More...
 
vtkDataArrayNewInstance () const
 
int IsNumeric () override
 This method is here to make backward compatibility easier. More...
 
int GetElementComponentSize () override
 Return the size, in bytes, of the lowest-level element of an array. More...
 
virtual void GetData (vtkIdType tupleMin, vtkIdType tupleMax, int compMin, int compMax, vtkDoubleArray *data)
 Get the data as a double array in the range (tupleMin,tupleMax) and (compMin, compMax). More...
 
virtual void ShallowCopy (vtkDataArray *other)
 Create a shallow copy of other into this, if possible. More...
 
virtual void FillComponent (int compIdx, double value)
 Fill a component of a data array with a specified value. More...
 
virtual void CopyComponent (int dstComponent, vtkDataArray *src, int srcComponent)
 Copy a component from one data array into a component on this data array. More...
 
unsigned long GetActualMemorySize () override
 Return the memory in kibibytes (1024 bytes) consumed by this data array. More...
 
void CreateDefaultLookupTable ()
 Create default lookup table. More...
 
void GetRange (double range[2], int comp)
 The range of the data array values for the given component will be returned in the provided range array argument. More...
 
doubleGetRange ()
 Return the range of the data array. More...
 
void GetRange (double range[2])
 The the range of the data array values will be returned in the provided range array argument. More...
 
virtual double GetMaxNorm ()
 Return the maximum norm for the tuples. More...
 
int CopyInformation (vtkInformation *infoFrom, int deep=1) override
 Copy information instance. More...
 
double GetTuple1 (vtkIdType tupleIdx)
 These methods are included as convenience for the wrappers. More...
 
doubleGetTuple2 (vtkIdType tupleIdx)
 These methods are included as convenience for the wrappers. More...
 
doubleGetTuple3 (vtkIdType tupleIdx)
 These methods are included as convenience for the wrappers. More...
 
doubleGetTuple4 (vtkIdType tupleIdx)
 These methods are included as convenience for the wrappers. More...
 
doubleGetTuple6 (vtkIdType tupleIdx)
 These methods are included as convenience for the wrappers. More...
 
doubleGetTuple9 (vtkIdType tupleIdx)
 These methods are included as convenience for the wrappers. More...
 
void SetTuple1 (vtkIdType tupleIdx, double value)
 These methods are included as convenience for the wrappers. More...
 
void SetTuple2 (vtkIdType tupleIdx, double val0, double val1)
 These methods are included as convenience for the wrappers. More...
 
void SetTuple3 (vtkIdType tupleIdx, double val0, double val1, double val2)
 These methods are included as convenience for the wrappers. More...
 
void SetTuple4 (vtkIdType tupleIdx, double val0, double val1, double val2, double val3)
 These methods are included as convenience for the wrappers. More...
 
void SetTuple6 (vtkIdType tupleIdx, double val0, double val1, double val2, double val3, double val4, double val5)
 These methods are included as convenience for the wrappers. More...
 
void SetTuple9 (vtkIdType tupleIdx, double val0, double val1, double val2, double val3, double val4, double val5, double val6, double val7, double val8)
 These methods are included as convenience for the wrappers. More...
 
void InsertTuple1 (vtkIdType tupleIdx, double value)
 These methods are included as convenience for the wrappers. More...
 
void InsertTuple2 (vtkIdType tupleIdx, double val0, double val1)
 These methods are included as convenience for the wrappers. More...
 
void InsertTuple3 (vtkIdType tupleIdx, double val0, double val1, double val2)
 These methods are included as convenience for the wrappers. More...
 
void InsertTuple4 (vtkIdType tupleIdx, double val0, double val1, double val2, double val3)
 These methods are included as convenience for the wrappers. More...
 
void InsertTuple6 (vtkIdType tupleIdx, double val0, double val1, double val2, double val3, double val4, double val5)
 These methods are included as convenience for the wrappers. More...
 
void InsertTuple9 (vtkIdType tupleIdx, double val0, double val1, double val2, double val3, double val4, double val5, double val6, double val7, double val8)
 These methods are included as convenience for the wrappers. More...
 
void InsertNextTuple1 (double value)
 These methods are included as convenience for the wrappers. More...
 
void InsertNextTuple2 (double val0, double val1)
 These methods are included as convenience for the wrappers. More...
 
void InsertNextTuple3 (double val0, double val1, double val2)
 These methods are included as convenience for the wrappers. More...
 
void InsertNextTuple4 (double val0, double val1, double val2, double val3)
 These methods are included as convenience for the wrappers. More...
 
void InsertNextTuple6 (double val0, double val1, double val2, double val3, double val4, double val5)
 These methods are included as convenience for the wrappers. More...
 
void InsertNextTuple9 (double val0, double val1, double val2, double val3, double val4, double val5, double val6, double val7, double val8)
 These methods are included as convenience for the wrappers. More...
 
virtual void RemoveFirstTuple ()
 These methods remove tuples from the data array. More...
 
virtual void RemoveLastTuple ()
 These methods remove tuples from the data array. More...
 
void SetLookupTable (vtkLookupTable *lut)
 Set/get the lookup table associated with this scalar data, if any. More...
 
virtual vtkLookupTableGetLookupTable ()
 Set/get the lookup table associated with this scalar data, if any. More...
 
doubleGetRange (int comp)
 Return the range of the data array values for the given component. More...
 
void GetDataTypeRange (double range[2])
 These methods return the Min and Max possible range of the native data type. More...
 
double GetDataTypeMin ()
 These methods return the Min and Max possible range of the native data type. More...
 
double GetDataTypeMax ()
 These methods return the Min and Max possible range of the native data type. More...
 
- Public Member Functions inherited from vtkAbstractArray
vtkAbstractArrayNewInstance () const
 
void SetComponentName (vtkIdType component, const char *name)
 Set the name for a component. More...
 
const char * GetComponentName (vtkIdType component)
 Get the component name for a given component. More...
 
bool HasAComponentName ()
 Returns if any component has had a name assigned. More...
 
int CopyComponentNames (vtkAbstractArray *da)
 Copies the component names from the inputed array to the current array make sure that the current array has the same number of components as the input array. More...
 
vtkIdType GetNumberOfTuples ()
 Get the number of complete tuples (a component group) in the array. More...
 
vtkIdType GetNumberOfValues () const
 Get the total number of values in the array. More...
 
vtkIdType GetSize ()
 Return the size of the data. More...
 
vtkIdType GetMaxId ()
 What is the maximum id currently in the array. More...
 
virtual const char * GetDataTypeAsString (void)
 Get the name of a data type as a string. More...
 
virtual vtkIdType GetDataSize ()
 Returns the size of the data in DataTypeSize units. More...
 
virtual void GetProminentComponentValues (int comp, vtkVariantArray *values, double uncertainty=1.e-6, double minimumProminence=1.e-3)
 Populate the given vtkVariantArray with a set of distinct values taken on by the requested component (or, when passed -1, by the tuples as a whole). More...
 
vtkInformationGetInformation ()
 Get an information object that can be used to annotate the array. More...
 
bool HasInformation ()
 Inquire if this array has an instance of vtkInformation already associated with it. More...
 
int GetNumberOfComponents ()
 Set/Get the dimension (n) of the components. More...
 
void Reset ()
 Reset to an empty state, without freeing any memory. More...
 
virtual void SetVoidArray (void *vtkNotUsed(array), vtkIdType vtkNotUsed(size), int vtkNotUsed(save))=0
 This method lets the user specify data to be held by the array. More...
 
virtual void SetVoidArray (void *array, vtkIdType size, int save, int vtkNotUsed(deleteMethod))
 This method lets the user specify data to be held by the array. More...
 
virtual void SetName (const char *)
 Set/get array's name. More...
 
virtual char * GetName ()
 Set/get array's name. More...
 
virtual unsigned int GetMaxDiscreteValues ()
 Get/Set the maximum number of prominent values this array may contain before it is considered continuous. More...
 
virtual void SetMaxDiscreteValues (unsigned int)
 Get/Set the maximum number of prominent values this array may contain before it is considered continuous. More...
 
- Public Member Functions inherited from vtkObject
 vtkBaseTypeMacro (vtkObject, vtkObjectBase)
 
virtual void DebugOn ()
 Turn debugging output on. More...
 
virtual void DebugOff ()
 Turn debugging output off. More...
 
bool GetDebug ()
 Get the value of the debug flag. More...
 
void SetDebug (bool debugFlag)
 Set the value of the debug flag. More...
 
virtual vtkMTimeType GetMTime ()
 Return this object's modified time. More...
 
void PrintSelf (ostream &os, vtkIndent indent) override
 Methods invoked by print to print information about the object including superclasses. More...
 
void RemoveObserver (unsigned long tag)
 
void RemoveObservers (unsigned long event)
 
void RemoveObservers (const char *event)
 
void RemoveAllObservers ()
 
int HasObserver (unsigned long event)
 
int HasObserver (const char *event)
 
int InvokeEvent (unsigned long event)
 
int InvokeEvent (const char *event)
 
unsigned long AddObserver (unsigned long event, vtkCommand *, float priority=0.0f)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
unsigned long AddObserver (const char *event, vtkCommand *, float priority=0.0f)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
vtkCommandGetCommand (unsigned long tag)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
void RemoveObserver (vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
void RemoveObservers (unsigned long event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
void RemoveObservers (const char *event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
int HasObserver (unsigned long event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
int HasObserver (const char *event, vtkCommand *)
 Allow people to add/remove/invoke observers (callbacks) to any VTK object. More...
 
template<class U , class T >
unsigned long AddObserver (unsigned long event, U observer, void(T::*callback)(), float priority=0.0f)
 Overloads to AddObserver that allow developers to add class member functions as callbacks for events. More...
 
template<class U , class T >
unsigned long AddObserver (unsigned long event, U observer, void(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f)
 Overloads to AddObserver that allow developers to add class member functions as callbacks for events. More...
 
template<class U , class T >
unsigned long AddObserver (unsigned long event, U observer, bool(T::*callback)(vtkObject *, unsigned long, void *), float priority=0.0f)
 Allow user to set the AbortFlagOn() with the return value of the callback method. More...
 
int InvokeEvent (unsigned long event, void *callData)
 This method invokes an event and return whether the event was aborted or not. More...
 
int InvokeEvent (const char *event, void *callData)
 This method invokes an event and return whether the event was aborted or not. More...
 
- Public Member Functions inherited from vtkObjectBase
const char * GetClassName () const
 Return the class name as a string. More...
 
virtual void Delete ()
 Delete a VTK object. More...
 
virtual void FastDelete ()
 Delete a reference to this object. More...
 
void InitializeObjectBase ()
 
void Print (ostream &os)
 Print an object to an ostream. More...
 
virtual void Register (vtkObjectBase *o)
 Increase the reference count (mark as used by another object). More...
 
virtual void UnRegister (vtkObjectBase *o)
 Decrease the reference count (release by another object). More...
 
int GetReferenceCount ()
 Return the current reference count of this object. More...
 
void SetReferenceCount (int)
 Sets the reference count. More...
 
void PrintRevisions (ostream &)
 Legacy. More...
 
virtual void PrintHeader (ostream &os, vtkIndent indent)
 Methods invoked by print to print information about the object including superclasses. More...
 
virtual void PrintTrailer (ostream &os, vtkIndent indent)
 Methods invoked by print to print information about the object including superclasses. More...
 

Static Public Member Functions

static vtkTemplateTypeMacro(vtkMappedDataArray< Scalar >, vtkTypedDataArray< Scalar >) typedef typename Superclass vtkMappedDataArray< Scalar > * FastDownCast (vtkAbstractArray *source)
 Perform a fast, safe cast from a vtkAbstractArray to a vtkMappedDataArray. More...
 
- Static Public Member Functions inherited from vtkTypedDataArray< Scalar >
static vtkTypedDataArray< Scalar > * FastDownCast (vtkAbstractArray *source)
 Perform a fast, safe cast from a vtkAbstractArray to a vtkTypedDataArray. More...
 
- Static Public Member Functions inherited from vtkDataArray
static int IsTypeOf (const char *type)
 
static vtkDataArraySafeDownCast (vtkObjectBase *o)
 
static vtkDataArrayFastDownCast (vtkAbstractArray *source)
 Perform a fast, safe cast from a vtkAbstractArray to a vtkDataArray. More...
 
static VTK_NEWINSTANCE vtkDataArrayCreateDataArray (int dataType)
 Creates an array for dataType where dataType is one of VTK_BIT, VTK_CHAR, VTK_SIGNED_CHAR, VTK_UNSIGNED_CHAR, VTK_SHORT, VTK_UNSIGNED_SHORT, VTK_INT, VTK_UNSIGNED_INT, VTK_LONG, VTK_UNSIGNED_LONG, VTK_DOUBLE, VTK_DOUBLE, VTK_ID_TYPE. More...
 
static vtkInformationDoubleVectorKeyCOMPONENT_RANGE ()
 This key is used to hold tight bounds on the range of one component over all tuples of the array. More...
 
static vtkInformationDoubleVectorKeyL2_NORM_RANGE ()
 This key is used to hold tight bounds on the $L_2$ norm of tuples in the array. More...
 
static vtkInformationStringKeyUNITS_LABEL ()
 A human-readable string indicating the units for the array data. More...
 
static void GetDataTypeRange (int type, double range[2])
 These methods return the Min and Max possible range of the native data type. More...
 
static double GetDataTypeMin (int type)
 These methods return the Min and Max possible range of the native data type. More...
 
static double GetDataTypeMax (int type)
 These methods return the Min and Max possible range of the native data type. More...
 
- Static Public Member Functions inherited from vtkAbstractArray
static int IsTypeOf (const char *type)
 
static vtkAbstractArraySafeDownCast (vtkObjectBase *o)
 
static VTK_NEWINSTANCE vtkAbstractArrayCreateArray (int dataType)
 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_DOUBLE, VTK_DOUBLE, VTK_ID_TYPE, VTK_STRING. More...
 
static vtkInformationIntegerKeyGUI_HIDE ()
 This key is a hint to end user interface that this array is internal and should not be shown to the end user. More...
 
static vtkInformationInformationVectorKeyPER_COMPONENT ()
 This key is used to hold a vector of COMPONENT_VALUES (and, for vtkDataArray subclasses, COMPONENT_RANGE) keys – one for each component of the array. More...
 
static vtkInformationVariantVectorKeyDISCRETE_VALUES ()
 A key used to hold discrete values taken on either by the tuples of the array (when present in this->GetInformation()) or individual components (when present in one entry of the PER_COMPONENT() information vector). More...
 
static vtkInformationDoubleVectorKeyDISCRETE_VALUE_SAMPLE_PARAMETERS ()
 A key used to hold conditions under which cached discrete values were generated; the value is a 2-vector of doubles. More...
 
static int GetDataTypeSize (int type)
 Return the size of the underlying data type. More...
 
- Static Public Member Functions inherited from vtkObject
static vtkObjectNew ()
 Create an object with Debug turned off, modified time initialized to zero, and reference counting on. More...
 
static void BreakOnError ()
 This method is called when vtkErrorMacro executes. More...
 
static void SetGlobalWarningDisplay (int val)
 This is a global flag that controls whether any debug, warning or error messages are displayed. More...
 
static void GlobalWarningDisplayOn ()
 This is a global flag that controls whether any debug, warning or error messages are displayed. More...
 
static void GlobalWarningDisplayOff ()
 This is a global flag that controls whether any debug, warning or error messages are displayed. More...
 
static int GetGlobalWarningDisplay ()
 This is a global flag that controls whether any debug, warning or error messages are displayed. More...
 
- Static Public Member Functions inherited from vtkObjectBase
static vtkTypeBool IsTypeOf (const char *name)
 Return 1 if this class type is the same type of (or a subclass of) the named class. More...
 
static vtkObjectBaseNew ()
 Create an object with Debug turned off, modified time initialized to zero, and reference counting on. More...
 

Protected Member Functions

 vtkMappedDataArray ()
 
 ~vtkMappedDataArray ()
 
virtual int GetArrayType ()
 Method for type-checking in FastDownCast implementations. More...
 
- Protected Member Functions inherited from vtkTypedDataArray< Scalar >
 vtkTypedDataArray ()
 
 ~vtkTypedDataArray ()
 
virtual bool AllocateTuples (vtkIdType numTuples)
 Needed for vtkGenericDataArray API, but just aborts. More...
 
virtual bool ReallocateTuples (vtkIdType numTuples)
 Needed for vtkGenericDataArray API, but just aborts. More...
 
- Protected Member Functions inherited from vtkGenericDataArray< vtkTypedDataArray< Scalar >, Scalar >
 vtkGenericDataArray ()
 
 ~vtkGenericDataArray () override
 
bool AllocateTuples (vtkIdType numTuples)
 Allocate space for numTuples. More...
 
bool ReallocateTuples (vtkIdType numTuples)
 Allocate space for numTuples. More...
 
bool EnsureAccessToTuple (vtkIdType tupleIdx)
 
- Protected Member Functions inherited from vtkDataArray
virtual vtkObjectBaseNewInstanceInternal () const
 
virtual void ComputeRange (double range[2], int comp)
 Compute the range for a specific component. More...
 
virtual bool ComputeScalarRange (double *ranges)
 Computes the range for each component of an array, the length of ranges must be two times the number of components. More...
 
virtual bool ComputeVectorRange (double range[2])
 
 vtkDataArray ()
 
 ~vtkDataArray () override
 
- Protected Member Functions inherited from vtkAbstractArray
 vtkAbstractArray ()
 
 ~vtkAbstractArray () override
 
virtual void SetInformation (vtkInformation *)
 Set an information object that can be used to annotate the array. More...
 
virtual void UpdateDiscreteValueSet (double uncertainty, double minProminence)
 Obtain the set of unique values taken on by each component of the array, as well as by the tuples of the array. More...
 
- Protected Member Functions inherited from vtkObject
 vtkObject ()
 
 ~vtkObject () override
 
void RegisterInternal (vtkObjectBase *, vtkTypeBool check) override
 
void UnRegisterInternal (vtkObjectBase *, vtkTypeBool check) override
 
void InternalGrabFocus (vtkCommand *mouseEvents, vtkCommand *keypressEvents=NULL)
 These methods allow a command to exclusively grab all events. More...
 
void InternalReleaseFocus ()
 These methods allow a command to exclusively grab all events. More...
 
- Protected Member Functions inherited from vtkObjectBase
 vtkObjectBase ()
 
virtual ~vtkObjectBase ()
 
virtual void CollectRevisions (ostream &)
 
virtual void ReportReferences (vtkGarbageCollector *)
 
 vtkObjectBase (const vtkObjectBase &)
 
void operator= (const vtkObjectBase &)
 

Additional Inherited Members

- Public Types inherited from vtkTypedDataArray< Scalar >
enum  { VTK_DATA_TYPE = vtkTypeTraits<ValueType>::VTK_TYPE_ID }
 Compile time access to the VTK type identifier. More...
 
- Public Types inherited from vtkGenericDataArray< vtkTypedDataArray< Scalar >, Scalar >
typedef Scalar ValueType
 
- Public Types inherited from vtkDataArray
typedef vtkAbstractArray Superclass
 
- Public Types inherited from vtkAbstractArray
enum  DeleteMethod { VTK_DATA_ARRAY_FREE, VTK_DATA_ARRAY_DELETE }
 
enum  { MAX_DISCRETE_VALUES = 32 }
 
enum  {
  AbstractArray = 0, DataArray, AoSDataArrayTemplate, SoADataArrayTemplate,
  TypedDataArray, MappedDataArray, DataArrayTemplate = AoSDataArrayTemplate
}
 
typedef vtkObject Superclass
 
- Public Attributes inherited from vtkTypedDataArray< Scalar >
vtkTemplateTypeMacro(vtkTypedDataArray< Scalar >, GenericDataArrayType) typedef typename Superclass typedef vtkTypedDataArrayIterator< ValueTypeIterator
 Typedef to a suitable iterator class. More...
 
- Protected Attributes inherited from vtkGenericDataArray< vtkTypedDataArray< Scalar >, Scalar >
vtkGenericDataArrayLookupHelper< SelfTypeLookup
 
- Protected Attributes inherited from vtkDataArray
vtkLookupTableLookupTable
 
double Range [2]
 
- Protected Attributes inherited from vtkAbstractArray
vtkIdType Size
 
vtkIdType MaxId
 
int NumberOfComponents
 
unsigned int MaxDiscreteValues
 
char * Name
 
bool RebuildArray
 
vtkInformationInformation
 
vtkInternalComponentNames * ComponentNames
 
- Protected Attributes inherited from vtkObject
bool Debug
 
vtkTimeStamp MTime
 
vtkSubjectHelper * SubjectHelper
 
- Protected Attributes inherited from vtkObjectBase
vtkAtomicInt32 ReferenceCount
 
vtkWeakPointerBase ** WeakPointers
 

Detailed Description

template<class Scalar>
class vtkMappedDataArray< Scalar >

Map non-contiguous data structures into the vtkDataArray API.

vtkMappedDataArray is a superclass for vtkDataArrays that do not use the standard memory layout, and allows VTK to interface with simulation codes for in-situ analysis without repacking simulation data.

vtkMappedDataArrayNewInstanceMacro is used by subclasses to implement NewInstanceInternal such that a non-mapped vtkDataArray is returned by NewInstance(). This prevents the mapped array type from propogating through the pipeline.

Attention
Subclasses that hold vtkIdType elements must also reimplement int GetDataType() (see Caveat in vtkTypedDataArray).

Definition at line 41 of file vtkMappedDataArray.h.

Constructor & Destructor Documentation

template<class Scalar>
vtkMappedDataArray< Scalar >::vtkMappedDataArray ( )
protected
template<class Scalar>
vtkMappedDataArray< Scalar >::~vtkMappedDataArray ( )
protected

Member Function Documentation

template<class Scalar>
static vtkTemplateTypeMacro (vtkMappedDataArray<Scalar>, vtkTypedDataArray<Scalar>) typedef typename Superclass vtkMappedDataArray<Scalar>* vtkMappedDataArray< Scalar >::FastDownCast ( vtkAbstractArray source)
static

Perform a fast, safe cast from a vtkAbstractArray to a vtkMappedDataArray.

This method checks if:

  • source->GetArrayType() is appropriate, and
  • source->GetDataType() matches the Scalar template argument if these conditions are met, the method performs a static_cast to return source as a vtkMappedDataArray pointer. Otherwise, NULL is returned.
template<class Scalar>
void vtkMappedDataArray< Scalar >::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 vtkDataArray.

Reimplemented in vtkCPExodusIIResultsArrayTemplate< Scalar >, and vtkCPExodusIINodalCoordinatesTemplate< Scalar >.

template<class Scalar>
void vtkMappedDataArray< Scalar >::DeepCopy ( vtkAbstractArray aa)
pure virtual

Deep copy of data.

Copies data from different data arrays even if they are different types (using doubleing-point exchange).

Reimplemented from vtkDataArray.

Implemented in vtkCPExodusIIResultsArrayTemplate< Scalar >, and vtkCPExodusIINodalCoordinatesTemplate< Scalar >.

template<class Scalar>
vtkVariant vtkMappedDataArray< Scalar >::GetVariantValue ( vtkIdType  valueIdx)
pure virtual

Retrieve value from the array as a variant.

Reimplemented from vtkAbstractArray.

Implemented in vtkCPExodusIIResultsArrayTemplate< Scalar >, and vtkCPExodusIINodalCoordinatesTemplate< Scalar >.

template<class Scalar>
void vtkMappedDataArray< Scalar >::SetVariantValue ( vtkIdType  valueIdx,
vtkVariant  value 
)
pure virtual

Set a value in the array from a variant.

This method does NOT do bounds checking.

Implements vtkAbstractArray.

Implemented in vtkCPExodusIIResultsArrayTemplate< Scalar >, and vtkCPExodusIINodalCoordinatesTemplate< Scalar >.

template<class Scalar>
void vtkMappedDataArray< Scalar >::GetTuples ( vtkIdList tupleIds,
vtkAbstractArray output 
)
pure virtual

Given a list of tuple ids, return an array of tuples.

You must insure that the output array has been previously allocated with enough space to hold the data.

Reimplemented from vtkDataArray.

Implemented in vtkCPExodusIIResultsArrayTemplate< Scalar >, and vtkCPExodusIINodalCoordinatesTemplate< Scalar >.

template<class Scalar>
void vtkMappedDataArray< Scalar >::GetTuples ( vtkIdType  p1,
vtkIdType  p2,
vtkAbstractArray output 
)
pure virtual

Get the tuples for the range of tuple 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.

Reimplemented from vtkDataArray.

Implemented in vtkCPExodusIIResultsArrayTemplate< Scalar >, and vtkCPExodusIINodalCoordinatesTemplate< Scalar >.

template<class Scalar>
void vtkMappedDataArray< Scalar >::InterpolateTuple ( vtkIdType  dstTupleIdx,
vtkIdList ptIndices,
vtkAbstractArray source,
double weights 
)
pure virtual

Set the tuple at dstTupleIdx in this array to the interpolated tuple value, given the ptIndices in the source array and associated interpolation weights.

This method assumes that the two arrays are of the same type and strcuture.

Reimplemented from vtkDataArray.

Implemented in vtkCPExodusIIResultsArrayTemplate< Scalar >, and vtkCPExodusIINodalCoordinatesTemplate< Scalar >.

template<class Scalar>
void vtkMappedDataArray< Scalar >::InterpolateTuple ( vtkIdType  dstTupleIdx,
vtkIdType  srcTupleIdx1,
vtkAbstractArray source1,
vtkIdType  srcTupleIdx2,
vtkAbstractArray source2,
double  t 
)
pure virtual

Insert the tuple at dstTupleIdx in this array to the tuple interpolated from the two tuple indices, srcTupleIdx1 and srcTupleIdx2, and an interpolation factor, t.

The interpolation factor ranges from (0,1), with t=0 located at the tuple described by srcTupleIdx1. This method assumes that the three arrays are of the same type, srcTupleIdx1 is an index to array source1, and srcTupleIdx2 is an index to array source2.

Reimplemented from vtkDataArray.

Implemented in vtkCPExodusIIResultsArrayTemplate< Scalar >, and vtkCPExodusIINodalCoordinatesTemplate< Scalar >.

template<class Scalar>
void vtkMappedDataArray< Scalar >::DeepCopy ( vtkDataArray da)
pure virtual

Deep copy of data.

Copies data from different data arrays even if they are different types (using doubleing-point exchange).

Reimplemented from vtkDataArray.

Implemented in vtkCPExodusIIResultsArrayTemplate< Scalar >, and vtkCPExodusIINodalCoordinatesTemplate< Scalar >.

template<class Scalar>
void* vtkMappedDataArray< Scalar >::GetVoidPointer ( vtkIdType  id)
virtual

Print an error and create an internal, long-lived temporary array.

This method should not be used on vtkMappedDataArray subclasses. See vtkArrayDispatch for a better way.

Implements vtkAbstractArray.

template<class Scalar>
void vtkMappedDataArray< Scalar >::ExportToVoidPointer ( void *  ptr)
virtual

Copy the internal data to the void pointer.

The pointer is cast to this array's Scalar type and vtkTypedDataArrayIterator is used to populate the input array.

Reimplemented from vtkAbstractArray.

template<class Scalar>
void vtkMappedDataArray< Scalar >::DataChanged ( )
virtual

Read the data from the internal temporary array (created by GetVoidPointer) back into the mapped array.

If GetVoidPointer has not been called (and the internal array therefore does not exist), print an error and return. The default implementation uses vtkTypedDataArrayIterator to extract the mapped data.

Implements vtkAbstractArray.

template<class Scalar>
void vtkMappedDataArray< Scalar >::SetVoidArray ( void *  ,
vtkIdType  ,
int   
)

These methods don't make sense for mapped data array.

Prints an error and returns.

template<class Scalar>
void vtkMappedDataArray< Scalar >::SetVoidArray ( void *  ,
vtkIdType  ,
int  ,
int   
)

These methods don't make sense for mapped data array.

Prints an error and returns.

template<class Scalar>
void* vtkMappedDataArray< Scalar >::WriteVoidPointer ( vtkIdType  ,
vtkIdType   
)
inlinevirtual

Not implemented.

Print error and return NULL.

Implements vtkDataArray.

Definition at line 110 of file vtkMappedDataArray.h.

template<class Scalar>
void vtkMappedDataArray< Scalar >::Modified ( )
virtual

Invalidate the internal temporary array and call superclass method.

Reimplemented from vtkObject.

template<class Scalar>
bool vtkMappedDataArray< Scalar >::HasStandardMemoryLayout ( )
inlinevirtual

Returns true if this array uses the standard memory layout defined in the VTK user guide, e.g.

a contiguous array: {t1c1, t1c2, t1c3, ... t1cM, t2c1, ... tNcM} where t1c2 is the second component of the first tuple.

Reimplemented from vtkAbstractArray.

Definition at line 123 of file vtkMappedDataArray.h.

template<class Scalar>
virtual int vtkMappedDataArray< Scalar >::GetArrayType ( )
inlineprotectedvirtual

Method for type-checking in FastDownCast implementations.

Reimplemented from vtkDataArray.

Definition at line 129 of file vtkMappedDataArray.h.


The documentation for this class was generated from the following file: