Main Page | Class Hierarchy | Class List | File List | Class Members | File Members

Vec4 Class Reference

#include <Vector.h>

List of all members.

Public Member Functions

 Vec4 ()
 Vec4 (const float xyzw)
 Vec4 (const float xx, const float yy, const float zz, const float ww)
 Vec4 (const Vec2 v, const float zz=0.0f, const float ww=0.0f)
 Vec4 (const float xx, const Vec2 v, const float ww)
 Vec4 (const float xx, const float yy, const Vec2 v)
 Vec4 (const Vec2 v, const Vec2 u)
 Vec4 (const Vec3 v, const float ww=0.0f)
 Vec4 (const float xx, const Vec3 v)
virtual ~Vec4 ()
float length ()
Vec4 normalize ()
Vec4 operator+ (const Vec4 &v)
Vec4 operator- (const Vec4 &v)
Vec4 operator- ()
Vec4 operator * (const float s)
Vec4 operator * (const Vec4 &v)
Vec4 operator/ (const float s)
Vec4 operator/ (const Vec4 &v)
void operator= (const Vec4 &v)
void operator+= (const Vec4 &v)
void operator-= (const Vec4 &v)
void operator *= (const float s)
void operator *= (const Vec4 &v)
void operator/= (const float s)
void operator/= (const Vec4 &v)
bool operator> (Vec4 &v)
bool operator== (const Vec4 &v)
bool operator!= (const Vec4 &v)
float & operator[] (const int index)
 operator const float * () const
 Vec4 ()
 Vec4 (const float xyzw)
 Vec4 (const float xx, const float yy, const float zz, const float ww)
 Vec4 (const Vec2 v, const float zz=0.0f, const float ww=0.0f)
 Vec4 (const float xx, const Vec2 v, const float ww)
 Vec4 (const float xx, const float yy, const Vec2 v)
 Vec4 (const Vec2 v, const Vec2 u)
 Vec4 (const Vec3 v, const float ww=0.0f)
 Vec4 (const float xx, const Vec3 v)
virtual ~Vec4 ()
float length ()
Vec4 normalize ()
Vec4 operator+ (const Vec4 &v)
Vec4 operator- (const Vec4 &v)
Vec4 operator- ()
Vec4 operator * (const float s)
Vec4 operator * (const Vec4 &v)
Vec4 operator/ (const float s)
Vec4 operator/ (const Vec4 &v)
void operator= (const Vec4 &v)
void operator+= (const Vec4 &v)
void operator-= (const Vec4 &v)
void operator *= (const float s)
void operator *= (const Vec4 &v)
void operator/= (const float s)
void operator/= (const Vec4 &v)
bool operator> (Vec4 &v)
bool operator== (const Vec4 &v)
bool operator!= (const Vec4 &v)
float & operator[] (const int index)
 operator const float * () const

Public Attributes

float x
float y
float z
float w


Detailed Description

Definition at line 89 of file DeFacto/Math/Vector.h.


Constructor & Destructor Documentation

Vec4::Vec4  ) 
 

Vec4.cpp

Author: Petter Alstermark, petter@alstermark.com

Definition at line 16 of file DeFacto/Math/Vec4.cpp.

References w, x, y, and z.

Referenced by operator *(), operator+(), operator-(), and operator/().

Vec4::Vec4 const float  xyzw  ) 
 

Definition at line 23 of file DeFacto/Math/Vec4.cpp.

References w, x, y, and z.

Vec4::Vec4 const float  xx,
const float  yy,
const float  zz,
const float  ww
 

Definition at line 30 of file DeFacto/Math/Vec4.cpp.

References w, x, y, and z.

Vec4::Vec4 const Vec2  v,
const float  zz = 0.0f,
const float  ww = 0.0f
 

Definition at line 60 of file DeFacto/Math/Vec4.cpp.

References w, Vec2::x, x, Vec2::y, y, and z.

Vec4::Vec4 const float  xx,
const Vec2  v,
const float  ww
 

Definition at line 70 of file DeFacto/Math/Vec4.cpp.

References w, Vec2::x, x, Vec2::y, y, and z.

Vec4::Vec4 const float  xx,
const float  yy,
const Vec2  v
 

Definition at line 80 of file DeFacto/Math/Vec4.cpp.

References w, Vec2::x, x, Vec2::y, y, and z.

Vec4::Vec4 const Vec2  v,
const Vec2  u
 

Definition at line 90 of file DeFacto/Math/Vec4.cpp.

References w, Vec2::x, x, Vec2::y, y, and z.

Vec4::Vec4 const Vec3  v,
const float  ww = 0.0f
 

Definition at line 40 of file DeFacto/Math/Vec4.cpp.

