Revert "[Tizen] Add screen and client rotation itself function"
[platform/core/uifw/dali-core.git] / dali / internal / render / common / render-instruction.h
index a98fd53..3157f85 100644 (file)
@@ -1,8 +1,8 @@
-#ifndef __DALI_INTERNAL_SCENE_GRAPH_RENDER_INSTRUCTION_H__
-#define __DALI_INTERNAL_SCENE_GRAPH_RENDER_INSTRUCTION_H__
+#ifndef DALI_INTERNAL_SCENE_GRAPH_RENDER_INSTRUCTION_H
+#define DALI_INTERNAL_SCENE_GRAPH_RENDER_INSTRUCTION_H
 
 /*
- * Copyright (c) 2015 Samsung Electronics Co., Ltd.
+ * Copyright (c) 2017 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -21,8 +21,9 @@
 // INTERNAL INCLUDES
 #include <dali/public-api/math/matrix.h>
 #include <dali/public-api/math/viewport.h>
-#include <dali/internal/update/node-attachments/scene-graph-camera-attachment.h>
+#include <dali/internal/update/render-tasks/scene-graph-camera.h>
 #include <dali/internal/render/common/render-list.h>
+#include <dali/internal/render/renderers/render-frame-buffer.h>
 
 namespace Dali
 {
@@ -37,7 +38,6 @@ class RenderTracker;
 
 namespace SceneGraph
 {
-class CameraAttachment;
 
 /**
  * A set of rendering instructions consisting of:
@@ -92,13 +92,13 @@ public:
    * render-lists are cleared but not released, while matrices and other settings reset in
    * preparation for building a set of instructions for the renderer.
    *
-   * @param[in] cameraAttachment to use to get view and projection matrices.
+   * @param[in] camera to use to get view and projection matrices.
    * @param[in] offscreenId A resource Id of an off-screen render target, or 0
    * @param[in] viewport A pointer to a viewport, of NULL.
    * @param[in] clearColor A pointer to a color to clear with, or NULL if no clear is required.
    */
-  void Reset( CameraAttachment* cameraAttachment,
-              unsigned int offscreenId,
+  void Reset( Camera* camera,
+              Render::FrameBuffer* frameBuffer,
               const Viewport* viewport,
               const Vector4* clearColor );
 
@@ -110,7 +110,7 @@ public:
   const Matrix* GetViewMatrix( BufferIndex index ) const
   {
     // inlined as this is called once per frame per render instruction
-    return &mCameraAttachment->GetViewMatrix( index );
+    return &mCamera->GetViewMatrix( index );
   }
 
   /**
@@ -121,7 +121,7 @@ public:
   const Matrix* GetProjectionMatrix( BufferIndex index ) const
   {
     // inlined as this is called once per frame per render instruction
-    return &mCameraAttachment->GetProjectionMatrix( index );
+    return &mCamera->GetProjectionMatrix( index );
   }
 
 private:
@@ -139,12 +139,13 @@ public: // Data
   Vector4  mClearColor;                 ///< Optional color to clear with
   bool     mIsViewportSet:1;            ///< Flag to determine whether the viewport is set
   bool     mIsClearColorSet:1;          ///< Flag to determine whether the clearColor is set
+  bool     mIgnoreRenderToFbo:1;        ///< Whether to ignore the render to FBO option (used to measure the performance above 60 fps)
 
-  unsigned int mOffscreenTextureId;     ///< Optional offscreen target
+  Render::FrameBuffer* mFrameBuffer;
 
 private: // Data
 
-  CameraAttachment* mCameraAttachment;  ///< camera that is used
+  Camera* mCamera;  ///< camera that is used
   RenderListContainer mRenderLists;     ///< container of all render lists
   RenderListContainer::SizeType mNextFreeRenderList;     ///< index for the next free render list
 
@@ -156,4 +157,4 @@ private: // Data
 
 } // namespace Dali
 
-#endif // __DALI_INTERNAL_SCENE_GRAPH_RENDER_INSTRUCTION_H__
+#endif // DALI_INTERNAL_SCENE_GRAPH_RENDER_INSTRUCTION_H