TVector2 Class Reference
[Math classes]

List of all members.

Public Member Functions

 TVector2 (void)
 TVector2 (const real xx, const real yy)
void SetValues (const real xx, const real yy)
uint32 GetDimension (void) const
const real & operator() (const uint32 elemNum) const
real & operator() (const uint32 elemNum)
const real & operator[] (const uint32 elemNum) const
real & operator[] (const uint32 elemNum)
real & X (void)
real & Y (void)
real X (void) const
real Y (void) const
real GetMagnitude (void) const
real GetMagnitudeSquared (void) const
real GetArgument () const
real GetDistance (const TVector2 &rhs) const
boolean SetMagnitude (const real newMagnitude)
void SetToCenter (const TVector2 &v0, const TVector2 &v1)
boolean Normalize (const real zeroTolerance=0.0f)
boolean NormalizeOrReplaceWith (const TVector2 &replacement, const real zeroTolerance=0.0f)
boolean IsEqual (const TVector2 &compareVec, const real zeroTolerance=0.0f) const
void ClampValue (const TVector2 &min, const TVector2 &max)
void Negate (void)
void Interpolate (const TVector2 &vstart, const TVector2 &vend, const float t)
void Swap (TVector2 &v)
TVector2 & operator/= (const real scalar)
TVector2 & operator *= (const real scalar)
TVector2 & operator+= (const TVector2 &v)
TVector2 & operator-= (const TVector2 &v)
TVector2 & operator= (const int32 i)
real Normalize (TVector2 &result) const
real GetNorm () const
real GetSquaredNorm () const

Public Attributes

real x
real y

Static Public Attributes

const TVector2 kZero
const TVector2 kOnes
const TVector2 kUnitX
const TVector2 kUnitY
const TVector2 kNegativeX
const TVector2 kNegativeY

Detailed Description

Defines a two dimensional vector.


Constructor & Destructor Documentation

TVector2::TVector2 (  void   )  [inline]
 

TVector2::TVector2 (  const real  xx,
const real  yy
)  [inline]
 


Member Function Documentation

void TVector2::ClampValue (  const TVector2 &  min,
const TVector2 &  max
) 
 

real TVector2::GetArgument (   )  const [inline]
 

uint32 TVector2::GetDimension (  void   )  const [inline]
 

real TVector2::GetDistance (  const TVector2 &  rhs  )  const [inline]
 

real TVector2::GetMagnitude (  void   )  const [inline]
 

real TVector2::GetMagnitudeSquared (  void   )  const [inline]
 

real TVector2::GetNorm (   )  const [inline]
 

real TVector2::GetSquaredNorm (   )  const [inline]
 

void TVector2::Interpolate (  const TVector2 &  vstart,
const TVector2 &  vend,
const float  t
)  [inline]
 

boolean TVector2::IsEqual (  const TVector2 &  compareVec,
const real  zeroTolerance = 0.0f
)  const
 

void TVector2::Negate (  void   )  [inline]
 

real TVector2::Normalize (  TVector2 &  result  )  const
 

boolean TVector2::Normalize (  const real  zeroTolerance = 0.0f  )  [inline]
 

boolean TVector2::NormalizeOrReplaceWith (  const TVector2 &  replacement,
const real  zeroTolerance = 0.0f
)  [inline]
 

TVector2 & TVector2::operator *= (  const real  scalar  )  [inline]
 

real & TVector2::operator() (  const uint32  elemNum  )  [inline]
 

const real & TVector2::operator() (  const uint32  elemNum  )  const [inline]
 

TVector2 & TVector2::operator+= (  const TVector2 &  v  )  [inline]
 

TVector2 & TVector2::operator-= (  const TVector2 &  v  )  [inline]
 

TVector2 & TVector2::operator/= (  const real  scalar  )  [inline]
 

TVector2& TVector2::operator= (  const int32  i  )  [inline]
 

real & TVector2::operator[] (  const uint32  elemNum  )  [inline]
 

const real & TVector2::operator[] (  const uint32  elemNum  )  const [inline]
 

boolean TVector2::SetMagnitude (  const real  newMagnitude  ) 
 

void TVector2::SetToCenter (  const TVector2 &  v0,
const TVector2 &  v1
) 
 

void TVector2::SetValues (  const real  xx,
const real  yy
)  [inline]
 

void TVector2::Swap (  TVector2 &  v  ) 
 

real TVector2::X (  void   )  const [inline]
 

real & TVector2::X (  void   )  [inline]
 

real TVector2::Y (  void   )  const [inline]
 

real & TVector2::Y (  void   )  [inline]
 


Member Data Documentation

const TVector2 TVector2::kNegativeX [static]
 

const TVector2 TVector2::kNegativeY [static]
 

const TVector2 TVector2::kOnes [static]
 

const TVector2 TVector2::kUnitX [static]
 

const TVector2 TVector2::kUnitY [static]
 

const TVector2 TVector2::kZero [static]
 

real TVector2::x
 

real TVector2::y
 


The documentation for this class was generated from the following file:
Generated on Mon Mar 14 12:29:10 2005 for Carrara SDK Doc by  doxygen 1.3.9.1