References w, Vec3::x, x, Vec3::y, y, Vec3::z, and z.

Vec4::Vec4 const float  xx,
const Vec3  v
 

Definition at line 50 of file DeFacto/Math/Vec4.cpp.

References w, Vec3::x, x, Vec3::y, y, Vec3::z, and z.

Vec4::~Vec4  )  [virtual]
 

Definition at line 100 of file DeFacto/Math/Vec4.cpp.

Vec4::Vec4  ) 
 

Vec4::Vec4 const float  xyzw  ) 
 

Vec4::Vec4 const float  xx,
const float  yy,
const float  zz,
const float  ww
 

Vec4::Vec4 const Vec2  v,
const float  zz = 0.0f,
const float  ww = 0.0f
 

Vec4::Vec4 const float  xx,
const Vec2  v,
const float  ww
 

Vec4::Vec4 const float  xx,
const float  yy,
const Vec2  v
 

Vec4::Vec4 const Vec2  v,
const Vec2  u
 

Vec4::Vec4 const Vec3  v,
const float  ww = 0.0f
 

Vec4::Vec4 const float  xx,
const Vec3  v
 

virtual Vec4::~Vec4  )  [virtual]
 


Member Function Documentation

float Vec4::length  ) 
 

float Vec4::length  ) 
 

Definition at line 107 of file DeFacto/Math/Vec4.cpp.

References w, x, y, and z.

Referenced by normalize(), and operator>().

Vec4 Vec4::normalize  ) 
 

Vec4 Vec4::normalize  ) 
 

Definition at line 114 of file DeFacto/Math/Vec4.cpp.

References length().

Here is the call graph for this function:

Vec4 Vec4::operator * const Vec4 v  ) 
 

Vec4 Vec4::operator * const float  s  ) 
 

Vec4 Vec4::operator * const Vec4 v  ) 
 

Definition at line 152 of file DeFacto/Math/Vec4.cpp.

References Vec4(), w, x, y, and z.

Here is the call graph for this function:

Vec4 Vec4::operator * const float  s  ) 
 

Definition at line 145 of file DeFacto/Math/Vec4.cpp.

References Vec4(), w, x, y, and z.

Here is the call graph for this function:

void Vec4::operator *= const Vec4 v  ) 
 

void Vec4::operator *= const float  s  ) 
 

void Vec4::operator *= const Vec4 v  ) 
 

Definition at line 224 of file DeFacto/Math/Vec4.cpp.

References w, x, y, and z.

void Vec4::operator *= const float  s  ) 
 

Definition at line 214 of file DeFacto/Math/Vec4.cpp.

References w, x, y, and z.

Vec4::operator const float *  )  const [inline]
 

Definition at line 126 of file LevelCreator/Math/Vector.h.

References x.

Vec4::operator const float *  )  const [inline]
 

Definition at line 126 of file DeFacto/Math/Vector.h.

References x.

bool Vec4::operator!= const Vec4 v  ) 
 

bool Vec4::operator!= const Vec4 v  ) 
 

Definition at line 268 of file DeFacto/Math/Vec4.cpp.

References w, x, y, and z.

Vec4 Vec4::operator+ const Vec4 v  ) 
 

Vec4 Vec4::operator+ const Vec4 v  ) 
 

Definition at line 124 of file DeFacto/Math/Vec4.cpp.

References Vec4(), w, x, y, and z.

Here is the call graph for this function:

void Vec4::operator+= const Vec4 v  ) 
 

void Vec4::operator+= const Vec4 v  ) 
 

Definition at line 194 of file DeFacto/Math/Vec4.cpp.

References w, x, y, and z.

Vec4 Vec4::operator-  ) 
 

Vec4 Vec4::operator- const Vec4 v  ) 
 

Vec4 Vec4::operator-  ) 
 

Definition at line 138 of file DeFacto/Math/Vec4.cpp.

References Vec4(), w, x, y, and z.

Here is the call graph for this function:

Vec4 Vec4::operator- const Vec4 v  ) 
 

Definition at line 131 of file DeFacto/Math/Vec4.cpp.

References Vec4(), w, x, y, and z.

Here is the call graph for this function:

void Vec4::operator-= const Vec4 v  ) 
 

void Vec4::operator-= const Vec4 v  ) 
 

Definition at line 204 of file DeFacto/Math/Vec4.cpp.

References w, x, y, and z.

Vec4 Vec4::operator/ const Vec4 v  ) 
 

Vec4 Vec4::operator/ const float  s  ) 
 

Vec4 Vec4::operator/ const Vec4 v  ) 
 

Definition at line 177 of file DeFacto/Math/Vec4.cpp.

References Vec4(), w, x, y, and z.

Here is the call graph for this function:

Vec4 Vec4::operator/ const float  s  ) 
 

Vec4 Vec4::operator ^ (const Vec4 &v) { Vec4 u; u.x = (y*v.z) - (z*v.y); u.y = (z*v.x) - (x*v.z); u.z = (x*v.y) - (y*v.x); return u;

Definition at line 170 of file DeFacto/Math/Vec4.cpp.

References Vec4(), w, x, y, and z.

Here is the call graph for this function:

void Vec4::operator/= const Vec4 v  ) 
 

void Vec4::operator/= const float  s  ) 
 

void Vec4::operator/= const Vec4 v  ) 
 

Definition at line 244 of file DeFacto/Math/Vec4.cpp.

References w, x, y, and z.

void Vec4::operator/= const float  s  ) 
 

Definition at line 234 of file DeFacto/Math/Vec4.cpp.

References w, x, y, and z.

void Vec4::operator= const Vec4 v  ) 
 

void Vec4::operator= const Vec4 v  ) 
 

Definition at line 184 of file DeFacto/Math/Vec4.cpp.

References w, x, y, and z.

bool Vec4::operator== const Vec4 v  ) 
 

bool Vec4::operator== const Vec4 v  ) 
 

Definition at line 261 of file DeFacto/Math/Vec4.cpp.

References w, x, y, and z.

bool Vec4::operator> Vec4 v  ) 
 

bool Vec4::operator> Vec4 v  ) 
 

Definition at line 254 of file DeFacto/Math/Vec4.cpp.

References length().

Here is the call graph for this function:

float& Vec4::operator[] const int  index  )  [inline]
 

Definition at line 125 of file LevelCreator/Math/Vector.h.

References x.

float& Vec4::operator[] const int  index  )  [inline]
 

Definition at line 125 of file DeFacto/Math/Vector.h.

References x.


Member Data Documentation

float Vec4::w
 

Definition at line 129 of file LevelCreator/Math/Vector.h.

Referenced by OpenGLRenderer::changeShaderConstant4f(), dot(), OpenGLParticleSystem::drawAndUpdate(), Explosion::drawAndUpdate(), Join::getPlayerChatColor(), length(), operator *(), operator *=(), operator!=(), operator+(), operator+=(), operator-(), operator-=(), operator/(), operator/=(), operator=(), operator==(), Particle::Particle(), OpenGLFont::setColor(), ParticleSystem::update(), and Vec4().

float Vec4::x
 

Definition at line 129 of file LevelCreator/Math/Vector.h.

Referenced by OpenGLRenderer::changeShaderConstant4f(), dot(), OpenGLParticleSystem::drawAndUpdate(), Explosion::drawAndUpdate(), Join::getPlayerChatColor(), length(), ParticleSystem::loadPreset(), operator *(), Mat4::operator *(), operator *=(), operator const float *(), operator!=(), operator+(), operator+=(), operator-(), operator-=(), operator/(), operator/=(), operator=(), operator==(), operator[](), Particle::Particle(), OpenGLFont::setColor(), ParticleSystem::update(), Particle::update(), MainApp::update(), and Vec4().

float Vec4::y
 

Definition at line 129 of file LevelCreator/Math/Vector.h.

Referenced by OpenGLRenderer::changeShaderConstant4f(), dot(), OpenGLParticleSystem::draw(), OpenGLParticleSystem::drawAndUpdate(), Explosion::drawAndUpdate(), Join::getPlayerChatColor(), length(), ParticleSystem::loadPreset(), operator *(), Mat4::operator *(), operator *=(), operator!=(), operator+(), operator+=(), operator-(), operator-=(), operator/(), operator/=(), operator=(), operator==(), Particle::Particle(), OpenGLFont::setColor(), ParticleSystem::update(), Particle::update(), MainApp::update(), and Vec4().

float Vec4::z
 

Definition at line 129 of file LevelCreator/Math/Vector.h.

Referenced by OpenGLRenderer::changeShaderConstant4f(), dot(), OpenGLParticleSystem::draw(), OpenGLParticleSystem::drawAndUpdate(), Explosion::drawAndUpdate(), Join::getPlayerChatColor(), length(), ParticleSystem::loadPreset(), operator *(), Mat4::operator *(), operator *=(), operator!=(), operator+(), operator+=(), operator-(), operator-=(), operator/(), operator/=(), operator=(), operator==(), Particle::Particle(), OpenGLFont::setColor(), ParticleSystem::update(), Particle::update(), MainApp::update(), and Vec4().


Generated on Sun Jun 5 15:51:12 2005 for Defacto by  doxygen 1.4.3