VTK
9.5.20250731
|
Go to the source code of this file.
Classes | |
class | vtkVector< T, Size > |
templated base type for storage of vectors. More... | |
class | vtkVector2< T > |
class | vtkVector3< T > |
class | vtkVector4< T > |
class | vtkVector2i |
Some derived classes for the different vectors commonly used. More... | |
class | vtkVector2f |
class | vtkVector2d |
class | vtkVector3i |
class | vtkVector3f |
class | vtkVector3d |
class | vtkVector4i |
class | vtkVector4d |
Macros | |
#define | vtkVectorNormalized(vectorType, type, size) |
Some inline functions for the derived types. | |
#define | vtkVectorDerivedMacro(vectorType, type, size) |
#define | vtkVector3Cross(vectorType, type) |
#define | vtkVectorOperatorNegate(vectorType, type, size) |
Several macros to define the various operator overloads for the vectors. | |
#define | vtkVectorOperatorPlus(vectorType, type, size) |
#define | vtkVectorOperatorMinus(vectorType, type, size) |
#define | vtkVectorOperatorMultiply(vectorType, type, size) |
#define | vtkVectorOperatorMultiplyScalar(vectorType, type, size) |
#define | vtkVectorOperatorMultiplyScalarPre(vectorType, type, size) |
#define | vtkVectorOperatorDivide(vectorType, type, size) |
#define | vtkVectorOperatorMacro(vectorType, type, size) |
Functions | |
template<typename A , int Size> | |
vtkVector< A, Size > | operator- (const vtkVector< A, Size > &v) |
This following operators enhance the vtkVector classes, allowing various operator overloads one might expect. | |
template<typename A , int Size> | |
vtkVector< A, Size > | operator+ (const vtkVector< A, Size > &v1, const vtkVector< A, Size > &v2) |
Performs addition of vectors of the same basic type. | |
template<typename T , int Size> | |
vtkVector< T, Size > & | operator+= (vtkVector< T, Size > &a, const vtkVector< T, Size > &b) |
Add the vector b to the vector a of the same basic type. | |
template<typename A , int Size> | |
vtkVector< A, Size > | operator- (const vtkVector< A, Size > &v1, const vtkVector< A, Size > &v2) |
Performs subtraction of vectors of the same basic type. | |
template<typename T , int Size> | |
vtkVector< T, Size > & | operator-= (vtkVector< T, Size > &a, const vtkVector< T, Size > &b) |
Subtract the vector b to the vector a of the same basic type. | |
template<typename A , int Size> | |
vtkVector< A, Size > | operator* (const vtkVector< A, Size > &v1, const vtkVector< A, Size > &v2) |
Performs multiplication of vectors of the same basic type. | |
template<typename A , typename B , int Size> | |
vtkVector< A, Size > | operator* (const vtkVector< A, Size > &v1, const B &scalar) |
Performs multiplication of vectors by a scalar value. | |
template<typename A , int Size> | |
vtkVector< A, Size > | operator/ (const vtkVector< A, Size > &v1, const vtkVector< A, Size > &v2) |
Performs division of vectors of the same type. | |
vtkVectorOperatorMacro (vtkVector2i, int, 2) | |
Overload the operators for the common types. | |
vtkVectorOperatorMacro (vtkVector2f, float, 2) | |
vtkVectorOperatorMacro (vtkVector2d, double, 2) | |
vtkVectorOperatorMacro (vtkVector3i, int, 3) | |
vtkVectorOperatorMacro (vtkVector3f, float, 3) | |
vtkVectorOperatorMacro (vtkVector3d, double, 3) | |
#define vtkVectorNormalized | ( | vectorType, | |
type, | |||
size | |||
) |
Some inline functions for the derived types.
Definition at line 420 of file vtkVector.h.
#define vtkVectorDerivedMacro | ( | vectorType, | |
type, | |||
size | |||
) |
Definition at line 426 of file vtkVector.h.
#define vtkVector3Cross | ( | vectorType, | |
type | |||
) |
Definition at line 486 of file vtkVector.h.
#define vtkVectorOperatorNegate | ( | vectorType, | |
type, | |||
size | |||
) |
Several macros to define the various operator overloads for the vectors.
These macros are necessary to define operator overloads for common vector types (e.g vtkVector3d...), without them, there could be ambiguous overloads. XXX(c++20): might use constraints instead
Definition at line 679 of file vtkVector.h.
#define vtkVectorOperatorPlus | ( | vectorType, | |
type, | |||
size | |||
) |
Definition at line 684 of file vtkVector.h.
#define vtkVectorOperatorMinus | ( | vectorType, | |
type, | |||
size | |||
) |
Definition at line 691 of file vtkVector.h.
#define vtkVectorOperatorMultiply | ( | vectorType, | |
type, | |||
size | |||
) |
Definition at line 698 of file vtkVector.h.
#define vtkVectorOperatorMultiplyScalar | ( | vectorType, | |
type, | |||
size | |||
) |
Definition at line 705 of file vtkVector.h.
#define vtkVectorOperatorMultiplyScalarPre | ( | vectorType, | |
type, | |||
size | |||
) |
Definition at line 711 of file vtkVector.h.
#define vtkVectorOperatorDivide | ( | vectorType, | |
type, | |||
size | |||
) |
Definition at line 717 of file vtkVector.h.
#define vtkVectorOperatorMacro | ( | vectorType, | |
type, | |||
size | |||
) |
Definition at line 725 of file vtkVector.h.
This following operators enhance the vtkVector classes, allowing various operator overloads one might expect.
Unary minus / negation of vector.
Definition at line 564 of file vtkVector.h.
vtkVector< A, Size > operator+ | ( | const vtkVector< A, Size > & | v1, |
const vtkVector< A, Size > & | v2 | ||
) |
Performs addition of vectors of the same basic type.
Definition at line 578 of file vtkVector.h.
vtkVector< T, Size > & operator+= | ( | vtkVector< T, Size > & | a, |
const vtkVector< T, Size > & | b | ||
) |
Add the vector b to the vector a of the same basic type.
Definition at line 592 of file vtkVector.h.
vtkVector< A, Size > operator- | ( | const vtkVector< A, Size > & | v1, |
const vtkVector< A, Size > & | v2 | ||
) |
Performs subtraction of vectors of the same basic type.
Definition at line 606 of file vtkVector.h.
vtkVector< T, Size > & operator-= | ( | vtkVector< T, Size > & | a, |
const vtkVector< T, Size > & | b | ||
) |
Subtract the vector b to the vector a of the same basic type.
Definition at line 620 of file vtkVector.h.
vtkVector< A, Size > operator* | ( | const vtkVector< A, Size > & | v1, |
const vtkVector< A, Size > & | v2 | ||
) |
Performs multiplication of vectors of the same basic type.
Definition at line 634 of file vtkVector.h.
vtkVector< A, Size > operator* | ( | const vtkVector< A, Size > & | v1, |
const B & | scalar | ||
) |
Performs multiplication of vectors by a scalar value.
Definition at line 648 of file vtkVector.h.
vtkVector< A, Size > operator/ | ( | const vtkVector< A, Size > & | v1, |
const vtkVector< A, Size > & | v2 | ||
) |
Performs division of vectors of the same type.
Definition at line 662 of file vtkVector.h.
vtkVectorOperatorMacro | ( | vtkVector2i | , |
int | , | ||
2 | |||
) |
Overload the operators for the common types.
vtkVectorOperatorMacro | ( | vtkVector2f | , |
float | , | ||
2 | |||
) |
vtkVectorOperatorMacro | ( | vtkVector2d | , |
double | , | ||
2 | |||
) |
vtkVectorOperatorMacro | ( | vtkVector3i | , |
int | , | ||
3 | |||
) |
vtkVectorOperatorMacro | ( | vtkVector3f | , |
float | , | ||
3 | |||
) |
vtkVectorOperatorMacro | ( | vtkVector3d | , |
double | , | ||
3 | |||
) |