Change method names of GlWindow 53/268653/2
authorDaekwang Ryu <dkdk.ryu@samsung.com>
Tue, 28 Dec 2021 05:40:48 +0000 (14:40 +0900)
committerDaekwang Ryu <dkdk.ryu@samsung.com>
Mon, 17 Jan 2022 05:10:42 +0000 (05:10 +0000)
It copies from GlView.

Change-Id: I7b26e752a0efd972b24e785aa2e661f5674bb132

automated-tests/src/dali-adaptor/utc-Dali-Gl-Window.cpp
dali/devel-api/adaptor-framework/gl-window.cpp
dali/devel-api/adaptor-framework/gl-window.h
dali/internal/window-system/common/gl-window-impl.cpp
dali/internal/window-system/common/gl-window-impl.h
dali/internal/window-system/common/gl-window-render-thread.cpp
dali/internal/window-system/common/gl-window-render-thread.h

index 61c70fc..746c6be 100644 (file)
@@ -110,12 +110,12 @@ int UtcDaliGlWindowNew2(void)
   END_TEST;
 }
 
-int UtcDaliGlWindowSetEglConfigGles20(void)
+int UtcDaliGlWindowSetGraphicsConfigGles20(void)
 {
   Dali::GlWindow window;
   try
   {
-    window.SetEglConfig(true, true, 0, Dali::GlWindow::GlesVersion::VERSION_2_0);
+    window.SetGraphicsConfig(true, true, 0, Dali::GlWindow::GlesVersion::VERSION_2_0);
 
     DALI_TEST_CHECK(false);
   }
@@ -126,12 +126,12 @@ int UtcDaliGlWindowSetEglConfigGles20(void)
   END_TEST;
 }
 
