![]() |
TrinityCore
|
#include <LineSegment.h>
Public Member Functions | |
LineSegment () | |
LineSegment (class BinaryInput &b) | |
void | serialize (class BinaryOutput &b) const |
void | deserialize (class BinaryInput &b) |
virtual | ~LineSegment () |
Point3 | point (int i) const |
Point3 | midpoint () const |
float | length () const |
Point3 | closestPoint (const Point3 &point) const |
double | distance (const Point3 &p) const |
double | distanceSquared (const Point3 &p) const |
bool | intersectsSolidSphere (const class Sphere &s) const |
Point3 | randomPoint () const |
Static Public Member Functions | |
static LineSegment | fromTwoPoints (const Point3 &point1, const Point3 &point2) |
Protected Member Functions | |
LineSegment (const Point3 &__point, const Vector3 &_direction) | |
Protected Attributes | |
Point3 | _point |
Vector3 | direction |
An finite segment of an infinite 3D line.
|
inlineprotected |
|
inline |
G3D::LineSegment::LineSegment | ( | class BinaryInput & | b | ) |
Returns the closest point on the line segment to point.
void G3D::LineSegment::deserialize | ( | class BinaryInput & | b | ) |
Returns the distance between point and the line
|
inlinestatic |
Constructs a line from two (not equal) points.
Returns true if some part of this segment is inside the sphere
|
inline |
|
inline |
Vector3 G3D::LineSegment::point | ( | int | i | ) | const |
Call with 0 or 1
Vector3 G3D::LineSegment::randomPoint | ( | ) | const |
void G3D::LineSegment::serialize | ( | class BinaryOutput & | b | ) | const |
|
protected |
|
protected |
Not normalized