Dali 3D User Interface Engine
camera-attachment-impl.h
Go to the documentation of this file.
1 #ifndef __DALI_INTERNAL_CAMERA_ATTACHMENT_H__
2 #define __DALI_INTERNAL_CAMERA_ATTACHMENT_H__
3 
4 /*
5  * Copyright (c) 2014 Samsung Electronics Co., Ltd.
6  *
7  * Licensed under the Apache License, Version 2.0 (the "License");
8  * you may not use this file except in compliance with the License.
9  * You may obtain a copy of the License at
10  *
11  * http://www.apache.org/licenses/LICENSE-2.0
12  *
13  * Unless required by applicable law or agreed to in writing, software
14  * distributed under the License is distributed on an "AS IS" BASIS,
15  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16  * See the License for the specific language governing permissions and
17  * limitations under the License.
18  *
19  */
20 
21 // INTERNAL INCLUDES
28 
29 namespace Dali
30 {
31 
32 class Matrix;
33 struct Vector3;
34 
35 namespace Internal
36 {
37 
38 class Camera;
39 
40 namespace SceneGraph
41 {
42 class CameraAttachment;
43 class Node;
44 }
45 
50 {
51 public:
58  static CameraAttachmentPtr New( EventThreadServices& eventThreadServices, const SceneGraph::Node& parentNode );
59 
63  void SetType(Dali::Camera::Type type);
64 
69 
76  void SetInvertYAxis( bool invertYAxis );
77 
82  bool GetInvertYAxis() const;
83 
88 
93 
97  void SetFieldOfView(float fieldOfView);
98 
102  float GetFieldOfView() const;
103 
107  void SetAspectRatio(float aspectRatio);
108 
112  float GetAspectRatio() const;
113 
118  void SetStereoBias(const Vector2& stereoBias);
119 
124  Vector2 GetStereoBias() const;
125 
129  void SetLeftClippingPlane(float leftClippingPlane);
130 
134  float GetLeftClippingPlane() const;
135 
139  void SetRightClippingPlane(float rightClippingPlane);
140 
144  float GetRightClippingPlane() const;
145 
149  void SetTopClippingPlane(float topClippingPlane);
150 
154  float GetTopClippingPlane() const;
155 
159  void SetBottomClippingPlane(float bottomClippingPlane);
160 
164  float GetBottomClippingPlane() const;
165 
169  void SetNearClippingPlane(float nearClippingPlane);
170 
174  float GetNearClippingPlane() const;
175 
179  void SetFarClippingPlane(float farClippingPlane);
180 
184  float GetFarClippingPlane() const;
185 
191  void SetTargetPosition(Vector3 target);
192 
198 
204  const Matrix& GetViewMatrix() const;
205 
211  const Matrix& GetProjectionMatrix() const;
212 
218  const Matrix& GetInverseViewProjectionMatrix() const;
219 
226 
233 
238 
243 
244 
245 private:
246 
251  CameraAttachment( EventThreadServices& eventThreadServices );
252 
258 
262  virtual void OnStageConnection();
263 
267  virtual void OnStageDisconnection();
268 
269 protected:
270 
274  virtual ~CameraAttachment();
275 
276 private:
277 
279 
293 };
294 
295 } // namespace Internal
296 
297 } // namespace Dali
298 
299 #endif // __DALI_INTERNAL_CAMERA_ATTACHMENT_H__
Dali Docs Home
Read more about Dali