X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=dali%2Fintegration-api%2Fscene.h;h=dc1db99ff70b45e46d40e2824123f934095b45fd;hb=be1696c6783e8dba628338211e4931df52987abf;hp=e396295b21d11aabe4de452ca76cba250ee7468b;hpb=6bfe656ae942470e3768d2a143a536b92a24d1ea;p=platform%2Fcore%2Fuifw%2Fdali-core.git diff --git a/dali/integration-api/scene.h b/dali/integration-api/scene.h index e396295..dc1db99 100644 --- a/dali/integration-api/scene.h +++ b/dali/integration-api/scene.h @@ -2,7 +2,7 @@ #define DALI_SCENE_H /* - * Copyright (c) 2020 Samsung Electronics Co., Ltd. + * Copyright (c) 2021 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. @@ -41,6 +41,11 @@ namespace Internal DALI_INTERNAL class Scene; } +namespace Graphics +{ +class RenderTarget; +} + namespace Integration { struct Event; @@ -66,20 +71,11 @@ public: * @brief Create an initialized Scene handle. * * @param[in] size The size of the set surface for this scene + * @param[in] orientation The rotated angle of the set surface for this scene * * @return a handle to a newly allocated Dali resource. */ - static Scene New(Size size); - - /** - * @brief Create an initialized Scene handle. - * - * @param[in] size The size of the set surface for this scene - * @param[in] orientation The orientation of the set surface for this scene - * - * @return a handle to a newly allocated Dali resource. - */ - static Scene New( Size size, int orientation ); + static Scene New(Size size, int32_t orientation = 0); /** * @brief Downcast an Object handle to Scene handle. @@ -227,6 +223,13 @@ public: void Discard(); /** + * @brief Sets the render target for the surface. + * + * @param[in] renderTarget The render target for the surface + */ + void SetSurfaceRenderTarget(Graphics::RenderTarget* renderTarget); + + /** * @brief Retrieve the Scene that the given actor belongs to. * @return The Scene. */ @@ -251,7 +254,7 @@ public: * * @note A callback of the following type may be used: * @code - * void MyFunction( int frameId ); + * void MyFunction( int32_t frameId ); * @endcode * This callback will be deleted once it is called. * @@ -267,7 +270,7 @@ public: * * @note A callback of the following type may be used: * @code - * void MyFunction( int frameId ); + * void MyFunction( int32_t frameId ); * @endcode * This callback will be deleted once it is called. * @@ -294,6 +297,35 @@ public: void GetFramePresentedCallback(FrameCallbackContainer& callbacks); /** + * @brief Informs the scene that the set surface has been rotated. + * + * @param[in] width The width of rotated surface + * @param[in] height The height of rotated surface + * @param[in] orientation The orientation of rotated surface + */ + void SurfaceRotated(float width, float height, int32_t orientation); + + /** + * @brief Gets the current surface orientation. It gets the value from the scene object. + * + * @return The current surface orientation. + */ + int32_t GetCurrentSurfaceOrientation() const; + + /** + * @brief Gets the current surface rectangle. It gets the value from the scene object. + * + * @return The current surface rectangle + */ + const Rect& GetCurrentSurfaceRect() const; + + /** + * Query wheter the surface rect is changed or not. + * @return true if the surface rect is changed. + */ + bool IsSurfaceRectChanged() const; + + /** * @brief This signal is emitted just after the event processing is finished. * * @return The signal to connect to