FX::FXVec3d Class Reference

#include <FXVec3d.h>

List of all members.


Detailed Description

Double-precision 3-element vector.

Public Member Functions

 FXVec3d ()
 FXVec3d (const FXVec3d &v)
 FXVec3d (const FXdouble v[])
 FXVec3d (FXdouble xx, FXdouble yy, FXdouble zz=1.0)
 FXVec3d (FXColor color)
FXdouble & operator[] (FXint i)
const FXdouble & operator[] (FXint i) const
FXVec3doperator= (FXColor color)
FXVec3doperator= (const FXVec3d &v)
FXVec3doperator= (const FXdouble v[])
FXVec3dset (const FXVec3d &v)
FXVec3dset (const FXdouble v[])
FXVec3dset (FXdouble xx, FXdouble yy, FXdouble zz)
FXVec3doperator*= (FXdouble n)
FXVec3doperator/= (FXdouble n)
FXVec3doperator+= (const FXVec3d &v)
FXVec3doperator-= (const FXVec3d &v)
 operator FXdouble * ()
 operator const FXdouble * () const
 operator FXVec2d & ()
 operator const FXVec2d & () const
 operator FXColor () const
FXVec3d operator+ () const
FXVec3d operator- () const
FXVec3d operator+ (const FXVec3d &v) const
FXVec3d operator- (const FXVec3d &v) const
FXVec3d operator* (const FXMat3d &m) const
FXVec3d operator* (const FXMat4d &m) const
FXdouble operator* (const FXVec3d &v) const
FXVec3d operator^ (const FXVec3d &v) const
bool operator! () const
bool operator== (const FXVec3d &v) const
bool operator!= (const FXVec3d &v) const
bool operator< (const FXVec3d &v) const
bool operator<= (const FXVec3d &v) const
bool operator> (const FXVec3d &v) const
bool operator>= (const FXVec3d &v) const
FXdouble length2 () const
FXdouble length () const
FXVec3dclamp (FXdouble lo, FXdouble hi)

Public Attributes

FXdouble x
FXdouble y
FXdouble z

Friends

FXVec3d operator* (const FXVec3d &a, FXdouble n)
FXVec3d operator* (FXdouble n, const FXVec3d &a)
FXVec3d operator/ (const FXVec3d &a, FXdouble n)
FXVec3d operator/ (FXdouble n, const FXVec3d &a)
bool operator== (const FXVec3d &a, FXdouble n)
bool operator!= (const FXVec3d &a, FXdouble n)
bool operator== (FXdouble n, const FXVec3d &a)
bool operator!= (FXdouble n, const FXVec3d &a)
bool operator< (const FXVec3d &a, FXdouble n)
bool operator<= (const FXVec3d &a, FXdouble n)
bool operator> (const FXVec3d &a, FXdouble n)
bool operator>= (const FXVec3d &a, FXdouble n)
bool operator< (FXdouble n, const FXVec3d &a)
bool operator<= (FXdouble n, const FXVec3d &a)
bool operator> (FXdouble n, const FXVec3d &a)
bool operator>= (FXdouble n, const FXVec3d &a)
FXVec3d veclo (const FXVec3d &a, const FXVec3d &b)
FXVec3d vechi (const FXVec3d &a, const FXVec3d &b)
FXAPI FXVec3d vecnormal (const FXVec3d &a, const FXVec3d &b, const FXVec3d &c)
FXAPI FXVec3d vecnormal (const FXVec3d &a, const FXVec3d &b, const FXVec3d &c, const FXVec3d &d)
FXAPI FXVec3d vecnormalize (const FXVec3d &v)
FXAPI FXStreamoperator<< (FXStream &store, const FXVec3d &v)
FXAPI FXStreamoperator>> (FXStream &store, FXVec3d &v)

Constructor & Destructor Documentation

FX::FXVec3d::FXVec3d (  )  [inline]

Default constructor.

FX::FXVec3d::FXVec3d ( const FXVec3d v  )  [inline]

Initialize from another vector.

References x, y, and z.

