EINA_ARRAY_ITER_NEXT(&ob->priv.onebuf_regions, i, rect, it)
result[i] = *rect;
- _evas_shm_surface_redraw(ob->surface);
-
/* force a buffer swap */
_evas_shm_surface_swap(ob->surface, result, n);
+ _evas_shm_surface_redraw(ob->surface);
+
/* clean array */
eina_array_clean(&ob->priv.onebuf_regions);
i++;
}
- _evas_shm_surface_redraw(ob->surface);
-
/* force a buffer swap */
_evas_shm_surface_swap(ob->surface, result, n);
+
+ _evas_shm_surface_redraw(ob->surface);
}
}
goto fd_err;
}
+ /* NB: Commented out. Used for debugging rendering issues */
+ /* memset(*data, 127, size); */
+
/* create wl_shm_pool using fd */
pool = wl_shm_create_pool(shm, fd, size);
else
wl_surface_damage(surface->surface, 0, 0, leaf->w, leaf->h);
- wl_surface_commit(surface->surface);
-
- leaf->busy = 1;
surface->dx = 0;
surface->dy = 0;
surface->redraw = EINA_TRUE;
void
_evas_shm_surface_redraw(Shm_Surface *surface)
{
+ Shm_Leaf *leaf = NULL;
+
LOGFN(__FILE__, __LINE__, __FUNCTION__);
if (surface->frame_cb)
surface->frame_cb = wl_surface_frame(surface->surface);
wl_callback_add_listener(surface->frame_cb, &_shm_frame_listener, surface);
+
+ wl_surface_commit(surface->surface);
+
+ leaf = &surface->leaf[surface->curr_buff];
+ leaf->busy = 1;
}