Public Member Functions
CLine Class Reference

Detailed Description

A parametric 3D line.

See also:
CVector3, CPlane
Example:

#include <xsi_line.h>

List of all members.

Public Member Functions

SICPPSDK_INLINE  CLine ()
SICPPSDK_INLINE  CLine (const CVector3 &in_point, const CVector3 &in_tangent)
SICPPSDK_INLINE  CLine (const CLine &in_line)
SICPPSDK_INLINE  ~CLine ()
SICPPSDK_INLINE CLine operator= (const CLine &in_line)
SICPPSDK_INLINE bool  operator== (const CLine &in_line) const
SICPPSDK_INLINE bool  operator!= (const CLine &in_line) const
SICPPSDK_INLINE bool  EpsilonEquals (const CLine &in_line, double in_dEpsilon) const
SICPPSDK_INLINE bool  Equals (const CLine &in_line) const
bool  Parallel (const CLine &in_line) const
bool  Collinear (const CLine &in_line) const
SICPPSDK_INLINE CVector3  Project (const CVector3 &in_point) const
SICPPSDK_INLINE CVector3  GetClosestPoint (const CLine &in_line) const
SICPPSDK_INLINE double  GetDistance (const CVector3 &in_point) const
SICPPSDK_INLINE double  GetDistance (const CLine &in_line) const
SICPPSDK_INLINE CVector3  GetPosition (double in_param) const
double  GetParameter (const CVector3 &in_point) const
bool  Intersect (const CLine &in_line, CVector3 &out_point) const
SICPPSDK_INLINE const CVector3 GetOrigin () const
SICPPSDK_INLINE const CVector3 GetTangent () const
SICPPSDK_INLINE CLine SetOrigin (const CVector3 &in_point)
SICPPSDK_INLINE CLine SetTangent (const CVector3 &in_tangent)
SICPPSDK_INLINE CLine Set (const CVector3 &in_point, const CVector3 &in_tangent)
SICPPSDK_INLINE CLine operator*= (const CMatrix3 &in_matrix3)
SICPPSDK_INLINE CLine operator*= (const CMatrix4 &in_matrix4)
SICPPSDK_INLINE CLine operator*= (const CTransformation &in_transformation)
SICPPSDK_INLINE CLine MulByMatrix3InPlace (const CMatrix3 &in_matrix3)
SICPPSDK_INLINE CLine MulByMatrix3 (const CLine &in_line, const CMatrix3 &in_matrix3)
SICPPSDK_INLINE CLine MulByMatrix4InPlace (const CMatrix4 &in_matrix4)
SICPPSDK_INLINE CLine MulByMatrix4 (const CLine &in_line, const CMatrix4 &in_matrix4)
SICPPSDK_INLINE CLine MulByTransformationInPlace (const CTransformation &in_transformation)
SICPPSDK_INLINE CLine MulByTransformation (const CLine &in_line, const CTransformation &in_transformation)

Constructor & Destructor Documentation

SICPPSDK_INLINE CLine ( )

Default constructor.

SICPPSDK_INLINE CLine ( const CVector3 in_point,
const CVector3 in_tangent 
)

Construct a line through given point in given direction.

Parameters:
in_point Point on the line
in_tangent Tangent direction vector
SICPPSDK_INLINE CLine ( const CLine in_line )

Copy constructor.

Parameters:
in_line Line to copy
SICPPSDK_INLINE ~CLine ( )

Default destructor.


Member Function Documentation

SICPPSDK_INLINE CLine & operator= ( const CLine in_line )

Assignment operator.

Parameters:
in_line Line to copy
Returns:
A reference to this line.
SICPPSDK_INLINE bool operator== ( const CLine in_line ) const

Equality operator tests the strict equality of this CLine with the specified line.

Parameters:
in_line Operand line.
Returns:
true if equal else false.
See also:
CLine::Equals
SICPPSDK_INLINE bool operator!= ( const CLine in_line ) const

Inequality operator tests the strict inequality of this CLine with the specified line.

Parameters:
in_line Operand line.
Returns:
true if equal else false.
See also:
CLine::Equals
SICPPSDK_INLINE bool EpsilonEquals ( const CLine in_line,
double  in_dEpsilon 
) const

Tests the equality of this line with the specified line, with a tolerance of Epsilon.

