Main Page   Class Hierarchy   Compound List   Header Files   Compound Members  

ddgLine2 Class Reference

2D Line object. More...

#include <ddggeom.h>

List of all members.


Public Members

 ddgLine2 ( ddgVector2 *p1, ddgVector2 *p2 )
Constructor using 2 points.

void set ( ddgVector2 *p1, ddgVector2 *p2 )
Constructor using 2 points.

 ddgLine2 (void)
Default constructor.

ddgVector2 o (void)
Return the orthogonal slope vector. Equivalent of 2D normal.

bool solve ( ddgVector2 *v, int dim)
Given X, or Y, find the other. Return ddgFailure if unsolvable.

bool intersect ( ddgLine2 *l, ddgVector2 *pt)
Calculate the intersection point of this line with another.

float isPointLeftOfLine ( ddgVector2 *q)
Returns [-1,1], positive if point is left of line, negative if right, 0 if on.

ddgVector2 p
A point on the line.

ddgVector2 d
Slope vector of the line.


Detailed Description

2D Line object.


The documentation for this class was generated from the following file:
Generated at Sun Sep 17 19:27:54 2000 for Digital Dawn Graphics Toolkit by doxygen 0.49-991205 written by Dimitri van Heesch, © 1997-1999