| Package | org.papervision3d.core.math |
| Class | public class Plane3D |
| Property | Defined by | ||
|---|---|---|---|
| d : Number
D.
| Plane3D | ||
| normal : Number3D
The plane normal (A, B, C).
| Plane3D | ||
| Method | Defined by | ||
|---|---|---|---|
|
Constructor.
| Plane3D | ||
|
Get the closest point on the plane.
| Plane3D | ||
|
distance(pt:*):Number
distance of point to plane.
| Plane3D | ||
|
fromCoefficients(a:Number, b:Number, c:Number, d:Number):Plane3D
[static]
Creates a plane from coefficients.
| Plane3D | ||
|
fromNormalAndPoint(normal:*, point:*):Plane3D
[static]
Creates a plane from a normal and a point.
| Plane3D | ||
|
fromThreePoints(p0:*, p1:*, p2:*):Plane3D
[static]
Creates a plane from three points.
| Plane3D | ||
|
normalize():void
normalize.
| Plane3D | ||
|
pointOnSide(num:Number3D):int
Gets the side a vertex is on.
| Plane3D | ||
|
projectPoints(points:Array, origin:Number3D = null):void
Projects points onto this plane.
| Plane3D | ||
|
setCoefficients(a:Number, b:Number, c:Number, d:Number):void
Sets this plane from ABCD coefficients.
| Plane3D | ||
|
Sets this plane from a normal and a point.
| Plane3D | ||
|
Sets this plane from three points.
| Plane3D | ||
|
toString():String
| Plane3D | ||
| d | property |
public var d:NumberD.
| normal | property |
public var normal:Number3DThe plane normal (A, B, C).
| Plane3D | () | constructor |
public function Plane3D(normal:Number3D = null, ptOnPlane:Number3D = null)Constructor.
Parametersnormal:Number3D (default = null) — The plane normal.
|
|
ptOnPlane:Number3D (default = null) — A point on the plane.
|
| closestPointOnPlane | () | method |
public function closestPointOnPlane(point:Number3D, ptOnPlane:Number3D):Number3DGet the closest point on the plane.
Parameterspoint:Number3D — The point to 'project'.
|
|
ptOnPlane:Number3D — ptOnPlane A known point on the plane.
|
Number3D |
| distance | () | method |
public function distance(pt:*):Numberdistance of point to plane.
Parameterspt:* |
Number |
| fromCoefficients | () | method |
public static function fromCoefficients(a:Number, b:Number, c:Number, d:Number):Plane3DCreates a plane from coefficients.
Parametersa:Number |
|
b:Number |
|
c:Number |
|
d:Number |
Plane3D —
The created plane.
|
| fromNormalAndPoint | () | method |
public static function fromNormalAndPoint(normal:*, point:*):Plane3DCreates a plane from a normal and a point.
Parametersnormal:* |
|
point:* |
Plane3D —
The created plane.
|
| fromThreePoints | () | method |
public static function fromThreePoints(p0:*, p1:*, p2:*):Plane3DCreates a plane from three points.
Parametersp0:* — First point.
|
|
p1:* — Second point.
|
|
p2:* — Third point.
|
Plane3D —
The created plane.
|
| normalize | () | method |
public function normalize():voidnormalize.
| pointOnSide | () | method |
public function pointOnSide(num:Number3D):intGets the side a vertex is on.
Parametersnum:Number3D |
int |
| projectPoints | () | method |
public function projectPoints(points:Array, origin:Number3D = null):voidProjects points onto this plane.
Passed points should be in the XY-plane. If the points have Z=0 then the points are projected exactly on the plane. When however Z is greater then zero, the points are moved 'out of the plane' by a distance Z. Negative values for Z move the points 'into the plane'.
Parameterspoints:Array — Array of points (any object with x, y, z props).
|
|
origin:Number3D (default = null) — Where to move the points.
|
| setCoefficients | () | method |
public function setCoefficients(a:Number, b:Number, c:Number, d:Number):voidSets this plane from ABCD coefficients.
Parametersa:Number |
|
b:Number |
|
c:Number |
|
d:Number |
| setNormalAndPoint | () | method |
public function setNormalAndPoint(normal:Number3D, pt:Number3D):voidSets this plane from a normal and a point.
Parametersnormal:Number3D |
|
pt:Number3D |
| setThreePoints | () | method |
public function setThreePoints(p0:Number3D, p1:Number3D, p2:Number3D):voidSets this plane from three points.
Parametersp0:Number3D |
|
p1:Number3D |
|
p2:Number3D |
| toString | () | method |
public function toString():String
Returns
String |