General purpose float pair, uses include representation of texture coordinates.
General purpose float pair, uses include representation of texture coordinates. No support yet added for float * Vec2 - is it necessary? Need to define a non-member non-friend operator* etc. BTW: Vec2 * float is okay
Vec2(float x, float y)
float _v[2]
bool operator == (const Vec2& v) const
inline float* ptr()
inline const float* ptr() const
inline void set( float x, float y )
inline float& operator [] (int i)
inline float operator [] (int i) const
inline float& x()
inline float& y()
inline float x() const
inline float y() const
inline float operator * (const Vec2& rhs) const
inline Vec2 operator * (const float& rhs) const
inline Vec2& operator *= (const float& rhs)
inline Vec2 operator / (const float& rhs) const
inline Vec2& operator /= (const float& rhs)
inline Vec2 operator + (const Vec2& rhs) const
inline Vec2& operator += (const Vec2& rhs)
inline Vec2 operator - (const Vec2& rhs) const
inline Vec2& operator -= (const Vec2& rhs)
inline Vec2 operator - () const
inline float length() const
inline float length2( void ) const
inline float normalize()
inline friend ostream& operator << (ostream& output, const Vec2& vec)
Alphabetic index HTML hierarchy of classes or Java