From: jiin.moon Date: Tue, 22 Nov 2016 06:36:48 +0000 (+0900) Subject: evas: Redraw dirty images without updates X-Git-Tag: accepted/tizen/common/20170102.152350~174 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=bc126e0b9e2e15111d8076242155a9e877cf9d0f;p=platform%2Fupstream%2Fefl.git evas: Redraw dirty images without updates Refs: v1.18.0-rc-1592-g55e8842 Author: Jean-Philippe Andre AuthorDate: Mon Nov 21 16:58:29 2016 +0900 Commit: Jean-Philippe Andre CommitDate: Tue Nov 22 14:32:37 2016 +0900 evas: Redraw dirty images without updates The proper way to use the pixel_get callback and dirty flag is to also specify which exact region has been updated with data_update_add. Unfortunately many apps and even GLView are relying on invalid behaviour that forced full redraw of the image even though data_update_add was never called. This amends c1a080f5e4e3ef01cfb792ef3eb9c9e59ba4d3f3 There is no dirty flag equivalent in EO as there is no pixel_get callback defined (yet). One problem is that the GL API is not defined, and may prove hard to define for bindings... Change-Id: I1447c87bb33e7a0fdef2e865d3c7c61f3f1304b8 --- diff --git a/src/lib/evas/canvas/evas_object_image.c b/src/lib/evas/canvas/evas_object_image.c index a81b744..dba5199 100644 --- a/src/lib/evas/canvas/evas_object_image.c +++ b/src/lib/evas/canvas/evas_object_image.c @@ -3860,19 +3860,12 @@ evas_object_image_render_pre(Evas_Object *eo_obj, evas_object_render_pre_prev_cur_add(&e->clip_changes, eo_obj, obj); if (!o->pixels->pixel_updates) goto done; } - if (o->dirty_pixels && ENFN->image_native_get) + if (o->dirty_pixels && !o->pixels->pixel_updates) { - /* Evas GL surfaces have historically required only the dirty - * pixel to trigger a redraw (call to pixels_get). Other kinds - * of surfaces must add data update regions. */ - Evas_Native_Surface *ns; - ns = ENFN->image_native_get(ENDT, o->engine_data); - if (ns && ((ns->type == EVAS_NATIVE_SURFACE_EVASGL) || - (ns->type == EVAS_NATIVE_SURFACE_TBM))) - { - evas_object_render_pre_prev_cur_add(&e->clip_changes, eo_obj, obj); - if (!o->pixels->pixel_updates) goto done; - } + /* Legacy compatibility (invalid behaviour): dirty_set() used to + * trigger full image redraw, even though this was not correct. */ + evas_object_render_pre_prev_cur_add(&e->clip_changes, eo_obj, obj); + goto done; } if (o->cur->frame != o->prev->frame) {