derekf pushed a commit to branch master.

http://git.enlightenment.org/core/efl.git/commit/?id=d1a4f38a961898c56cdc6c9469724cefed1a75cf

commit d1a4f38a961898c56cdc6c9469724cefed1a75cf
Author: Derek Foreman <der...@osg.samsung.com>
Date:   Wed Nov 29 15:31:17 2017 -0600

    wayland_shm: Store width and height in surface struct
    
    No longer query these from the outbuf.
---
 src/modules/evas/engines/wayland_shm/evas_dmabuf.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/src/modules/evas/engines/wayland_shm/evas_dmabuf.c 
b/src/modules/evas/engines/wayland_shm/evas_dmabuf.c
index 46cea14689..521c2c6c89 100644
--- a/src/modules/evas/engines/wayland_shm/evas_dmabuf.c
+++ b/src/modules/evas/engines/wayland_shm/evas_dmabuf.c
@@ -15,6 +15,7 @@ struct _Dmabuf_Surface
    Ecore_Wl2_Buffer *current;
    Eina_List *buffers;
 
+   int w, h;
    Eina_Bool alpha : 1;
 };
 
@@ -40,6 +41,8 @@ _evas_dmabuf_surface_reconfigure(Surface *s, int w, int h, 
uint32_t flags EINA_U
         ecore_wl2_buffer_destroy(b);
         surface->buffers = eina_list_remove_list(surface->buffers, l);
      }
+   surface->w = w;
+   surface->h = h;
 }
 
 static void *
@@ -90,7 +93,7 @@ _evas_dmabuf_surface_wait(Dmabuf_Surface *s)
      {
         Outbuf *ob;
         ob = s->surface->ob;
-        best = ecore_wl2_buffer_create(ob->ewd, ob->w, ob->h, s->alpha);
+        best = ecore_wl2_buffer_create(ob->ewd, s->w, s->h, s->alpha);
         /* Start at -1 so it's age is incremented to 0 for first draw */
         best->age = -1;
         s->buffers = eina_list_append(s->buffers, best);
@@ -189,6 +192,8 @@ _evas_surface_create(Evas_Engine_Info_Wayland *info, Outbuf 
*ob)
 
    surf->surface = out;
    surf->alpha = info->info.destination_alpha;
+   surf->w = 0;
+   surf->h = 0;
 
    /* create surface buffers */
    if (!ecore_wl2_buffer_init(ewd, types)) goto err;

-- 


Reply via email to