-int UtcDaliGlWindowSetEglConfigGles30(void)
+int UtcDaliGlWindowSetGraphicsConfigGles30(void)
 {
   Dali::GlWindow window;
   try
   {
-    window.SetEglConfig(true, true, 0, Dali::GlWindow::GlesVersion::VERSION_3_0);
+    window.SetGraphicsConfig(true, true, 0, Dali::GlWindow::GlesVersion::VERSION_3_0);
 
     DALI_TEST_CHECK(false);
   }
@@ -395,13 +395,13 @@ void glTerminate(void)
 {
 }
 
-int UtcDaliGlWindowRegisterGlCallback(void)
+int UtcDaliGlWindowRegisterGlCallbacks(void)
 {
   Dali::GlWindow window;
 
   try
   {
-    window.RegisterGlCallback(Dali::MakeCallback(glInit), Dali::MakeCallback(glRenderFrame), Dali::MakeCallback(glTerminate));
+    window.RegisterGlCallbacks(Dali::MakeCallback(glInit), Dali::MakeCallback(glRenderFrame), Dali::MakeCallback(glTerminate));
 
     DALI_TEST_CHECK(false);
   }
@@ -418,7 +418,7 @@ int UtcDaliGlWindowRenderOnce(void)
 
   try
   {
-    window.RegisterGlCallback(Dali::MakeCallback(glInit), Dali::MakeCallback(glRenderFrame), Dali::MakeCallback(glTerminate));
+    window.RegisterGlCallbacks(Dali::MakeCallback(glInit), Dali::MakeCallback(glRenderFrame), Dali::MakeCallback(glTerminate));
     window.RenderOnce();
 
     DALI_TEST_CHECK(false);
index 929e2a9..daedd6f 100644 (file)
@@ -69,9 +69,9 @@ GlWindow::GlWindow(GlWindow&& rhs) = default;
 
 GlWindow& GlWindow::operator=(GlWindow&& rhs) = default;
 
-void GlWindow::SetEglConfig(bool depth, bool stencil, int msaa, GlesVersion version)
+void GlWindow::SetGraphicsConfig(bool depth, bool stencil, int msaa, GlesVersion version)
 {
-  GetImplementation(*this).SetEglConfig(depth, stencil, msaa, version);
+  GetImplementation(*this).SetGraphicsConfig(depth, stencil, msaa, version);
 }
 
 void GlWindow::Raise()
@@ -174,9 +174,9 @@ void GlWindow::SetPreferredOrientation(WindowOrientation orientation)
   GetImplementation(*this).SetPreferredOrientation(orientation);
 }
 
-void GlWindow::RegisterGlCallback(CallbackBase* initCallback, CallbackBase* renderFrameCallback, CallbackBase* terminateCallback)
+void GlWindow::RegisterGlCallbacks(CallbackBase* initCallback, CallbackBase* renderFrameCallback, CallbackBase* terminateCallback)
 {
-  GetImplementation(*this).RegisterGlCallback(initCallback, renderFrameCallback, terminateCallback);
+  GetImplementation(*this).RegisterGlCallbacks(initCallback, renderFrameCallback, terminateCallback);
 }
 
 void GlWindow::RenderOnce()
index 72b5855..0f026fc 100644 (file)
@@ -169,7 +169,7 @@ public:
   GlWindow& operator=(GlWindow&& rhs);
 
   /**
-   * @brief Sets egl configuration for GlWindow
+   * @brief Sets graphics configuration for GlWindow
    *
    * @param[in] depth the flag of depth buffer. If true is set, 24bit depth buffer is enabled.
    * @param[in] stencil the flag of stencil. it true is set, 8bit stencil buffer is enabled.
@@ -177,7 +177,7 @@ public:
    * @param[in] version the GLES version
    *
    */
-  void SetEglConfig(bool depth, bool stencil, int msaa, GlesVersion version);
+  void SetGraphicsConfig(bool depth, bool stencil, int msaa, GlesVersion version);
 
   /**
    * @brief Raises GlWindow to the top of GlWindow stack.
@@ -365,7 +365,7 @@ public:
    * @endcode
    * This callback is called when GlWindow is deleted.
    */
-  void RegisterGlCallback(CallbackBase* initCallback, CallbackBase* renderFrameCallback, CallbackBase* terminateCallback);
+  void RegisterGlCallbacks(CallbackBase* initCallback, CallbackBase* renderFrameCallback, CallbackBase* terminateCallback);
 
   /**
    * @brief Renders once more even if GL render functions are not added to idler.
index 4edb1a0..536cd56 100644 (file)
@@ -191,7 +191,7 @@ void GlWindow::SetClass(const std::string& name, const std::string className)
   mWindowBase->SetClass(name, className);
 }
 
-void GlWindow::SetEglConfig(bool depth, bool stencil, int msaa, Dali::GlWindow::GlesVersion version)
+void GlWindow::SetGraphicsConfig(bool depth, bool stencil, int msaa, Dali::GlWindow::GlesVersion version)
 {
   // Init Graphics
   mDepth   = depth;
@@ -211,7 +211,7 @@ void GlWindow::SetEglConfig(bool depth, bool stencil, int msaa, Dali::GlWindow::
     rVersion = 30;
   }
 
-  mGlWindowRenderThread->SetEglConfig(depth, stencil, msaa, rVersion);
+  mGlWindowRenderThread->SetGraphicsConfig(depth, stencil, msaa, rVersion);
 }
 
 void GlWindow::Raise()
@@ -746,13 +746,13 @@ void GlWindow::SetChild(Dali::Window& child)
   }
 }
 
-void GlWindow::RegisterGlCallback(CallbackBase* initCallback, CallbackBase* renderFrameCallback, CallbackBase* terminateCallback)
+void GlWindow::RegisterGlCallbacks(CallbackBase* initCallback, CallbackBase* renderFrameCallback, CallbackBase* terminateCallback)
 {
   if(mIsEGLInitialized == false)
   {
     InitializeGraphics();
   }
-  mGlWindowRenderThread->RegisterGlCallback(initCallback, renderFrameCallback, terminateCallback);
+  mGlWindowRenderThread->RegisterGlCallbacks(initCallback, renderFrameCallback, terminateCallback);
   mGlWindowRenderThread->Start();
 }
 
index 954e297..98f8c93 100644 (file)
@@ -68,9 +68,9 @@ public:
   static GlWindow* New(const PositionSize& positionSize, const std::string& name, const std::string& className, bool isTransparent = false);
 
   /**
-   * @copydoc Dali::GlWindow::SetEglConfig()
+   * @copydoc Dali::GlWindow::SetGraphicsConfig()
    */
-  void SetEglConfig(bool depth, bool stencil, int msaa, Dali::GlWindow::GlesVersion version);
+  void SetGraphicsConfig(bool depth, bool stencil, int msaa, Dali::GlWindow::GlesVersion version);
 
   /**
    * @copydoc Dali::GlWindow::Raise()
@@ -173,9 +173,9 @@ public:
   void SetPreferredOrientation(WindowOrientation orientation);
 
   /**
-   * @copydoc Dali::GlWindow::RegisterGlCallback()
+   * @copydoc Dali::GlWindow::RegisterGlCallbacks()
    */
-  void RegisterGlCallback(CallbackBase* initCallback, CallbackBase* renderFrameCallback, CallbackBase* terminateCallback);
+  void RegisterGlCallbacks(CallbackBase* initCallback, CallbackBase* renderFrameCallback, CallbackBase* terminateCallback);
 
   /**
    * @copydoc Dali::GlWindow::RenderOnce()
index e6390cf..9ed0a54 100644 (file)
@@ -85,7 +85,7 @@ void GlWindowRenderThread::SetWindowBase(WindowBase* windowBase)
   mWindowBase = windowBase;
 }
 
-void GlWindowRenderThread::SetEglConfig(bool depth, bool stencil, int msaa, int version)
+void GlWindowRenderThread::SetGraphicsConfig(bool depth, bool stencil, int msaa, int version)
 {
   mDepth       = depth;
   mStencil     = stencil;
@@ -116,7 +116,7 @@ void GlWindowRenderThread::Stop()
   mRenderThreadWaitCondition.Notify(lock);
 }
 
-void GlWindowRenderThread::RegisterGlCallback(CallbackBase* initCallback,
+void GlWindowRenderThread::RegisterGlCallbacks(CallbackBase* initCallback,
                                               CallbackBase* renderFrameCallback,
                                               CallbackBase* terminateCallback)
 {
index 95a1366..2b4871b 100644 (file)
@@ -104,7 +104,7 @@ public:
   void SetWindowBase(WindowBase* windowBase);
 
   /**
-   * @brief Sets egl configuration for GlWindow
+   * @brief Sets graphics configuration for GlWindow
    *
    * @param[in] depth the flag of depth buffer. If true is set, 24bit depth buffer is enabled.
    * @param[in] stencil the flag of stencil. it true is set, 8bit stencil buffer is enabled.
@@ -112,7 +112,7 @@ public:
    * @param[in] version the GLES version.
    *
    */
-  void SetEglConfig(bool depth, bool stencil, int msaa, int version);
+  void SetGraphicsConfig(bool depth, bool stencil, int msaa, int version);
 
   /**
    * Pauses the Render Thread.
@@ -139,9 +139,9 @@ public:
   void Stop();
 
   /**
-   * @copydoc Dali::GlWindow::RegisterGlCallback()
+   * @copydoc Dali::GlWindow::RegisterGlCallbacks()
    */
-  void RegisterGlCallback(CallbackBase* initCallback, CallbackBase* renderFrameCallback, CallbackBase* terminateCallback);
+  void RegisterGlCallbacks(CallbackBase* initCallback, CallbackBase* renderFrameCallback, CallbackBase* terminateCallback);
 
   /**
    * Enable OnDemand Rendering Mode