ILine_DG Interface
Represents a 3D ray (axis) defined by its origin and direction.
A standalone line can be constructed via IObjectGenerator_DG.Create<ILine_DG>() > ILine_DG query.
Implements also: IObject_DG.
Properties
 double Radius
 PointDg Origin
 VectDg Direction
Methods
 Init
 Init
 Init
 DirectTowards
 GetPoint
 ReverseDirection
 GetDistance
 GetDistanceLine
 GetLineIntersection
 GetAngle
 GetPointLocation
 GetPointPosition
 IsCollinear
 IsCoplanar
 GetLineLocation
 Rotate
 Slide
 Copy
 Clone
 GetPointProjection
 GetPointProjection1
 GetVectorProjection
void Init(PointDg origin, VectDg direction)
void Init(PointDg end0, PointDg end1)
void Init(Line_DG line)
void DirectTowards(PointDg target, bool success)
PointDg GetPoint(double u)
void ReverseDirection()
double GetDistance(PointDg point, out PointDg pointNearestOnThis, out double paramOnThis)
Computes distance point to this line.
pointNearestOnThis  [out] Parameter along this of the nearest point (distance origin to the point).
double GetDistanceLine(ILine_DG line, out double paramNearestThis, out double paramNearestLine)
Computes distance between two 3D lines.
paramNearestThis  [out] Parameter along this of the nearest point on this (distance origin to the point). Random if lines are collinear
paramNearestLine  [out] Parameter along line of the nearest point on line (distance origin to the point). Random if lines are collinear
bool GetLineIntersection(ILine_DG line, double tolerance, out double paramThis, out double paramLine, out PointDg intersection)
Returns false if there is no single intersection point
paramThis  [out] Parameter of the intersection point on this (distance origin to the point).
paramLine  [out] Parameter of the intersection point on line.
double GetAngle(ILine_DG line)
Returns angle between the two lines in radians.
PointVsLineLocation_DG GetPointLocation(PointDg point)
PointVsLineLocation_DG GetPointLocation(PointDg point, double tolerance)
double GetPointPosition(PointDg point)
Returns parameter of the point along the line, which is equal to distance to origin. Uses projection to the line if the point is outside.
bool IsCollinear(ILine_DG iLine, double tolerance)
bool IsCoplanar(ILine_DG line, double tolerance)
LineVsLineLocation_DG GetLineLocation(ILine_DG line)
LineVsLineLocation_DG GetLineLocation(ILine_DG line, double tolerance)
void Rotate(ILine_DG axis, double angleBy)
angleBy is expected in radians.
void Slide(double dist)
Slides origin along the line by dist, which can be negative.
void Copy(ILine_DG line)
ILine_DG Clone()
Returns a new copy of this.
PointDg GetPointProjection(PointDg point)
double GetPointProjection1(PointDg point)
Returns parameter of the projected point.
VectDg GetVectorProjection(VectDg vector)
