summaryrefslogtreecommitdiff
path: root/gdk/gdkinternals.h
diff options
context:
space:
mode:
authorAlexander Larsson <alexl@redhat.com>2014-10-09 10:09:51 +0200
committerMatthias Clasen <mclasen@redhat.com>2014-10-13 10:43:31 -0400
commita8f11835c5c59755c0477b289019a4cfab761628 (patch)
tree4932f49d9a79e7a3daeb0cc416fc247b64f81983 /gdk/gdkinternals.h
parentceeed1c48db28bdf04e5d36dbb0fc24e3c702dd5 (diff)
downloadgtk+-a8f11835c5c59755c0477b289019a4cfab761628.tar.gz
Change the way the update area is tracked during paint
First of all we track the current update area during an update in window->active_update_area. This will be used later in end_paint to know the damaged area. Secondly we keep track of old update areas for the last 2 frames. This will later allow us to reuse old framebuffer contents in double or tripple buffer setups, only painting what has changed since then.
Diffstat (limited to 'gdk/gdkinternals.h')
-rw-r--r--gdk/gdkinternals.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/gdk/gdkinternals.h b/gdk/gdkinternals.h
index 07df2f15de..d70b6c4742 100644
--- a/gdk/gdkinternals.h
+++ b/gdk/gdkinternals.h
@@ -213,6 +213,12 @@ struct _GdkWindow
cairo_region_t *update_area;
guint update_freeze_count;
+ /* This is the update_area that was in effect when the current expose
+ started. It may be smaller than the expose area if we'e painting
+ more than we have to, but it represents the "true" damage. */
+ cairo_region_t *active_update_area;
+ /* We store the old expose areas to support buffer-age optimizations */
+ cairo_region_t *old_updated_area[2];
GdkWindowState state;