Parameters:
in_line Operand line.
in_dEpsilon Error margin
Possible Values: [0, +INF[ should be a positive value
Returns:
true if equal else false.
SICPPSDK_INLINE bool Equals ( const CLine in_line ) const

Tests the strict equality of this line with the specified line.

Parameters:
in_line Operand line.
Returns:
true if equal else false.
bool Parallel ( const CLine in_line ) const

Tests whether two lines are parallel.

Parameters:
in_line Operand line.
Returns:
true if equal else false.
bool Collinear ( const CLine in_line ) const

Tests whether two lines are collinear.

Parameters:
in_line Operand line.
Returns:
true if equal else false.
SICPPSDK_INLINE CVector3 Project ( const CVector3 in_point ) const

Return projection of given point on this line.

Returns:
Closest point on the line
SICPPSDK_INLINE CVector3 GetClosestPoint ( const CLine in_line ) const

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

Returns:
Closest point on the line
SICPPSDK_INLINE double GetDistance ( const CVector3 in_point ) const

Return distance fromt the line to the given point.

Returns:
Distance to input point
SICPPSDK_INLINE double GetDistance ( const CLine in_line ) const

Return distance fromt the line to the given line.

Returns:
Distance to input line
SICPPSDK_INLINE CVector3 GetPosition ( double  in_param ) const

Return position on line for given parameter.

Parameters:
in_param Parameter on line.
Returns:
Position corresponding to input parameter
double GetParameter ( const CVector3 in_point ) const

Return parameter on line closest to input point.

Returns:
Position corresponding to input parameter
bool Intersect ( const CLine in_line,
CVector3 out_point 
) const

Return intersection of this line with the given line.

Parameters:
in_line Line to intersect.
out_point Closest point of intersection on line.
Returns:
true if lines intersect at a single point else false.
SICPPSDK_INLINE const CVector3 & GetOrigin ( ) const

Return origin of the line.

Returns:
Reference to origin.
SICPPSDK_INLINE const CVector3 & GetTangent ( ) const

Return tangent direction of the line.

Returns:
Reference to tangent.
SICPPSDK_INLINE CLine & SetOrigin ( const CVector3 in_point )

Set origin of the line.

Parameters:
in_point Point on the line
Returns:
A reference to this line.
SICPPSDK_INLINE CLine & SetTangent ( const CVector3 in_tangent )

Set tangent direction of the line.

Parameters:
in_tangent Tangent direction vector.
Returns:
A reference to this line.
SICPPSDK_INLINE CLine & Set ( const CVector3 in_point,
const CVector3 in_tangent 
)

Set origin and tangent direction of the line.

Parameters:
in_point Point on the line
in_tangent Tangent direction vector.
Returns:
A reference to this line.
SICPPSDK_INLINE CLine & operator*= ( const CMatrix3 in_matrix3 )

Right-multiplies this line by the matrix m in place (this = this . m ).

Parameters:
in_matrix3 Operand matrix.
Returns:
A reference to this line.
See also:
CLine::MulByMatrix3InPlace
SICPPSDK_INLINE CLine & operator*= ( const CMatrix4 in_matrix4 )

Right-multiplies this line by the matrix m in place (this = this . m ).

Parameters:
in_matrix4 Operand matrix.
Returns:
A reference to this line.
See also:
CLine::MulByMatrix4InPlace
SICPPSDK_INLINE CLine & operator*= ( const CTransformation in_transformation )

Right-multiplies this line by the transformation t in place (this = this . t).

Parameters:
in_transformation transformation operand.
Returns:
A reference to this line.
See also:
CLine::MulByTransformationInPlace
SICPPSDK_INLINE CLine & MulByMatrix3InPlace ( const CMatrix3 in_matrix3 )

Right-multiplies this line by the matrix m in place (this = this . m ).

Parameters:
in_matrix3 Operand matrix.
Returns:
A reference to this line.
SICPPSDK_INLINE CLine & MulByMatrix3 ( const CLine in_line,
const CMatrix3 in_matrix3 
)

Right-multiplies the line l by the matrix m and store the result in this line (this = l . m ).

Parameters:
in_line Operand line
in_matrix3 Operand matrix.
Returns:
A reference to this line.
SICPPSDK_INLINE CLine & MulByMatrix4InPlace ( const CMatrix4 in_matrix4 )

Right-multiplies this line by the matrix m in place (this = this . m ).

Parameters:
in_matrix4 Operand matrix.
Returns:
A reference to this line.
SICPPSDK_INLINE CLine & MulByMatrix4 ( const CLine in_line,
const CMatrix4 in_matrix4 
)

Right-multiplies the line l by the matrix m and store the result in this line (this = l . m ).

Parameters:
in_line Operand line
in_matrix4 Operand matrix.
Returns:
A reference to this line.
SICPPSDK_INLINE CLine & MulByTransformationInPlace ( const CTransformation in_transformation )

Right-multiplies this line by the transformation t in place (this = this . t).

Parameters:
in_transformation transformation operand.
Returns:
A reference to this line.
SICPPSDK_INLINE CLine & MulByTransformation ( const CLine in_line,
const CTransformation in_transformation 
)

Right-multiplies the line l by the transformation t and stores the result in this line (this = l . t ).

Parameters:
in_line Operand line.
in_transformation transformation operand.
Returns:
A reference to this line.

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