Home | Namespaces | Hierarchy | Alphabetical List | Class list | Files | Namespace Members | Class members | File members
Public Member Functions | Public Attributes
core::line3d Class Reference

3D line between two points with intersection methods. More...

#include <Line3d.h>

List of all members.

Public Member Functions

vector3d getClosestPoint (const vector3d &point) const
 Returns the closest point on this line to a point.
f32 getLength () const
f32 getLengthSQ () const
vector3d getMiddle () const
 Returns middle of line.
vector3d getVector () const
 Returns vector of line.
bool isPointBetweenStartAndEnd (const vector3d &point) const
 line3d (f32 xa, f32 ya, f32 za, f32 xb, f32 yb, f32 zb)
 line3d (const line3d &other)
 line3d ()
 line3d (const vector3d &nstart, const vector3d &nend)
bool operator!= (const line3d &other) const
line3d operator+ (const vector3d &point) const
line3d & operator+= (const vector3d &point)
line3d operator- (const vector3d &point) const
line3d & operator-= (const vector3d &point)
bool operator== (const line3d &other) const
void set (const vector3d &nstart, const vector3d &nend)
void set (const line3d &other)
void set (const f32 &xa, const f32 &ya, const f32 &za, const f32 &xb, const f32 &yb, const f32 &zb)

Public Attributes

vector3d end
vector3d start

Detailed Description

3D line between two points with intersection methods.


Constructor & Destructor Documentation

core::line3d::line3d ( )

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

core::line3d::line3d ( f32  xa,
f32  ya,
f32  za,
f32  xb,
f32  yb,
f32  zb 
)
core::line3d::line3d ( const vector3d &  nstart,
const vector3d &  nend 
)
core::line3d::line3d ( const line3d &  other)

Member Function Documentation

vector3d core::line3d::getClosestPoint ( const vector3d &  point) const

Returns the closest point on this line to a point.

References core::vector3d::dotProduct(), end, core::vector3d::getLength(), and start.

f32 core::line3d::getLength ( ) const

Returns length of line

Returns:
Returns length of line.

References end, core::vector3d::getDistanceFrom(), and start.

f32 core::line3d::getLengthSQ ( ) const

Returns sqared length of line

Returns:
Returns sqared length of line.

References end, core::vector3d::getDistanceFromSQ(), and start.

vector3d core::line3d::getMiddle ( ) const

Returns middle of line.

References end, and start.

vector3d core::line3d::getVector ( ) const

Returns vector of line.

References end, and start.

bool core::line3d::isPointBetweenStartAndEnd ( const vector3d &  point) const

Returns if the over given point is between start and end of the line. Assumes that the point is already somewhere on the line.

References end, core::vector3d::isBetweenPoints(), and start.

bool core::line3d::operator!= ( const line3d &  other) const

References end, and start.

line3d core::line3d::operator+ ( const vector3d &  point) const

References end, line3d(), and start.

line3d & core::line3d::operator+= ( const vector3d &  point)

References end, and start.

line3d core::line3d::operator- ( const vector3d &  point) const

References end, line3d(), and start.

line3d & core::line3d::operator-= ( const vector3d &  point)

References end, and start.

bool core::line3d::operator== ( const line3d &  other) const

References end, and start.

void core::line3d::set ( const vector3d &  nstart,
const vector3d &  nend 
)

References end, core::vector3d::set(), and start.

void core::line3d::set ( const line3d &  other)

References end, core::vector3d::set(), and start.

void core::line3d::set ( const f32 &  xa,
const f32 &  ya,
const f32 &  za,
const f32 &  xb,
const f32 &  yb,
const f32 &  zb 
)

References end, core::vector3d::set(), and start.


Member Data Documentation


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

The KG Game Engine
The KG Game Engine Documentation © 2006-2011 by Kat'Oun. Generated on Sat Jul 2 2011 00:50:07 by Doxygen (1.7.4)