[gtk/wip/chergert/glproto: 398/493] check our batch before the previous




commit 58c270a5f749b7f869f29cc41275f8a1798d6b76
Author: Christian Hergert <chergert redhat com>
Date:   Thu Feb 4 14:53:39 2021 -0800

    check our batch before the previous

 gsk/next/gskglcommandqueue.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/gsk/next/gskglcommandqueue.c b/gsk/next/gskglcommandqueue.c
index d28e08b475..a832b080b9 100644
--- a/gsk/next/gskglcommandqueue.c
+++ b/gsk/next/gskglcommandqueue.c
@@ -472,14 +472,14 @@ gsk_gl_command_queue_end_draw (GskGLCommandQueue *self)
 
   /* Do simple chaining of draw to last batch. */
   /* TODO: Use merging capabilities for out-or-order batching */
-  if (last_batch != NULL &&
+  if (batch->draw.uniform_count == 0 &&
+      batch->draw.bind_count == 0 &&
+      last_batch != NULL &&
       last_batch->any.kind == GSK_GL_COMMAND_KIND_DRAW &&
       last_batch->any.program == batch->any.program &&
       last_batch->any.viewport.width == batch->any.viewport.width &&
       last_batch->any.viewport.height == batch->any.viewport.height &&
       last_batch->draw.framebuffer == batch->draw.framebuffer &&
-      batch->draw.uniform_count == 0 &&
-      batch->draw.bind_count == 0 &&
       last_batch->draw.vbo_offset + last_batch->draw.vbo_count == batch->draw.vbo_offset)
     {
       last_batch->draw.vbo_count += batch->draw.vbo_count;


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]