CCCoreLib 31 May 2022
CloudCompare Core algorithms
|
Indexed 2D vector. More...
#include <PointProjectionTools.h>
Public Member Functions | |
IndexedCCVector2 () | |
Default constructor. | |
IndexedCCVector2 (PointCoordinateType x, PointCoordinateType y) | |
Constructor. | |
IndexedCCVector2 (PointCoordinateType x, PointCoordinateType y, unsigned i) | |
Constructor. | |
IndexedCCVector2 (const CCVector2 &v) | |
Copy constructor. | |
Public Member Functions inherited from Vector2Tpl< Type > | |
Vector2Tpl (Type s=0) | |
Default constructor. More... | |
Vector2Tpl (Type _x, Type _y) | |
Constructor from a couple of coordinates. More... | |
Type | norm2 () const |
Returns vector square norm. | |
Type | norm () const |
Returns vector norm. | |
void | normalize () |
Sets vector norm to unity. | |
Type | dot (const Vector2Tpl &v) const |
Dot product. | |
Type | cross (const Vector2Tpl &v) const |
Cross product. More... | |
Vector2Tpl & | operator- () |
Inverse operator. | |
Vector2Tpl & | operator+= (const Vector2Tpl &v) |
In-place addition operator. | |
Vector2Tpl & | operator-= (const Vector2Tpl &v) |
In-place subtraction operator. | |
Vector2Tpl & | operator*= (Type v) |
In-place multiplication (by a scalar) operator. | |
Vector2Tpl & | operator/= (Type v) |
In-place division (by a scalar) operator. | |
Vector2Tpl | operator+ (const Vector2Tpl &v) const |
Addition operator. | |
Vector2Tpl | operator- (const Vector2Tpl &v) const |
Subtraction operator. | |
Vector2Tpl | operator* (Type s) const |
Multiplication operator. | |
Vector2Tpl | operator/ (Type s) const |
Division operator. | |
Type & | operator[] (unsigned i) |
Direct coordinate access. | |
const Type & | operator[] (unsigned i) const |
Direct coordinate access (const) | |
Public Attributes | |
unsigned | index |
Point index. | |
Public Attributes inherited from Vector2Tpl< Type > | |
union { | |
struct { | |
Type x | |
Type y | |
} | |
Type u [2] | |
}; | |
Indexed 2D vector.
Used for convex and concave hull computation