FX::FXVec3d::FXVec3d ( const FXdouble  v[]  )  [inline]

Initialize from array of doubles.

FX::FXVec3d::FXVec3d ( FXdouble  xx,
FXdouble  yy,
FXdouble  zz = 1.0 
) [inline]

Initialize with components.

FX::FXVec3d::FXVec3d ( FXColor  color  ) 

Initialize with color.


Member Function Documentation

FXdouble& FX::FXVec3d::operator[] ( FXint  i  )  [inline]

Return a non-const reference to the ith element.

const FXdouble& FX::FXVec3d::operator[] ( FXint  i  )  const [inline]

Return a const reference to the ith element.

FXVec3d& FX::FXVec3d::operator= ( FXColor  color  ) 

Assign color.

FXVec3d& FX::FXVec3d::operator= ( const FXVec3d v  )  [inline]

Assignment.

References x, y, and z.

FXVec3d& FX::FXVec3d::operator= ( const FXdouble  v[]  )  [inline]

Assignment from array of doubles.

FXVec3d& FX::FXVec3d::set ( const FXVec3d v  )  [inline]

Set value from another vector.

Referenced by FX::FXRanged::set().

FXVec3d& FX::FXVec3d::set ( const FXdouble  v[]  )  [inline]

Set value from array of floats.

FXVec3d& FX::FXVec3d::set ( FXdouble  xx,
FXdouble  yy,
FXdouble  zz 
) [inline]

Set value from components.

FXVec3d& FX::FXVec3d::operator*= ( FXdouble  n  )  [inline]

Assigning operators.

FX::FXVec3d::operator FXdouble * (  )  [inline]

Conversions.

FX::FXVec3d::operator FXColor (  )  const

Convert to color.

FXVec3d FX::FXVec3d::operator+ (  )  const [inline]

Unary.

FXVec3d FX::FXVec3d::operator+ ( const FXVec3d v  )  const [inline]

Vector and vector.

References x, y, and z.

FXVec3d FX::FXVec3d::operator* ( const FXMat3d m  )  const

Vector and matrix.

FXdouble FX::FXVec3d::operator* ( const FXVec3d v  )  const [inline]

Dot product.

References x, y, and z.

FXVec3d FX::FXVec3d::operator^ ( const FXVec3d v  )  const [inline]

Cross product.

References x, y, and z.

bool FX::FXVec3d::operator! (  )  const [inline]

Test if zero.

bool FX::FXVec3d::operator== ( const FXVec3d v  )  const [inline]

Equality tests.

References x, y, and z.

bool FX::FXVec3d::operator< ( const FXVec3d v  )  const [inline]

Inequality tests.

References x, y, and z.

FXdouble FX::FXVec3d::length2 (  )  const [inline]

Length and square of length.

FXVec3d& FX::FXVec3d::clamp ( FXdouble  lo,
FXdouble  hi 
) [inline]

Clamp values of vector between limits.


Friends And Related Function Documentation

FXVec3d operator* ( const FXVec3d a,
FXdouble  n 
) [friend]

Scaling.

FXVec3d veclo ( const FXVec3d a,
const FXVec3d b 
) [friend]

Lowest or highest components.

FXAPI FXVec3d vecnormal ( const FXVec3d a,
const FXVec3d b,
const FXVec3d c 
) [friend]

Compute normal from three points a,b,c.

FXAPI FXVec3d vecnormal ( const FXVec3d a,
const FXVec3d b,
const FXVec3d c,
const FXVec3d d 
) [friend]

Compute approximate normal from four points a,b,c,d.

FXAPI FXVec3d vecnormalize ( const FXVec3d v  )  [friend]

Normalize vector.

FXAPI FXStream& operator<< ( FXStream store,
const FXVec3d v 
) [friend]

Save vector to a stream.

FXAPI FXStream& operator>> ( FXStream store,
FXVec3d v 
) [friend]

Load vector from a stream.


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

(C) 2002-2008 Niall Douglas. Some parts (C) to assorted authors.
Generated on Fri Jun 13 22:25:30 2008 for TnFOX by doxygen v1.5.6