2D (x,y) point structure - Float More...

#include <point.h>

+ Inheritance diagram for clan::Pointf:

Public Member Functions

 Pointf ()
 
 Pointf (float x, float y)
 
 Pointf (const Pointx< float > &p)
 
 Pointf (const Vec2< float > &p)
 
- Public Member Functions inherited from clan::Pointx< float >
 Pointx ()
 
 Pointx (floatx, floaty)
 
 Pointx (const Pointx< float > &p)
 
 Pointx (const Vec2< float > &p)
 
- Public Member Functions inherited from clan::Vec2< float >
 Vec2 ()
 
 Vec2 (const float &scalar)
 
 Vec2 (const Vec3< float > &copy)
 
 Vec2 (const Vec4< float > &copy)
 
 Vec2 (const float &p1, const float &p2)
 
 Vec2 (const float *array_xy)
 
 Vec2 (const Vec2< double > &copy)
 
 Vec2 (const Vec2< float > &copy)
 
 Vec2 (const Vec2< int > &copy)
 
Angle angle (const Vec2< float > &vector) const
 Calculate the angle between this vector and an other vector. More...
 
Angle angle_line (const Vec2< float > &point) const
 Calculate the angle of the line joining this point and other point. More...
 
Angle angle_normed (const Vec2< float > &vector) const
 Calculate the angle between this vector and an other vector, where the vectors are unit vectors. More...
 
float distance (const Vec2< float > &vector) const
 Calculate the distance between this vector and an other vector. More...
 
float dot (const Vec2< float > &vector) const
 Dot products this vector with an other vector. More...
 
bool is_equal (const Vec2< float > &other, floatepsilon) const
 Returns true if equal within the bounds of an epsilon. More...
 
float length () const
 Returns the length (magnitude) of this vector. More...
 
Vec2< float > & normalize ()
 Normalizes this vector. More...
 
bool operator!= (const Vec2< float > &vector) const
 != operator. More...
 
void operator*= (const Vec2< float > &vector)
 *= operator. More...
 
void operator*= (floatvalue)
 *= operator. More...
 
void operator+= (const Vec2< float > &vector)
 += operator. More...
 
void operator+= (floatvalue)
 += operator. More...
 
Vec2< float > operator- () const
 
  • operator.
More...
 
void operator-= (const Vec2< float > &vector)
 -= operator. More...
 
void operator-= (floatvalue)
 -= operator. More...
 
void operator/= (const Vec2< float > &vector)
 /= operator. More...
 
void operator/= (floatvalue)
 /= operator. More...
 
bool operator< (const Vec2< float > &vector) const
 < operator. More...
 
Vec2< float > & operator= (const Vec2< float > &vector)
 = operator. More...
 
bool operator== (const Vec2< float > &vector) const
 == operator. More...
 
Vec2< float > & rotate (const Vec2< float > &hotspot, const Angle &angle)
 Rotate this vector around another point. More...
 
Vec2< float > & round ()
 Rounds all components of this vector. More...
 
float round_value (float value) const
 Rounds a value for the datatype. More...
 

Additional Inherited Members

- Public Types inherited from clan::Vec2< float >
typedef float datatype
 
- Static Public Member Functions inherited from clan::Vec2< float >
static Pointx< float > calc_origin (Origin origin, const Sizex< float > &size)
 Returns the anchor point for the origin within the dimensions of the size structure. More...
 
static float dot (const Vec2< float > &vector_1, const Vec2< float > &vector_2)
 Dot products a vector with an other vector. More...
 
static bool is_equal (const Vec2< float > &first, const Vec2< float > &second, floatepsilon)
 Returns true if equal within the bounds of an epsilon. More...
 
static Vec2< float > normalize (const Vec2< float > &vector)
 Normalizes a vector. More...
 
static Vec2< float > rotate (const Vec2< float > &vector, const Vec2< float > &hotspot, const Angle &angle)
 Rotate a vector around another point. More...
 
static Vec2< float > round (const Vec2< float > &vector)
 Rounds all components on a vector. More...
 
- Public Attributes inherited from clan::Vec2< float >
union {
   Type   r
 
   Type   s
 
   Type   x
 
}; 
 
union {
   Type   g
 
   Type   t
 
   Type   y
 
}; 
 
float g
 
float r
 
float s
 
float t
 
float x
 
float y
 

Detailed Description

2D (x,y) point structure - Float

Constructor & Destructor Documentation

clan::Pointf::Pointf ( )
inline
clan::Pointf::Pointf ( float  x,
float  y 
)
inline
clan::Pointf::Pointf ( const Pointx< float > &  p)
inline
clan::Pointf::Pointf ( const Vec2< float > &  p)
inline

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