X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=dali%2Finternal%2Fevent%2Frender-tasks%2Frender-task-impl.h;h=90d5cc357291ca651aa580ca63caeafd337f4cec;hb=462cbee2270984cdca45488f3733d664dcf49187;hp=c1d8537a0d1d0d58b794c7c140fe0fcd2bb2868f;hpb=c2e24cf1461faf73ded8df8afccc8b4799ccef65;p=platform%2Fcore%2Fuifw%2Fdali-core.git diff --git a/dali/internal/event/render-tasks/render-task-impl.h b/dali/internal/event/render-tasks/render-task-impl.h index c1d8537..90d5cc3 100644 --- a/dali/internal/event/render-tasks/render-task-impl.h +++ b/dali/internal/event/render-tasks/render-task-impl.h @@ -2,7 +2,7 @@ #define __DALI_INTERNAL_RENDER_TASK_H__ /* - * Copyright (c) 2014 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 #include -#include +#include #include +#include namespace Dali { @@ -37,6 +38,7 @@ class EventThreadServices; namespace SceneGraph { class RenderTask; +class Camera; } class RenderTask : public Object @@ -94,12 +96,22 @@ public: /** * @copydoc Dali::RenderTask::SetTargetFrameBuffer() */ - void SetTargetFrameBuffer( Dali::FrameBufferImage frameBuffer ); + void SetTargetFrameBuffer( FrameBufferImagePtr frameBuffer ); /** * @copydoc Dali::RenderTask::GetTargetFrameBuffer */ - Dali::FrameBufferImage GetTargetFrameBuffer() const; + FrameBufferImage* GetTargetFrameBuffer() const; + + /** + * @copydoc Dali::RenderTask::SetFrameBuffer() + */ + void SetFrameBuffer( FrameBufferPtr frameBuffer ); + + /** + * @copydoc Dali::RenderTask::GetFrameBuffer + */ + FrameBuffer* GetFrameBuffer() const; /** * @copydoc Dali::RenderTask::SetScreenToFrameBufferFunction @@ -162,6 +174,18 @@ public: const Vector4& GetClearColor() const; /** + * Indicate whether GL sync is required for native render target. + * @param[in] requiresSync whether GL sync is required. + */ + void SetSyncRequired( bool requiresSync ); + + /** + * Query whether the sync object is required for native render target. + * @return True if the sync object is required, false otherwise. + */ + bool IsSyncRequired() const; + + /** * @copydoc Dali::RenderTask::SetClearEnabled() */ void SetClearEnabled( bool enabled ); @@ -294,6 +318,16 @@ public: // Implementation of Object virtual Property::Value GetDefaultProperty( Property::Index index ) const; /** + * @copydoc Dali::Internal::Object::GetDefaultPropertyCurrentValue() + */ + virtual Property::Value GetDefaultPropertyCurrentValue( Property::Index index ) const; + + /** + * @copydoc Dali::Internal::Object::OnNotifyDefaultPropertyAnimation() + */ + virtual void OnNotifyDefaultPropertyAnimation( Animation& animation, Property::Index index, const Property::Value& value ); + + /** * @copydoc Dali::Internal::Object::GetSceneObject() */ virtual const SceneGraph::PropertyOwner* GetSceneObject() const; @@ -420,6 +454,7 @@ protected: RenderTask& mRenderTask; Actor* mActor; ///< Raw-pointer to the actor; not owned. + const SceneGraph::Camera* mCamera; ///< Raw-pointer to camera scene-graph object; not owned. }; private: @@ -428,15 +463,20 @@ private: Connector mSourceConnector; ///< Responsible for connecting/disconnecting source Nodes Connector mCameraConnector; ///< Responsible for connecting/disconnecting camera Nodes - Connector mMappingConnector; /// Responsible for connecting/disconnection actor node, which used to mapping screen to frame buffer coordinate + Connector mMappingConnector; /// Responsible for connecting/disconnecting actor node, which used to mapping screen to frame buffer coordinate Vector4 mClearColor; ///< Optional clear color + Vector2 mViewportPosition; ///< The cached viewport position + Vector2 mViewportSize; ///< The cached viewport size + unsigned int mRefreshRate; ///< Determines how often the task is processed. unsigned int mRefreshOnceCounter; - Dali::FrameBufferImage mFrameBufferImage; ///< Optional off-screen render target. + FrameBufferImagePtr mFrameBufferImage; ///< Optional off-screen render target. + FrameBufferPtr mFrameBuffer; + Dali::RenderTask::ScreenToFrameBufferFunction mScreenToFrameBufferFunction; ///< Used to convert screen to frame-buffer coordinates @@ -445,6 +485,7 @@ private: bool mClearEnabled : 1; ///< True if the render-task should be clear the color buffer. bool mCullMode : 1; ///< True if the render-task's actors should be culled bool mIsSystemLevel : 1; ///< True if the render-task is on the system level task list. + bool mRequiresSync : 1; ///< True if the GL sync is required to track the render of. //Signals Dali::RenderTask::RenderTaskSignalType mSignalFinished; ///< Signal emmited when the render task has been processed.