class: etk::Vector2D


Description:



Constructor and Destructor:

+                     Vector2D                (void );
+ Vector2D (T _x,
T _y);
+ Vector2D (const Vector2D<double> & obj);
+ Vector2D (const Vector2D<float> & obj);
+ Vector2D (const Vector2D<int32_t> & obj);
+ Vector2D (const std::string & str);
+ Vector2D (const std::u32string & str);
+ ~Vector2D (void );

Synopsis:

+ T                   m_floats;
+ const Vector2D<T> & operator = (const Vector2D<T> & obj);
+ const Vector2D<T> & operator = (const T val);
+ bool operator == (const Vector2D<T> & obj) const;
+ bool operator != (const Vector2D<T> & obj) const;
+ const Vector2D<T> & operator += (const Vector2D<T> & obj);
+ const Vector2D<T> & operator += (const T val);
+ Vector2D<T> operator + (const Vector2D<T> & obj) const;
+ Vector2D<T> operator + (const T val) const;
+ const Vector2D<T> & operator -= (const Vector2D<T> & obj);
+ const Vector2D<T> & operator -= (const T val);
+ Vector2D<T> operator - (const Vector2D<T> & obj) const;
+ Vector2D<T> operator - (const T val) const;
+ const Vector2D<T> & operator *= (const Vector2D<T> & obj);
+ const Vector2D<T> & operator *= (const T val);
+ Vector2D<T> operator * (const Vector2D<T> & obj) const;
+ Vector2D<T> operator * (const T val) const;
+ Vector2D<T> operator (const Vector2D<T> & obj) const;
+ Vector2D<T> operator (const T val) const;
+ Vector2D<T> & operator ++ (void );
+ Vector2D<T> operator ++ (int unused);
+ Vector2D<T> & operator -- (void );
+ Vector2D<T> operator -- (int unused);
+ btScalar dot (const Vector2D<T> & v) const;
+ btScalar length2 (void ) const;
+ btScalar length (void ) const;
+ btScalar distance2 (const btVector3 & v) const;
+ btScalar distance (const btVector3 & v) const;
+ Vector3D<T> & normalize (void );
+ Vector2D<T> normalized (void ) const;
+ Vector2D<T> absolute (void ) const;
+ int32_t minAxis (void ) const;
+ int32_t maxAxis (void ) const;
+ int32_t furthestAxis (void ) const;
+ int32_t closestAxis (void ) const;
+ const T & getX (void ) const;
+ const T & getY (void ) const;
+ void setX (T _x);
+ void setY (T _y);
+ const T & x (void ) const;
+ const T & y (void ) const;
+ operator T * (void );
+ operator const T * (void ) const;
+ void setMax (const Vector2D<T> & other);
+ void setMin (const Vector2D<T> & other);
+ void setValue (const T & _x,
const T & _y);
+ void setZero (void );
+ bool isZero (void ) const;
+ operator std::string (void ) const;
+ operator std::u32string (void ) const;

Detail:

m_floats

+ T m_floats;



Vector2D

+  Vector2D (void );



Vector2D

+  Vector2D (T _x,
T _y);



Vector2D

+  Vector2D (const Vector2D<double> & obj);



Vector2D

+  Vector2D (const Vector2D<float> & obj);



Vector2D

+  Vector2D (const Vector2D<int32_t> & obj);



Vector2D

+  Vector2D (const std::string & str);



Vector2D

+  Vector2D (const std::u32string & str);



~Vector2D

+  ~Vector2D (void );



operator =

+ const Vector2D<T> & operator = (const Vector2D<T> & obj);



operator =

+ const Vector2D<T> & operator = (const T val);



operator ==

+ bool operator == (const Vector2D<T> & obj) const;



operator !=

+ bool operator != (const Vector2D<T> & obj) const;



operator +=

+ const Vector2D<T> & operator += (const Vector2D<T> & obj);



operator +=

+ const Vector2D<T> & operator += (const T val);



operator +

+ Vector2D<T> operator + (const Vector2D<T> & obj) const;



operator +

+ Vector2D<T> operator + (const T val) const;



operator -=

+ const Vector2D<T> & operator -= (const Vector2D<T> & obj);



operator -=

+ const Vector2D<T> & operator -= (const T val);



operator -

+ Vector2D<T> operator - (const Vector2D<T> & obj) const;



operator -

+ Vector2D<T> operator - (const T val) const;



operator *=

+ const Vector2D<T> & operator *= (const Vector2D<T> & obj);



operator *=

+ const Vector2D<T> & operator *= (const T val);



operator *

+ Vector2D<T> operator * (const Vector2D<T> & obj) const;



operator *

+ Vector2D<T> operator * (const T val) const;



operator

+ Vector2D<T> operator (const Vector2D<T> & obj) const;



operator

+ Vector2D<T> operator (const T val) const;



operator ++

+ Vector2D<T> & operator ++ (void );



operator ++

+ Vector2D<T> operator ++ (int unused);



operator --

+ Vector2D<T> & operator -- (void );



operator --

+ Vector2D<T> operator -- (int unused);



dot

+ btScalar dot (const Vector2D<T> & v) const;
Return the dot product


length2

+ btScalar length2 (void ) const;
Return the length of the vector squared


length

+ btScalar length (void ) const;
Return the length of the vector


distance2

+ btScalar distance2 (const btVector3 & v) const;
Return the distance squared between the ends of this and another vector This is symantically treating the vector like a point


distance

+ btScalar distance (const btVector3 & v) const;
Return the distance between the ends of this and another vector This is symantically treating the vector like a point


normalize

+ Vector3D<T> & normalize (void );
Normalize this vector x^2 + y^2 + z^2 = 1


normalized

+ Vector2D<T> normalized (void ) const;
Return a normalized version of this vector


absolute

+ Vector2D<T> absolute (void ) const;
Return a vector will the absolute values of each element


minAxis

+ int32_t minAxis (void ) const;
Return the axis with the smallest value Note return values are 0,1,2 for x, y, or z


maxAxis

+ int32_t maxAxis (void ) const;
Return the axis with the largest value Note return values are 0,1,2 for x, y, or z


furthestAxis

+ int32_t furthestAxis (void ) const;



closestAxis

+ int32_t closestAxis (void ) const;



getX

+ const T & getX (void ) const;
Return the x value


getY

+ const T & getY (void ) const;
Return the y value


setX

+ void setX (T _x);
Set the x value


setY

+ void setY (T _y);
Set the y value


x

+ const T & x (void ) const;
Return the x value


y

+ const T & y (void ) const;
Return the y value


operator T *

+  operator T * (void );



operator const T *

+  operator const T * (void ) const;



setMax

+ void setMax (const Vector2D<T> & other);
Set each element to the max of the current values and the values of another btVector3


setMin

+ void setMin (const Vector2D<T> & other);
Set each element to the min of the current values and the values of another btVector3


setValue

+ void setValue (const T & _x,
const T & _y);



setZero

+ void setZero (void );



isZero

+ bool isZero (void ) const;



operator std::string

+  operator std::string (void ) const;



operator std::u32string

+  operator std::u32string (void ) const;