ITK
4.1.0
Insight Segmentation and Registration Toolkit
|
#include <itkCovariantVector.h>
Public Types | |
typedef FixedArray< T, NVectorDimension > | BaseArray |
typedef T | ComponentType |
typedef Self | CovariantVectorType |
typedef NumericTraits < ValueType >::RealType | RealValueType |
typedef CovariantVector | Self |
typedef FixedArray< T, NVectorDimension > | Superclass |
typedef T | ValueType |
Public Member Functions | |
CovariantVector () | |
CovariantVector (const ValueType &r) | |
vnl_vector_ref< T > | Get_vnl_vector (void) |
vnl_vector< T > | Get_vnl_vector (void) const |
RealValueType | GetNorm (void) const |
RealValueType | GetSquaredNorm (void) const |
vnl_vector_ref< T > | GetVnlVector (void) |
vnl_vector< T > | GetVnlVector (void) const |
void | Normalize (void) |
ValueType | operator* (const Self &vec) const |
ValueType | operator* (const Vector< T, NVectorDimension > &vec) const |
Self | operator* (const ValueType &val) const |
Self | operator+ (const Self &vec) const |
const Self & | operator+= (const Self &vec) |
Self | operator- () const |
Self | operator- (const Self &vec) const |
const Self & | operator-= (const Self &vec) |
template<class Tt > | |
Self | operator/ (const Tt &val) const |
CovariantVector & | operator= (const Self &r) |
CovariantVector & | operator= (const ValueType r[NVectorDimension]) |
void | Set_vnl_vector (const vnl_vector< T > &) |
void | SetVnlVector (const vnl_vector< T > &) |
template<class TVectorValueType > | |
CovariantVector (const CovariantVector< TVectorValueType, NVectorDimension > &r) | |
CovariantVector (const ValueType r[Dimension]) | |
template<class Tt > | |
Self & | operator= (const Tt &v) |
template<class Tt > | |
const Self & | operator*= (const Tt &value) |
template<class Tt > | |
const Self & | operator/= (const Tt &value) |
template<typename TCoordRepB > | |
void | CastFrom (const CovariantVector< TCoordRepB, NVectorDimension > &pa) |
Static Public Member Functions | |
static unsigned int | GetCovariantVectorDimension () |
static unsigned int | GetNumberOfComponents () |
Static Public Attributes | |
static const unsigned int | Dimension = NVectorDimension |
A templated class holding a n-Dimensional covariant vector.
CovariantVector is a templated class that holds a single vector (i.e., an array of values). CovariantVector can be used as the data type held at each pixel in an Image or at each vertex of an Mesh. The template parameter T can be any data type that behaves like a primitive (or atomic) data type (int, short, float, complex). The NVectorDimension defines the number of components in the vector array.
CovariantVector is not a dynamically extendible array like std::vector. It is intended to be used like a mathematical vector.
If you wish a simpler pixel types, you can use Scalar, which represents a single data value at a pixel. There is also the more complex type ScalarCovariantVector, which supports (for a given pixel) a single scalar value plus an array of vector values. (The scalar and vectors can be of different data type.)
CovariantVector is the type that should be used for representing normals to surfaces and gradients of functions. AffineTransform transform covariant vectors different than vectors.
Definition at line 67 of file itkCovariantVector.h.
typedef FixedArray< T, NVectorDimension > itk::CovariantVector< T, NVectorDimension >::BaseArray |
The Array type from which this CovariantVector is derived.
Definition at line 89 of file itkCovariantVector.h.
typedef T itk::CovariantVector< T, NVectorDimension >::ComponentType |
Component value type
Definition at line 80 of file itkCovariantVector.h.
typedef Self itk::CovariantVector< T, NVectorDimension >::CovariantVectorType |
I am a covariant vector.
Definition at line 86 of file itkCovariantVector.h.
typedef NumericTraits< ValueType >::RealType itk::CovariantVector< T, NVectorDimension >::RealValueType |
Definition at line 77 of file itkCovariantVector.h.
typedef CovariantVector itk::CovariantVector< T, NVectorDimension >::Self |
Standard class typedefs.
Definition at line 71 of file itkCovariantVector.h.
typedef FixedArray< T, NVectorDimension > itk::CovariantVector< T, NVectorDimension >::Superclass |
Definition at line 72 of file itkCovariantVector.h.
typedef T itk::CovariantVector< T, NVectorDimension >::ValueType |
ValueType can be used to declare a variable that is the same type as a data element held in an CovariantVector.
Reimplemented from itk::FixedArray< T, NVectorDimension >.
Definition at line 76 of file itkCovariantVector.h.
itk::CovariantVector< T, NVectorDimension >::CovariantVector | ( | ) | [inline] |
Default constructor and copy constructors.
Definition at line 117 of file itkCovariantVector.h.
itk::CovariantVector< T, NVectorDimension >::CovariantVector | ( | const ValueType & | r | ) |
itk::CovariantVector< T, NVectorDimension >::CovariantVector | ( | const CovariantVector< TVectorValueType, NVectorDimension > & | r | ) | [inline] |
Pass-through constructor for the Array base class. Implicit casting is performed to initialize constructor from any another one of datatype.
Definition at line 123 of file itkCovariantVector.h.
itk::CovariantVector< T, NVectorDimension >::CovariantVector | ( | const ValueType | r[Dimension] | ) | [inline] |
Pass-through constructor for the Array base class. Implicit casting is performed to initialize constructor from any another one of datatype.
Definition at line 125 of file itkCovariantVector.h.
void itk::CovariantVector< T, NVectorDimension >::CastFrom | ( | const CovariantVector< TCoordRepB, NVectorDimension > & | pa | ) | [inline] |
Copy from another CovariantVector with a different representation type. Casting is done with C-Like rules
Definition at line 234 of file itkCovariantVector.h.
vnl_vector_ref< T > itk::CovariantVector< T, NVectorDimension >::Get_vnl_vector | ( | void | ) |
Get a vnl_vector_ref referencing the same memory block.
vnl_vector< T > itk::CovariantVector< T, NVectorDimension >::Get_vnl_vector | ( | void | ) | const |
Get a vnl_vector with a copy of the internal memory block.
static unsigned int itk::CovariantVector< T, NVectorDimension >::GetCovariantVectorDimension | ( | ) | [inline, static] |
Get the dimension (size) of the vector.
Definition at line 92 of file itkCovariantVector.h.
RealValueType itk::CovariantVector< T, NVectorDimension >::GetNorm | ( | void | ) | const |
Returns the Euclidean Norm of the vector
static unsigned int itk::CovariantVector< T, NVectorDimension >::GetNumberOfComponents | ( | ) | [inline, static] |
Returns the number of components in this vector type
Definition at line 223 of file itkCovariantVector.h.
RealValueType itk::CovariantVector< T, NVectorDimension >::GetSquaredNorm | ( | void | ) | const |
Returns vector's Squared Euclidean Norm
vnl_vector_ref< T > itk::CovariantVector< T, NVectorDimension >::GetVnlVector | ( | void | ) |
Get a vnl_vector_ref referencing the same memory block.
vnl_vector< T > itk::CovariantVector< T, NVectorDimension >::GetVnlVector | ( | void | ) | const |
Get a vnl_vector with a copy of the internal memory block.
void itk::CovariantVector< T, NVectorDimension >::Normalize | ( | void | ) |
Divides the covariant vector componets by the norm
ValueType itk::CovariantVector< T, NVectorDimension >::operator* | ( | const Self & | vec | ) | const |
CovariantVector operator*. Performs the inner product of two covariant vectors.
ValueType itk::CovariantVector< T, NVectorDimension >::operator* | ( | const Vector< T, NVectorDimension > & | vec | ) | const |
operator*. Performs the scalar product with a vector (contravariant). This scalar product is invariant under affine transformations
Self itk::CovariantVector< T, NVectorDimension >::operator* | ( | const ValueType & | val | ) | const [inline] |
Scalar operator*. Scale the elements of a vector by a scalar. Return a new vector.
Definition at line 194 of file itkCovariantVector.h.
const Self& itk::CovariantVector< T, NVectorDimension >::operator*= | ( | const Tt & | value | ) | [inline] |
Scalar operator*=. Scales elements by a scalar.
Definition at line 144 of file itkCovariantVector.h.
Self itk::CovariantVector< T, NVectorDimension >::operator+ | ( | const Self & | vec | ) | const |
CovariantVector addition. Add two vectors. Return a new vector.
const Self& itk::CovariantVector< T, NVectorDimension >::operator+= | ( | const Self & | vec | ) |
CovariantVector operator+=. Adds a vectors to the current vector.
Self itk::CovariantVector< T, NVectorDimension >::operator- | ( | ) | const |
CovariantVector negation. Negate all the elements of a vector. Return a new vector
Self itk::CovariantVector< T, NVectorDimension >::operator- | ( | const Self & | vec | ) | const |
CovariantVector subtraction. Subtract two vectors. Return a new vector.
const Self& itk::CovariantVector< T, NVectorDimension >::operator-= | ( | const Self & | vec | ) |
CovariantVector operator-=. Subtracts a vector from a current vector.
Self itk::CovariantVector< T, NVectorDimension >::operator/ | ( | const Tt & | val | ) | const [inline] |
Scalar operator/. Scale (divide) the elements of a vector by a scalar. Return a new vector.
Definition at line 208 of file itkCovariantVector.h.
const Self& itk::CovariantVector< T, NVectorDimension >::operator/= | ( | const Tt & | value | ) | [inline] |
Scalar operator/=. Scales (divides) elements by a scalar.
Definition at line 156 of file itkCovariantVector.h.
Self& itk::CovariantVector< T, NVectorDimension >::operator= | ( | const Tt & | v | ) | [inline] |
Assignment operator with implicit casting from another data type
Definition at line 130 of file itkCovariantVector.h.
CovariantVector& itk::CovariantVector< T, NVectorDimension >::operator= | ( | const Self & | r | ) |
Pass-through assignment operator for the Array base class.
CovariantVector& itk::CovariantVector< T, NVectorDimension >::operator= | ( | const ValueType | r[NVectorDimension] | ) |
void itk::CovariantVector< T, NVectorDimension >::Set_vnl_vector | ( | const vnl_vector< T > & | ) |
Set a vnl_vector_ref referencing the same memory block.
void itk::CovariantVector< T, NVectorDimension >::SetVnlVector | ( | const vnl_vector< T > & | ) |
Set a vnl_vector_ref referencing the same memory block.
const unsigned int itk::CovariantVector< T, NVectorDimension >::Dimension = NVectorDimension [static] |
Dimension of the Space
Reimplemented from itk::FixedArray< T, NVectorDimension >.
Definition at line 83 of file itkCovariantVector.h.