2D (x,y) point structure - Double More...
#include <point.h>
Public Member Functions | |
Pointd () | |
Pointd (const Pointx< double > &p) | |
Pointd (const Vec2< double > &p) | |
Pointd (double x, double y) | |
![]() | |
Pointx () | |
Pointx (const Pointx< double > &p) | |
Pointx (const Vec2< double > &p) | |
Pointx (double x, double y) | |
![]() | |
Vec2 () | |
Vec2 (const double &p1, const double &p2) | |
Vec2 (const double &scalar) | |
Vec2 (const double *array_xy) | |
Vec2 (const Vec2< double > ©) | |
Vec2 (const Vec2< double > ©) | |
Vec2 (const Vec2< double > ©) | |
Vec2 (const Vec2< double > ©) | |
Vec2 (const Vec2< double > ©) | |
Vec2 (const Vec2< double > ©) | |
Vec2 (const Vec2< double > ©) | |
Vec2 (const Vec2< double > ©) | |
Vec2 (const Vec2< double > ©) | |
Vec2 (const Vec2< float > ©) | |
Vec2 (const Vec2< float > ©) | |
Vec2 (const Vec2< float > ©) | |
Vec2 (const Vec2< float > ©) | |
Vec2 (const Vec2< float > ©) | |
Vec2 (const Vec2< float > ©) | |
Vec2 (const Vec2< float > ©) | |
Vec2 (const Vec2< float > ©) | |
Vec2 (const Vec2< float > ©) | |
Vec2 (const Vec2< int > ©) | |
Vec2 (const Vec2< int > ©) | |
Vec2 (const Vec2< int > ©) | |
Vec2 (const Vec2< int > ©) | |
Vec2 (const Vec2< int > ©) | |
Vec2 (const Vec2< int > ©) | |
Vec2 (const Vec2< int > ©) | |
Vec2 (const Vec2< int > ©) | |
Vec2 (const Vec2< int > ©) | |
Vec2 (const Vec3< double > ©) | |
Vec2 (const Vec4< double > ©) | |
Angle | angle (const Vec2< double > &vector) const |
Calculate the angle between this vector and an other vector. | |
Angle | angle_line (const Vec2< double > &point) const |
Calculate the angle of the line joining this point and other point. | |
Angle | angle_normed (const Vec2< double > &vector) const |
Calculate the angle between this vector and an other vector, where the vectors are unit vectors. | |
double | distance (const Vec2< double > &vector) const |
Calculate the distance between this vector and an other vector. | |
double | dot (const Vec2< double > &vector) const |
Dot products this vector with an other vector. | |
bool | is_equal (const Vec2< double > &other, double epsilon) const |
Returns true if equal within the bounds of an epsilon. | |
double | length () const |
Returns the length (magnitude) of this vector. | |
double | length () const |
float | length () const |
Vec2< double > & | normalize () |
Normalizes this vector. | |
bool | operator!= (const Vec2< double > &vector) const |
!= operator. | |
void | operator*= (const Vec2< double > &vector) |
*= operator. | |
void | operator*= (double value) |
*= operator. | |
void | operator+= (const Vec2< double > &vector) |
+= operator. | |
void | operator+= (double value) |
+= operator. | |
Vec2< double > | operator- () const |
| |
void | operator-= (const Vec2< double > &vector) |
-= operator. | |
void | operator-= (double value) |
-= operator. | |
void | operator/= (const Vec2< double > &vector) |
/= operator. | |
void | operator/= (double value) |
/= operator. | |
bool | operator< (const Vec2< double > &vector) const |
< operator. | |
Vec2< double > & | operator= (const Vec2< double > &vector) |
= operator. | |
bool | operator== (const Vec2< double > &vector) const |
== operator. | |
Vec2< double > & | rotate (const Vec2< double > &hotspot, const Angle &angle) |
Rotate this vector around another point. | |
Vec2< double > & | round () |
Rounds all components of this vector. | |
double | round_value (float value) const |
Rounds a value for the datatype. | |
Additional Inherited Members | ||
![]() | ||
typedef double | datatype | |
![]() | ||
static Pointx< double > | calc_origin (Origin origin, const Sizex< double > &size) | |
Returns the anchor point for the origin within the dimensions of the size structure. | ||
static double | dot (const Vec2< double > &vector_1, const Vec2< double > &vector_2) | |
Dot products a vector with an other vector. | ||
static bool | is_equal (const Vec2< double > &first, const Vec2< double > &second, double epsilon) | |
Returns true if equal within the bounds of an epsilon. | ||
static Vec2< double > | normalize (const Vec2< double > &vector) | |
Normalizes a vector. | ||
static Vec2< double > | rotate (const Vec2< double > &vector, const Vec2< double > &hotspot, const Angle &angle) | |
Rotate a vector around another point. | ||
static Vec2< double > | round (const Vec2< double > &vector) | |
Rounds all components on a vector. | ||
![]() | ||
union { | ||
Type r | ||
Type s | ||
Type x | ||
}; | ||
union { | ||
Type g | ||
Type t | ||
Type y | ||
}; | ||
double | g | |
double | r | |
double | s | |
double | t | |
double | x | |
double | y | |
2D (x,y) point structure - Double
|
inline |
|
inline |
|
inline |
|
inline |