[mutter/gnome-3-36] clutter/stage-cogl: Avoid copying fb_clip_region
- From: Robert Mader <rmader src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [mutter/gnome-3-36] clutter/stage-cogl: Avoid copying fb_clip_region
- Date: Thu, 19 Nov 2020 20:27:12 +0000 (UTC)
commit 9919c8c3e6d33d3fb94ebecf15cdf7a6a4935caf
Author: Daniel van Vugt <daniel van vugt canonical com>
Date: Wed Nov 18 19:08:38 2020 +0800
clutter/stage-cogl: Avoid copying fb_clip_region
Because it gets destroyed (unreferenced) immediately after that.
This avoids a deep copy of potentially kilobytes of data.
Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/1572>
(cherry picked from commit 32b68478ede34caee447c9803addedc12a4df6c7)
clutter/clutter/cogl/clutter-stage-cogl.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
---
diff --git a/clutter/clutter/cogl/clutter-stage-cogl.c b/clutter/clutter/cogl/clutter-stage-cogl.c
index 9031f52915..0d99ba4bc5 100644
--- a/clutter/clutter/cogl/clutter-stage-cogl.c
+++ b/clutter/clutter/cogl/clutter-stage-cogl.c
@@ -935,7 +935,7 @@ clutter_stage_cogl_redraw_view (ClutterStageWindow *stage_window,
}
else
{
- swap_region = cairo_region_copy (fb_clip_region);
+ swap_region = cairo_region_reference (fb_clip_region);
do_swap_buffer = TRUE;
}
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]