fix some core swapper logic isue with rect updates... nasty nasty

nasty to catch! :(



SVN revision: 82859
This commit is contained in:
Carsten Haitzler 2013-01-16 06:41:02 +00:00
parent b86a5cd30f
commit 73b2f09b74
2 changed files with 5 additions and 4 deletions

View File

@ -275,7 +275,7 @@ evas_software_xlib_swapbuf_new_region_for_update(Outbuf *buf, int x, int y, int
im = (RGBA_Image *)evas_cache_image_empty(evas_common_image_cache_get()); im = (RGBA_Image *)evas_cache_image_empty(evas_common_image_cache_get());
if (!im) if (!im)
{ {
free(rect); eina_rectangle_free(rect);
return NULL; return NULL;
} }
im->cache_entry.flags.alpha |= buf->priv.destination_alpha ? 1 : 0; im->cache_entry.flags.alpha |= buf->priv.destination_alpha ? 1 : 0;
@ -351,7 +351,6 @@ evas_software_xlib_swapbuf_flush(Outbuf *buf)
int x, y, w, h; int x, y, w, h;
x = rect->x; y = rect->y; w = rect->w; h = rect->h; x = rect->x; y = rect->y; w = rect->w; h = rect->h;
rects[i] = *rect;
if (buf->rot == 0) if (buf->rot == 0)
{ {
rects[i].x = x; rects[i].x = x;
@ -382,13 +381,14 @@ evas_software_xlib_swapbuf_flush(Outbuf *buf)
rects[i].w = h; rects[i].w = h;
rects[i].h = w; rects[i].h = w;
} }
free(rect); eina_rectangle_free(rect);
#ifdef EVAS_CSERVE2 #ifdef EVAS_CSERVE2
if (evas_cserve2_use_get()) if (evas_cserve2_use_get())
evas_cache2_image_close(&im->cache_entry); evas_cache2_image_close(&im->cache_entry);
else else
#endif #endif
evas_cache_image_drop(&im->cache_entry); evas_cache_image_drop(&im->cache_entry);
i++;
} }
evas_xlib_swapper_buffer_unmap(buf->priv.swapper); evas_xlib_swapper_buffer_unmap(buf->priv.swapper);
evas_xlib_swapper_swap(buf->priv.swapper, rects, n); evas_xlib_swapper_swap(buf->priv.swapper, rects, n);

View File

@ -222,6 +222,7 @@ evas_xlib_swapper_free(X_Swapper *swp)
{ {
_buf_free(swp, &(swp->buf[i])); _buf_free(swp, &(swp->buf[i]));
} }
XFreeGC(swp->disp, swp->gc);
free(swp); free(swp);
} }