2 ## Camera Actor API ( extends Actor API)
5 Allows the developer to use actor semantics to control a camera.
7 There are two types of camera actor, FREE_LOOK and LOOK_AT_TARGET. By default
8 the camera actor will be FREE_LOOK.
10 A FREE_LOOK camera uses actor's orientation to control where the camera is looking.
11 If no additional rotations are specified, the camera looks in the negative Z direction.
13 For LOOK_AT_TARGET the actor's orientation is ignored, instead the camera looks at TARGET_POSITION
16 // get the camera currently used
17 var defaultCamera = dali.stage.getRenderTaskList().getTask(0).getCameraActor();
19 var fov = defaultCamera.fieldOfView;
21 // increase field of view by 10%
22 defaultCamera.fieldOfView = fov * 1.1;
24 // shift the camera to the left, the rendered scene will shift to the right
25 defaultCamera.x -= 10;
28 ### Camera Actor Specific Properties
30 | Name | Type | Writable | Animatable|
31 |------------------------|------------|--------------|-----------|
32 | type | dali.CAMERA_FREE_LOOK or dali.CAMERA_LOOK_AT_TARGET | ✔ | ✘ |
33 | projectionMode | dali.CAMERA_ORTHOGRAPHIC_PROJECTION or dali.CAMERA_PERSPECTIVE_PROJECTION | ✔| ✘ |
34 | fieldOfView | FLOAT | ✔ | ✘ |
35 | aspectRatio | FLOAT | ✔ | ✘ |
36 | nearPlaneDistance | FLOAT | ✔ | ✘ |
37 | farPlaneDistance | FLOAT | ✔ | ✘ |
38 | leftPlaneDistance | FLOAT | ✔ | ✘ |
39 | rightPlaneDistance | FLOAT | ✔ | ✘ |
40 | topPlaneDistance | FLOAT | ✔ | ✘ |
41 | bottomPlaneDistance | FLOAT | ✔ | ✘ |
42 | targetPosition | VECTOR3 | ✔ | ✘ |
43 | projectionMatrix | MATRIX | ✔ | ✘ |
44 | viewMatrix | MATRIX | ✔ | ✘ |
45 | invertYAxis | BOOLEAN | ✔ | ✘ |