gl_drm: stop trying to figure out buffer age if gl extension isn't present
authorDerek Foreman <derekf@osg.samsung.com>
Fri, 22 Jan 2016 20:48:34 +0000 (14:48 -0600)
committerMike Blumenkrantz <zmike@osg.samsung.com>
Thu, 18 Feb 2016 20:50:15 +0000 (15:50 -0500)
If we don't have the right extension for age we probably don't have
partial updates either.  The code to get the age calculations right is
actually much nastier than this anyway since gbm can hand back buffers
in arbitrary order, and as many as it feels like.

src/modules/evas/engines/gl_drm/evas_outbuf.c

index 6561441..65a47f5 100644 (file)
@@ -600,25 +600,7 @@ evas_outbuf_buffer_state_get(Outbuf *ob)
      }
    else
      {
-        int delta;
-
-        delta = (ob->priv.last - ob->priv.curr +
-                 (ob->priv.last > ob->priv.last ?
-                     0 : ob->priv.num)) % ob->priv.num;
-
-        switch (delta)
-          {
-           case 0:
-             return MODE_COPY;
-           case 1:
-             return MODE_DOUBLE;
-           case 2:
-             return MODE_TRIPLE;
-           case 3:
-             return MODE_QUADRUPLE;
-           default:
-             return MODE_FULL;
-          }
+        return MODE_FULL;
      }
 
    return ob->swap_mode;