Aria
2.8.0
|
Represents geometry of a line in two-dimensional space. More...
#include <ariaUtil.h>
Public Member Functions | |
ArLine (double a, double b, double c) | |
Constructor with parameters. | |
ArLine (double x1, double y1, double x2, double y2) | |
Constructor with endpoints. | |
double | getA (void) const |
Gets the A line parameter. | |
double | getB (void) const |
Gets the B line parameter. | |
double | getC (void) const |
Gets the C line parameter. | |
virtual double | getPerpDist (const ArPose &pose) const |
Calculate the distance from the given point to (its projection on) this line segment. More... | |
bool | getPerpPoint (const ArPose &pose, ArPose *perpPoint) const |
Determine the intersection point between this line segment, and a perpendicular line passing through the given pose (i.e. projects the given pose onto this line segment.) More... | |
virtual double | getPerpSquaredDist (const ArPose &pose) const |
Calculate the squared distance from the given point to (its projection on) this line segment. More... | |
bool | intersects (const ArLine *line, ArPose *pose) const |
finds the intersection of this line with another line More... | |
void | makeLinePerp (const ArPose *pose, ArLine *line) const |
Makes the given line perpendicular to this one through the given pose. | |
void | newParameters (double a, double b, double c) |
Sets the line parameters (make it not a segment) | |
void | newParametersFromEndpoints (double x1, double y1, double x2, double y2) |
Sets the line parameters from endpoints, but makes it not a segment. | |
virtual bool | operator!= (const ArLine &other) const |
Inequality operator. | |
virtual bool | operator== (const ArLine &other) const |
Equality operator. | |
virtual | ~ArLine () |
Destructor. | |
Protected Attributes | |
double | myA |
double | myB |
double | myC |
Represents geometry of a line in two-dimensional space.
Note this the theoretical line, i.e. it goes infinitely. For a line segment with endpoints, use ArLineSegment.
|
inlinevirtual |
Calculate the distance from the given point to (its projection on) this line segment.
pose | the the pose to find the perp point of |
Determine the intersection point between this line segment, and a perpendicular line passing through the given pose (i.e. projects the given pose onto this line segment.)
If there is no intersection, false is returned.
pose | The X and Y components of this pose object indicate the point to project onto this line segment. |
perpPoint | The X and Y components of this pose object are set to indicate the intersection point |
Java and Python Wrappers: Not available in Java or Python wrapper libraries.
|
inlinevirtual |
Calculate the squared distance from the given point to (its projection on) this line segment.
pose | the the pose to find the perp point of |
finds the intersection of this line with another line
line | the line to check if it intersects with this line |
pose | if the lines intersect, the pose is set to the location |