|
|
|
line Class Template ReferenceCollaboration diagram for line:![]() Detailed Descriptiontemplate<class Point, class PointRef>
| |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
Public Member Functions | |
| line (const Point &start, const Point &end) | |
| Construct from two points. | |
| line (Istream &) | |
| Construct from Istream. | |
| PointRef | start () const |
| Return first vertex. | |
| PointRef | end () const |
| Return second vertex. | |
| Point | centre () const |
| Return centre (centroid). | |
| scalar | mag () const |
| Return scalar magnitude. | |
| vector | vec () const |
| Return start-end vector. | |
| pointHit | nearestDist (const point &p) const |
| Return nearest distance to line from a given point. | |
| scalar | nearestDist (const line< point, const point & > &edge, point &thisPoint, point &edgePoint) const |
| Return nearest distance from line to line. Returns distance. | |
Friends | |
| Istream & | operator>> (Istream &, line &) |
| Ostream & | operator (Ostream &, const line &) |
| line | ( | const Point & | start, | |
| const Point & | end | |||
| ) | [inline] |
Construct from two points.
Definition at line 48 of file lineI.H.
References Istream::readBegin().
Here is the call graph for this function:

| Point centre | ( | ) | const [inline] |
Return centre (centroid).
Definition at line 87 of file lineI.H.
References Foam::mag(), and line::vec().
Here is the call graph for this function:

| vector vec | ( | ) | const [inline] |
Return start-end vector.
Definition at line 101 of file lineI.H.
References p.
Referenced by line::centre().
Here is the caller graph for this function:

Return nearest distance to line from a given point.
If the nearest point is on the line, return a hit
Definition at line 109 of file lineI.H.
References Foam::mag(), and p.
Here is the call graph for this function:
