VTK
Public Types | Public Member Functions
vtkArrayCoordinates Class Reference

Stores coordinate into an N-way array. More...

#include <vtkArrayCoordinates.h>

List of all members.

Public Types

typedef vtkIdType CoordinateT
typedef vtkIdType DimensionT

Public Member Functions

 vtkArrayCoordinates ()
 vtkArrayCoordinates (CoordinateT i)
 vtkArrayCoordinates (CoordinateT i, CoordinateT j)
 vtkArrayCoordinates (CoordinateT i, CoordinateT j, CoordinateT k)
DimensionT GetDimensions () const
void SetDimensions (DimensionT dimensions)
CoordinateToperator[] (DimensionT i)
const CoordinateToperator[] (DimensionT i) const
CoordinateT GetCoordinate (DimensionT i) const
void SetCoordinate (DimensionT i, const CoordinateT &)
bool operator== (const vtkArrayCoordinates &rhs) const
bool operator!= (const vtkArrayCoordinates &rhs) const
VTKCOMMONCORE_EXPORT friend
ostream & 
operator<< (ostream &stream, const vtkArrayCoordinates &rhs)

Detailed Description

Stores coordinate into an N-way array.

vtkArrayCoordinates stores a collection of coordinates that can be used to access values in a vtkArray containing an arbitrary number of dimensions.

Convenience constructors are provided for working with one, two, and three dimensions. For higher dimensions, use the default constructor, SetDimensions() and operator[] to assign a coordinate value along each dimension.

See also:
vtkArray, vtkArrayExtents
Thanks:
Developed by Timothy M. Shead (tshea.nosp@m.d@sa.nosp@m.ndia..nosp@m.gov) at Sandia National Laboratories.
Examples:
vtkArrayCoordinates (Examples)
Tests:
vtkArrayCoordinates (Tests)

Definition at line 56 of file vtkArrayCoordinates.h.


Member Typedef Documentation

Definition at line 59 of file vtkArrayCoordinates.h.

Definition at line 60 of file vtkArrayCoordinates.h.


Constructor & Destructor Documentation

Create an empty set of coordinates. Use SetDimensions() and operator[] to populate the coordinates.

Create coordinates for a one-dimensional array.

Create coordinates for a two-dimensional array.

Create coordinates for a three-dimensional array.


Member Function Documentation

Return the number of dimensions contained in the coordinates.

Set the number of dimensions. Note that this method resets the coordinate along each dimension to zero, so you must set every coordinate explicitly using operator[] after calling SetDimensions().

CoordinateT& vtkArrayCoordinates::operator[] ( DimensionT  i)

Returns the coordinate of the i-th dimension.

const CoordinateT& vtkArrayCoordinates::operator[] ( DimensionT  i) const

Returns the coordinate of the i-th dimension.

Returns the coordinate of the i-th dimension.

Sets the coordinate of the i-th dimension.

bool vtkArrayCoordinates::operator== ( const vtkArrayCoordinates rhs) const

Equality comparison

bool vtkArrayCoordinates::operator!= ( const vtkArrayCoordinates rhs) const

Inequality comparison


Friends And Related Function Documentation

VTKCOMMONCORE_EXPORT friend ostream& operator<< ( ostream &  stream,
const vtkArrayCoordinates rhs 
) [friend]

Inequality comparison


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