X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=dali%2Finternal%2Fwindow-system%2Fubuntu-x11%2Fpixmap-render-surface-ecore-x.h;h=b88c3f6afc3111b978a5359a334d46bbcccd53ef;hb=b6c0fd19182faf643e0f519c37959f89f37a964f;hp=91ee16142cb498823c1b220c789caeb4246d8e5f;hpb=ee1898022ba5157cb467dc822cdac1a29712cba9;p=platform%2Fcore%2Fuifw%2Fdali-adaptor.git diff --git a/dali/internal/window-system/ubuntu-x11/pixmap-render-surface-ecore-x.h b/dali/internal/window-system/ubuntu-x11/pixmap-render-surface-ecore-x.h index 91ee161..b88c3f6 100644 --- a/dali/internal/window-system/ubuntu-x11/pixmap-render-surface-ecore-x.h +++ b/dali/internal/window-system/ubuntu-x11/pixmap-render-surface-ecore-x.h @@ -1,8 +1,8 @@ -#ifndef __DALI_ECORE_X_PIXMAP_RENDER_SURFACE_H__ -#define __DALI_ECORE_X_PIXMAP_RENDER_SURFACE_H__ +#ifndef DALI_ECORE_X_PIXMAP_RENDER_SURFACE_H +#define DALI_ECORE_X_PIXMAP_RENDER_SURFACE_H /* - * Copyright (c) 2018 Samsung Electronics Co., Ltd. + * Copyright (c) 2020 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. @@ -18,17 +18,18 @@ * */ +// EXTERNAL INCLUDES +#include + // INTERNAL INCLUDES -#include -#include +#include +#include +#include +#include +#include #include #include -// EXTERNAL INCLUDES -#include -#include -#include - namespace Dali { namespace Internal @@ -47,13 +48,9 @@ public: * Uses an X11 surface to render to. * @param [in] positionSize the position and size of the surface * @param [in] surface can be a X-window or X-pixmap (type must be unsigned int). - * @param [in] name optional name of surface passed in * @param [in] isTransparent if it is true, surface has 32 bit color depth, otherwise, 24 bit */ - PixmapRenderSurfaceEcoreX( Dali::PositionSize positionSize, - Any surface, - const std::string& name, - bool isTransparent = false); + PixmapRenderSurfaceEcoreX( Dali::PositionSize positionSize, Any surface, bool isTransparent = false ); /** * @brief Destructor @@ -65,101 +62,106 @@ public: // from WindowRenderSurface /** * @copydoc Dali::Internal::Adaptor::PixmapRenderSurface::GetSurface() */ - virtual Any GetSurface() override; + Any GetSurface() override; /** * @copydoc Dali::Internal::Adaptor::PixmapRenderSurface::SetRenderNotification() */ - virtual void SetRenderNotification( TriggerEventInterface* renderNotification ) override; + void SetRenderNotification( TriggerEventInterface* renderNotification ) override; -public: // from Dali::RenderSurface +public: // from Dali::RenderSurfaceInterface /** - * @copydoc Dali::RenderSurface::GetPositionSize() + * @copydoc Dali::RenderSurfaceInterface::GetPositionSize() */ - virtual PositionSize GetPositionSize() const; + PositionSize GetPositionSize() const override; /** - * @copydoc Dali::RenderSurface::InitializeEgl() + * @copydoc Dali::RenderSurfaceInterface::GetDpi() */ - virtual void InitializeEgl( EglInterface& egl ); + void GetDpi( unsigned int& dpiHorizontal, unsigned int& dpiVertical ) override; /** - * @copydoc Dali::RenderSurface::CreateEglSurface() + * @copydoc Dali::RenderSurfaceInterface::InitializeGraphics() */ - virtual void CreateEglSurface( EglInterface& egl ); + void InitializeGraphics() override; /** - * @copydoc Dali::RenderSurface::DestroyEglSurface() + * @copydoc Dali::RenderSurfaceInterface::CreateSurface() */ - virtual void DestroyEglSurface( EglInterface& egl ); + void CreateSurface() override; /** - * @copydoc Dali::RenderSurface::ReplaceEGLSurface() + * @copydoc Dali::RenderSurfaceInterface::DestroySurface() */ - virtual bool ReplaceEGLSurface( EglInterface& egl ); + void DestroySurface() override; /** - * @copydoc Dali::RenderSurface::MoveResize() + * @copydoc Dali::RenderSurfaceInterface::ReplaceGraphicsSurface() */ - virtual void MoveResize( Dali::PositionSize positionSize) {} + bool ReplaceGraphicsSurface() override; /** - * @copydoc Dali::RenderSurface::SetViewMode() + * @copydoc Dali::RenderSurfaceInterface::MoveResize() */ - void SetViewMode( ViewMode viewMode ) {} + virtual void MoveResize( Dali::PositionSize positionSize) override {} /** - * @copydoc Dali::RenderSurface::StartRender() + * @copydoc Dali::RenderSurfaceInterface::StartRender() */ - virtual void StartRender(); + void StartRender() override; /** - * @copydoc Dali::RenderSurface::PreRender() + * @copydoc Dali::RenderSurfaceInterface::PreRender() */ - virtual bool PreRender( EglInterface& egl, Integration::GlAbstraction& glAbstraction, bool resizingSurface ); + bool PreRender( bool resizingSurface, const std::vector>& damagedRects, Rect& clippingRect ) override; /** - * @copydoc Dali::RenderSurface::PostRender() + * @copydoc Dali::RenderSurfaceInterface::PostRender() */ - virtual void PostRender( EglInterface& egl, Integration::GlAbstraction& glAbstraction, DisplayConnection* displayConnection, bool replacingSurface, bool resizingSurface ); + void PostRender( bool renderToFbo, bool replacingSurface, bool resizingSurface, const std::vector>& damagedRects ) override; /** - * @copydoc Dali::RenderSurface::StopRender() + * @copydoc Dali::RenderSurfaceInterface::StopRender() */ - virtual void StopRender(); + void StopRender() override; /** - * @copydoc Dali::RenderSurface::SetThreadSynchronization + * @copydoc Dali::RenderSurfaceInterface::SetThreadSynchronization */ - virtual void SetThreadSynchronization( ThreadSynchronizationInterface& threadSynchronization ); + void SetThreadSynchronization( ThreadSynchronizationInterface& threadSynchronization ) override; /** - * @copydoc Dali::RenderSurface::GetSurfaceType() + * @copydoc Dali::RenderSurfaceInterface::GetSurfaceType() */ - virtual RenderSurface::Type GetSurfaceType(); + Dali::RenderSurfaceInterface::Type GetSurfaceType() override; + + /** + * @copydoc Dali::RenderSurfaceInterface::MakeContextCurrent() + */ + void MakeContextCurrent() override; private: // from PixmapRenderSurface /** - * @copydoc Dali::RenderSurface::ReleaseLock() + * @copydoc Dali::RenderSurfaceInterface::ReleaseLock() */ - virtual void ReleaseLock(); + void ReleaseLock() override; /** * @copydoc Dali::Internal::Adaptor::PixmapRenderSurface::Initialize() */ - virtual void Initialize( Any surface ) override; + void Initialize( Any surface ) override; /** * @copydoc Dali::Internal::Adaptor::PixmapRenderSurface::Initialize() */ - virtual void CreateRenderable() override; + void CreateRenderable() override; /** * @copydoc Dali::Internal::Adaptor::PixmapRenderSurface::Initialize() */ - virtual void UseExistingRenderable( unsigned int surfaceId ) override; + void UseExistingRenderable( unsigned int surfaceId ) override; private: @@ -173,9 +175,9 @@ private: private: // Data static const int BUFFER_COUNT = 2; - + GraphicsInterface* mGraphics; ///< Graphics interface + Dali::DisplayConnection* mDisplayConnection; ///< Display connection PositionSize mPosition; ///< Position - std::string mTitle; ///< Title of window which shows from "xinfo -topvwins" command TriggerEventInterface* mRenderNotification; ///< Render notification trigger ColorDepth mColorDepth; ///< Color depth of surface (32 bit or 24 bit) bool mOwnSurface; ///< Whether we own the surface (responsible for deleting it) @@ -194,4 +196,4 @@ private: // Data } // namespace Dali -#endif // __DALI_ECORE_X_PIXMAP_RENDER_SURFACE_H__ +#endif // DALI_ECORE_X_PIXMAP_RENDER_SURFACE_H