Line3
A line.
Constructor Summary
Public Constructor | ||
public |
constructor(start: Vector3, end: Vector3) Constructs a new line. |
Member Summary
Public Members | ||
public |
The ending point. |
|
public |
The starting point. |
Method Summary
Public Methods | ||
public |
Adjusts this line to point in the given direction. |
|
public |
Clones this line. |
|
public |
closestPointToPoint(p: Vector3, clampToLine: Boolean, target: Vector3): Vector3 Returns the closest point on the line. |
|
public |
Copies the values of the given line. |
|
public |
Calculates the delta vector of this line. |
|
public |
Checks if this line equals the given one. |
|
public |
Calculates the center of this line. |
|
public |
Calculates the length of this line. |
|
public |
Calculates the squared length of this line. |
|
public |
Sets the starting and ending point of this line. |
Public Constructors
Public Members
Public Methods
public at(d: Vector3, target: Vector3): Vector3 source
Adjusts this line to point in the given direction.
public closestPointToPoint(p: Vector3, clampToLine: Boolean, target: Vector3): Vector3 source
Returns the closest point on the line.
public copy(l: Line3): Line3 source
Copies the values of the given line.
Params:
Name | Type | Attribute | Description |
l | Line3 | A line. |
public delta(target: Vector3): Vector3 source
Calculates the delta vector of this line.
Params:
Name | Type | Attribute | Description |
target | Vector3 |
|
A target vector. If none is provided, a new one will be created. |
public equals(l: Line3): Boolean source
Checks if this line equals the given one.
Params:
Name | Type | Attribute | Description |
l | Line3 | A line. |
public getCenter(target: Vector3): Vector3 source
Calculates the center of this line.
Params:
Name | Type | Attribute | Description |
target | Vector3 |
|
A target vector. If none is provided, a new one will be created. |