Main Page | Modules | Namespace List | Class Hierarchy | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

Emma::Line Class Reference

Represents a directed line in 3D space. More...

#include <EmmaLine.h>

List of all members.

Public Member Functions

 Line ()
virtual ~Line ()
EMMA_EXPORT Line (const Fusion::Vec3f &p0, const Fusion::Vec3f &p1)
 Construct a line from two points lying on the line.
EMMA_EXPORT void setValue (const Fusion::Vec3f &p0, const Fusion::Vec3f &p1)
 Set the value given p0 and p1.
EMMA_EXPORT bool getClosestPoints (const Line &line2, Fusion::Vec3f &ptOnThis, Fusion::Vec3f &ptOnLine2) const
 Find closest points between the two lines.
EMMA_EXPORT Fusion::Vec3f getClosestPoint (const Fusion::Vec3f &point) const
 Returns the closest point on the line to the given point.
const Fusion::Vec3fgetPosition () const
 Get position.
const Fusion::Vec3fgetDirection () const
 Get direction.
bool intersect (const Box3f &box, Fusion::Vec3f &enter, Fusion::Vec3f &exit) const
 Intersect the line with a box, point, line, and triangle.
bool intersect (float angle, const Box3f &box) const
 Intersect the line with a box.
bool intersect (float angle, const Fusion::Vec3f &point) const
 Intersect the line with a point.
bool intersect (float angle, const Fusion::Vec3f &v0, const Fusion::Vec3f &v1, Fusion::Vec3f &pt) const
 Intersect the line with a line.
bool intersect (const Fusion::Vec3f &v0, const Fusion::Vec3f &v1, const Fusion::Vec3f &v2, Fusion::Vec3f &pt, Fusion::Vec3f &barycentric, bool &front) const
 Intersect the line with a triangle.


Detailed Description

Represents a directed line in 3D space.


Constructor & Destructor Documentation

Emma::Line::Line  )  [inline]
 

virtual Emma::Line::~Line  )  [inline, virtual]
 

EMMA_EXPORT Emma::Line::Line const Fusion::Vec3f p0,
const Fusion::Vec3f p1
 

Construct a line from two points lying on the line.

If you want to construct a line from a position and a direction, use Line(p, p + d). Line is directed from p0 to p1.


Member Function Documentation

EMMA_EXPORT Fusion::Vec3f Emma::Line::getClosestPoint const Fusion::Vec3f point  )  const
 

Returns the closest point on the line to the given point.

EMMA_EXPORT bool Emma::Line::getClosestPoints const Line line2,
Fusion::Vec3f ptOnThis,
Fusion::Vec3f ptOnLine2
const
 

Find closest points between the two lines.

Return false if they are parallel, otherwise return true.

const Fusion::Vec3f& Emma::Line::getDirection  )  const [inline]
 

Get direction.

const Fusion::Vec3f& Emma::Line::getPosition  )  const [inline]
 

Get position.

bool Emma::Line::intersect const Fusion::Vec3f v0,
const Fusion::Vec3f v1,
const Fusion::Vec3f v2,
Fusion::Vec3f pt,
Fusion::Vec3f barycentric,
bool &  front
const
 

Intersect the line with a triangle.

bool Emma::Line::intersect float  angle,
const Fusion::Vec3f v0,
const Fusion::Vec3f v1,
Fusion::Vec3f pt
const
 

Intersect the line with a line.

bool Emma::Line::intersect float  angle,
const Fusion::Vec3f point
const
 

Intersect the line with a point.

bool Emma::Line::intersect float  angle,
const Box3f box
const
 

Intersect the line with a box.

bool Emma::Line::intersect const Box3f box,
Fusion::Vec3f enter,
Fusion::Vec3f exit
const
 

Intersect the line with a box, point, line, and triangle.

EMMA_EXPORT void Emma::Line::setValue const Fusion::Vec3f p0,
const Fusion::Vec3f p1
 

Set the value given p0 and p1.


The documentation for this class was generated from the following file:
Generated on Sat Apr 1 06:08:23 2006 for Emma SDK Guide by  doxygen 1.4.3