Public Member Functions | Public Attributes

CL_Line2d Class Reference
[clanCore Math]

2D line - Double More...

#include <line.h>

Inheritance diagram for CL_Line2d:
Inheritance graph
[legend]

List of all members.

Public Member Functions

 CL_Line2d ()
 CL_Line2d (const CL_Vec2< double > &point_p, double gradient)
 CL_Line2d (const CL_Vec2< double > &point_p, const CL_Vec2< double > &point_q)
 CL_Line2d (const CL_Line2x< double > &copy)
Attributes

CL_Vec2< double > get_intersection (const CL_Line2x< double > &second, bool &intersect) const
 Return the intersection of this and other line.
double point_right_of_line (CL_Vec2< double > point) const
 Return [<0, 0, >0] if the Point P is right, on or left of the line trough A,B.
Operators

bool operator== (const CL_Line2x< double > &line) const
 == operator.
bool operator!= (const CL_Line2x< double > &line) const
 != operator.

Public Attributes

CL_Vec2< double > p
 First point on the line.
CL_Vec2< double > q

Detailed Description

2D line - Double


Constructor & Destructor Documentation

CL_Line2d::CL_Line2d (  )  [inline]
CL_Line2d::CL_Line2d ( const CL_Line2x< double > &  copy  )  [inline]
CL_Line2d::CL_Line2d ( const CL_Vec2< double > &  point_p,
const CL_Vec2< double > &  point_q 
) [inline]
CL_Line2d::CL_Line2d ( const CL_Vec2< double > &  point_p,
double  gradient 
) [inline]

Member Function Documentation

CL_Vec2<double > CL_Line2x< double >::get_intersection ( const CL_Line2x< double > &  second,
bool &  intersect 
) const [inherited]

Return the intersection of this and other line.

Parameters:
second = The second line to use
intersect = On Return: true if the lines intersect, false if the lines are parallel
Returns:
The point
bool CL_Line2x< double >::operator!= ( const CL_Line2x< double > &  line  )  const [inline, inherited]

!= operator.

bool CL_Line2x< double >::operator== ( const CL_Line2x< double > &  line  )  const [inline, inherited]

== operator.

double CL_Line2x< double >::point_right_of_line ( CL_Vec2< double >  point  )  const [inline, inherited]

Return [<0, 0, >0] if the Point P is right, on or left of the line trough A,B.

Parameters:
point = The point
Returns:
Value representing - left (>0), centre (=0), or right (<0)

Member Data Documentation

CL_Vec2<double > CL_Line2x< double >::p [inherited]

First point on the line.

CL_Vec2<double > CL_Line2x< double >::q [inherited]

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