Module hilo/game/Camera3d
Requires
hilo/core/Class, hilo/util/util
Source
Camera3d.js
Camera3d is a pseudo-3d camera.
Property | Defined | |
---|---|---|
fv:Number
The distance of the fov(The distance between eyes and the Z plane,it determines the scale ratio of the 3d object).
|
Camera3d | |
fx:Number
The x position of the screen viewpoint(The distance between the screen viewpoint and the screen left top corner on the x axis).
|
Camera3d | |
fy:Number
The y position of the screen viewpoint(The distance between the screen viewpoint and the screen left top corner on the y axis).
|
Camera3d | |
rotationX:Number
The x rotation.
|
Camera3d | |
rotationY:Number
The y rotation.
|
Camera3d | |
rotationZ:Number
The z rotation.
|
Camera3d | |
stage:Object
The 3d object's container, it can be stage or container.It is required if you need to sort the 3d object by z axis.
|
Camera3d | |
x:Number
The x position.
|
Camera3d | |
y:Number
The y position.
|
Camera3d | |
z:Number
The z position.
|
Camera3d |
Method | Defined | |
---|---|---|
Camera3d()
Constructor
|
Camera3d | |
Project the 3d point to 2d point.
|
Camera3d | |
rotateX(angle:Number)
Rotate by the x axis.
|
Camera3d | |
rotateY(angle:Number)
Rotate by the y axis.
|
Camera3d | |
rotateZ(angle:Number)
Rotate by the z axis.
|
Camera3d | |
sortZ()
Sort by z axis.
|
Camera3d | |
tick()
Used for the ticker.
|
Camera3d | |
translate(x:Number, y:Number, z:Number)
Translate the camera,used for Zoomin/out feature.
|
Camera3d |