We had a "clever" optimization that would keep a buffer on resize
if it was resizing up horizontal and fit within the previously
allocated stride.
Unfortunately, there still needs to be a buffer reconfigure between
client and compositor that wasn't taking place. Remove this for now.
buffer->age++;
}
+/* The only user of this function has been removed, but it
+ * will likely come back later. The problem is that
+ * a dmabuf buffer needs to be resized on the compositor
+ * even if the allocation still fits. Doing the resize
+ * properly isn't something that will be fixed in the 1.21
+ * timeframe, so the optimization has been (temporarily)
+ * removed.
+ *
+ * This is currently beta api - don't move it out of beta
+ * with no users...
+ */
EAPI Eina_Bool
ecore_wl2_buffer_fit(Ecore_Wl2_Buffer *b, int w, int h)
{
if ((!w) || (!h)) return;
EINA_LIST_FOREACH_SAFE(p->buffers, l, tmp, b)
{
+/* This would be nice, but requires a partial create to follow,
+ and that partial create is buffer type specific.
+
if (ecore_wl2_buffer_fit(b, w, h))
continue;
-
+*/
ecore_wl2_buffer_destroy(b);
p->buffers = eina_list_remove_list(p->buffers, l);
}