namespace Internal
{
-//@todo Break this dependence somehow.
-namespace Render
-{
-class Renderer;
-}
-
namespace SceneGraph
{
class Scene;
-
-struct DirtyRect
-{
- DirtyRect(Node* node, Render::Renderer* renderer, int frame, Rect<int>& rect)
- : node(node),
- renderer(renderer),
- frame(frame),
- rect(rect),
- visited(true)
- {
- }
-
- DirtyRect()
- : node(nullptr),
- renderer(nullptr),
- frame(0),
- rect(),
- visited(true)
- {
- }
-
- bool operator<(const DirtyRect& rhs) const
- {
- if(node == rhs.node)
- {
- if(renderer == rhs.renderer)
- {
- return frame > rhs.frame; // Most recent rects come first
- }
- else
- {
- return renderer < rhs.renderer;
- }
- }
- else
- {
- return node < rhs.node;
- }
- }
-
- Node* node;
- Render::Renderer* renderer;
- int frame;
-
- Rect<int> rect;
- bool visited;
-};
-
} // namespace SceneGraph
class EventProcessor;
/**
* @copydoc Dali::Integration::Scene::New
*/
- static ScenePtr New(Size size, int orientation = 0);
+ static ScenePtr New(Size size, int32_t orientation = 0);
/**
* virtual destructor
* @param[in] height The height of rotated surface
* @param[in] orientation The orientation of rotated surface
*/
- void SurfaceRotated(float width, float height, int orientation);
+ void SurfaceRotated(float width, float height, int32_t orientation);
/**
- * @brief Get surface's current orientation
- *
- * @return surface orientation
+ * @copydoc Dali::Integration::Scene::SetRotationCompletedAcknowledgement
+ */
+ void SetRotationCompletedAcknowledgement();
+
+ /**
+ * @copydoc Dali::Integration::Scene::IsRotationCompletedAcknowledgementSet
*/
- int GetSurfaceOrientation();
+ bool IsRotationCompletedAcknowledgementSet() const;
+
+ /**
+ * @copydoc Dali::Integration::Scene::GetCurrentSurfaceOrientation
+ */
+ int32_t GetCurrentSurfaceOrientation() const;
+
+ /**
+ * @copydoc Dali::Integration::Scene::GetCurrentSurfaceRect
+ */
+ const Rect<int32_t>& GetCurrentSurfaceRect() const;
/**
* @copydoc Dali::Integration::Scene::IsSurfaceRectChanged
bool IsSurfaceRectChanged() const;
/**
+ * @copydoc Dali::Integration::Scene::SetSurfaceRenderTarget
+ */
+ void SetSurfaceRenderTarget(const Graphics::RenderTargetCreateInfo& renderTargetCreateInfo);
+
+ /**
* Used by the EventProcessor to emit key event signals.
* @param[in] event The key event.
*/
*/
Integration::Scene::WheelEventSignalType& WheelEventSignal();
- /**
- * @brief Get ItemsDirtyRects
- *
- * @return the ItemsDirtyRects
- */
- std::vector<Dali::Internal::SceneGraph::DirtyRect>& GetItemsDirtyRects();
-
public:
/**
* From RenderTaskDefaults; retrieve the default root actor.
* From RenderTaskDefaults; retrieve the default camera actor.
* @return The default camera actor.
*/
- CameraActor& GetDefaultCameraActor() override;
+ CameraActor& GetDefaultCameraActor() const override;
private:
// Constructor
* @param[in] size The size of the set surface
* @param[in] orientation The orientation of the set surface for this scene
*/
- void Initialize(Size size, int orientation);
+ void Initialize(Size size, int32_t orientation);
// Undefined
Scene(const Scene&) = delete;
* @param[in] height The height of rotated surface
* @param[in] orientation The orientation of rotated surface
*/
- void ChangedSurface(float width, float height, int orientation);
+ void ChangedSurface(float width, float height, int32_t orientation);
private:
Internal::SceneGraph::Scene* mSceneObject;
EventProcessor mEventProcessor;
// The Surface's orientation
- int mSurfaceOrientation;
+ int32_t mSurfaceOrientation;
// The key event signal
Integration::Scene::KeyEventSignalType mKeyEventSignal;
// The wheel event signal
Integration::Scene::WheelEventSignalType mWheelEventSignal;
-
- std::vector<Dali::Internal::SceneGraph::DirtyRect> mItemsDirtyRects;
};
} // namespace Internal