| Package | net.bgstaal.perspectiveprojection |
| Class | public class Point3d |
| Property | Defined by | ||
|---|---|---|---|
| x : Number
The x coordinate
| Point3d | ||
| y : Number
The y coordinate
| Point3d | ||
| z : Number
The z coordinate
| Point3d | ||
| Method | Defined by | ||
|---|---|---|---|
|
Point3d(x:Number = 0, y:Number = 0, z:Number = 0)
Creates a Point3d instance
| Point3d | ||
|
Applies the supplied transformation matrix to the point around the supplied pivot point
| Point3d | ||
|
Performs a perspective projection on the instance and returns a 2d represenation of the 3d coordinates
| Point3d | ||
| x | property |
public var x:NumberThe x coordinate
| y | property |
public var y:NumberThe y coordinate
| z | property |
public var z:NumberThe z coordinate
| Point3d | () | constructor |
public function Point3d(x:Number = 0, y:Number = 0, z:Number = 0)Creates a Point3d instance
Parametersx:Number (default = 0) — The x coordinate
|
|
y:Number (default = 0) — The y coordinate
|
|
z:Number (default = 0) — The z coordinate
|
| applyMatrix | () | method |
public function applyMatrix(m:Matrix3d, pivotPoint:Point3d = null):voidApplies the supplied transformation matrix to the point around the supplied pivot point
Parametersm:Matrix3d — m Matrix3d instance with the transformation values
|
|
pivotPoint:Point3d (default = null) — pivotPoint A Point in 3d witch the transformation should be applied around. The coordinates (0,0,0) is used if no value is supplied.
|
| project | () | method |
public function project(focalLength:Number, projectionCenter:Point = null):Point2dPerforms a perspective projection on the instance and returns a 2d represenation of the 3d coordinates
ParametersfocalLength:Number — focalLength Distance from camera to the stage
|
|
projectionCenter:Point (default = null) — projectionCenter 2d coordinate representing the center of the viewing frustrum (vanishing point)
|
Point2d —
A Point2d instance representing a projected version of this |