discomfitor pushed a commit to branch master.

http://git.enlightenment.org/core/enlightenment.git/commit/?id=4d30674ab87001d6a1515908341d756d75a22a89

commit 4d30674ab87001d6a1515908341d756d75a22a89
Author: Mike Blumenkrantz <zm...@osg.samsung.com>
Date:   Fri Oct 2 13:49:57 2015 -0400

    move client post-update adding into render function
    
    in some cases, it's possible for a client which expects to render on
    the next frame to actually render on the frame after. in these cases,
    the compositor must not clear the pixmap image until after the render
    has occurred in order to avoid inaccuracies. for this reason, the best
    place to flag a client for post-render work is at the time of the client's
    render
    
    ref T2762
    ref D3120
---
 src/bin/e_comp.c        | 14 +++-----------
 src/bin/e_comp_object.c |  6 ++++++
 2 files changed, 9 insertions(+), 11 deletions(-)

diff --git a/src/bin/e_comp.c b/src/bin/e_comp.c
index 380df4e..6274235 100644
--- a/src/bin/e_comp.c
+++ b/src/bin/e_comp.c
@@ -307,14 +307,13 @@ _e_comp_cb_nocomp_begin_timeout(void *data EINA_UNUSED)
 }
 
 
-static Eina_Bool
+static void
 _e_comp_client_update(E_Client *ec)
 {
    int pw, ph;
-   Eina_Bool post = !e_pixmap_is_x(ec->pixmap);
 
    DBG("UPDATE [%p] pm = %p", ec, ec->pixmap);
-   if (e_object_is_del(E_OBJECT(ec))) return EINA_FALSE;
+   if (e_object_is_del(E_OBJECT(ec))) return;
 
    e_pixmap_size_get(ec->pixmap, &pw, &ph);
 
@@ -327,7 +326,6 @@ _e_comp_client_update(E_Client *ec)
             e_pixmap_size_changed(ec->pixmap, pw, ph))
           {
              e_pixmap_image_clear(ec->pixmap, 0);
-             post = EINA_TRUE;
              e_comp_object_render_update_del(ec->frame); //clear update
           }
         else if (!e_pixmap_size_get(ec->pixmap, NULL, NULL))
@@ -346,7 +344,6 @@ _e_comp_client_update(E_Client *ec)
         if (e_pixmap_is_x(ec->pixmap) && (!ec->override))
           evas_object_resize(ec->frame, ec->w, ec->h);
      }
-   return post;
 }
 
 static void
@@ -397,12 +394,7 @@ _e_comp_cb_update(void)
      {
         /* clear update flag */
         e_comp_object_render_update_del(ec->frame);
-        if (_e_comp_client_update(ec))
-          {
-             e_comp->post_updates = eina_list_append(e_comp->post_updates, ec);
-             REFD(ec, 111);
-             e_object_ref(E_OBJECT(ec));
-          }
+        _e_comp_client_update(ec);
      }
    _e_comp_fps_update();
    if (conf->fps_show)
diff --git a/src/bin/e_comp_object.c b/src/bin/e_comp_object.c
index 4180478..c5655f1 100644
--- a/src/bin/e_comp_object.c
+++ b/src/bin/e_comp_object.c
@@ -3682,6 +3682,12 @@ end:
 
    eina_iterator_free(it);
    E_FREE_FUNC(cw->pending_updates, eina_tiler_free);
+   if (ret)
+     {
+        e_comp->post_updates = eina_list_append(e_comp->post_updates, cw->ec);
+        REFD(cw->ec, 111);
+        e_object_ref(E_OBJECT(cw->ec));
+     }
    return ret;
 }
 

-- 


Reply via email to