Merge "(Vector) Fix deadlock issue: remove lock" into devel/master
authorHeeyong Song <heeyong.song@samsung.com>
Mon, 31 May 2021 01:37:34 +0000 (01:37 +0000)
committerGerrit Code Review <gerrit@review>
Mon, 31 May 2021 01:37:34 +0000 (01:37 +0000)
automated-tests/src/dali-toolkit/dali-toolkit-test-utils/test-graphics-controller.cpp
automated-tests/src/dali-toolkit/dali-toolkit-test-utils/test-graphics-framebuffer.h
dali-toolkit/public-api/dali-toolkit-version.cpp
packaging/dali-toolkit.spec

index cbdd5dd..0886719 100644 (file)
@@ -600,11 +600,14 @@ void TestGraphicsController::ProcessCommandBuffer(TestGraphicsCommandBuffer& com
       }
       case CommandType::BIND_UNIFORM_BUFFER:
       {
-        auto& bindings = cmd.data.bindUniformBuffers;
-        auto  buffer   = bindings.standaloneUniformsBufferBinding;
+        if(currentPipeline)
+        {
+          auto& bindings = cmd.data.bindUniformBuffers;
+          auto  buffer   = bindings.standaloneUniformsBufferBinding;
 
-        // based on reflection, issue gl calls
-        buffer.buffer->BindAsUniformBuffer(static_cast<const TestGraphicsProgram*>(currentPipeline->programState.program), bindings.standaloneUniformsBufferBinding);
+          // based on reflection, issue gl calls
+          buffer.buffer->BindAsUniformBuffer(static_cast<const TestGraphicsProgram*>(currentPipeline->programState.program), bindings.standaloneUniformsBufferBinding);
+        }
         break;
       }
       case CommandType::BIND_SAMPLERS:
@@ -619,25 +622,34 @@ void TestGraphicsController::ProcessCommandBuffer(TestGraphicsCommandBuffer& com
       }
       case CommandType::DRAW:
       {
-        mGl.DrawArrays(GetTopology(currentPipeline->inputAssemblyState.topology),
-                       0,
-                       cmd.data.draw.draw.vertexCount);
+        if(currentPipeline)
+        {
+          mGl.DrawArrays(GetTopology(currentPipeline->inputAssemblyState.topology),
+                         0,
+                         cmd.data.draw.draw.vertexCount);
+        }
         break;
       }
       case CommandType::DRAW_INDEXED:
       {
-        mGl.DrawElements(GetTopology(currentPipeline->inputAssemblyState.topology),
-                         static_cast<GLsizei>(cmd.data.draw.drawIndexed.indexCount),
-                         GL_UNSIGNED_SHORT,
-                         reinterpret_cast<void*>(cmd.data.draw.drawIndexed.firstIndex));
+        if(currentPipeline)
+        {
+          mGl.DrawElements(GetTopology(currentPipeline->inputAssemblyState.topology),
+                           static_cast<GLsizei>(cmd.data.draw.drawIndexed.indexCount),
+                           GL_UNSIGNED_SHORT,
+                           reinterpret_cast<void*>(cmd.data.draw.drawIndexed.firstIndex));
+        }
         break;
       }
       case CommandType::DRAW_INDEXED_INDIRECT:
       {
-        mGl.DrawElements(GetTopology(currentPipeline->inputAssemblyState.topology),
-                         static_cast<GLsizei>(cmd.data.draw.drawIndexed.indexCount),
-                         GL_UNSIGNED_SHORT,
-                         reinterpret_cast<void*>(cmd.data.draw.drawIndexed.firstIndex));
+        if(currentPipeline)
+        {
+          mGl.DrawElements(GetTopology(currentPipeline->inputAssemblyState.topology),
+                           static_cast<GLsizei>(cmd.data.draw.drawIndexed.indexCount),
+                           GL_UNSIGNED_SHORT,
+                           reinterpret_cast<void*>(cmd.data.draw.drawIndexed.firstIndex));
+        }
         break;
       }
       case CommandType::SET_SCISSOR:
@@ -838,6 +850,7 @@ void TestGraphicsController::ProcessCommandBuffer(TestGraphicsCommandBuffer& com
               const auto& area = cmd.data.beginRenderPass.renderArea;
               if(area.x == 0 &&
                  area.y == 0 &&
+                 renderTarget &&
                  area.width == renderTarget->mCreateInfo.extent.width &&
                  area.height == renderTarget->mCreateInfo.extent.height)
               {
index 664c28b..97efe39 100644 (file)
@@ -40,8 +40,8 @@ public:
   TraceCallStack&                 mCallStack;
 
   GLuint mId{0};
-  GLuint mDepthBuffer;
-  GLuint mStencilBuffer;
+  GLuint mDepthBuffer{0};
+  GLuint mStencilBuffer{0};
 };
 
 } // namespace Dali
index 6d52641..f31d0a0 100644 (file)
@@ -29,7 +29,7 @@ namespace Toolkit
 {
 const unsigned int TOOLKIT_MAJOR_VERSION = 2;
 const unsigned int TOOLKIT_MINOR_VERSION = 0;
-const unsigned int TOOLKIT_MICRO_VERSION = 27;
+const unsigned int TOOLKIT_MICRO_VERSION = 28;
 const char* const  TOOLKIT_BUILD_DATE    = __DATE__ " " __TIME__;
 
 #ifdef DEBUG_ENABLED
index 391ddf9..70ea699 100644 (file)
@@ -1,6 +1,6 @@
 Name:       dali2-toolkit
 Summary:    Dali 3D engine Toolkit
-Version:    2.0.27
+Version:    2.0.28
 Release:    1
 Group:      System/Libraries
 License:    Apache-2.0 and BSD-3-Clause and MIT