[gtk/wip/chergert/glproto: 466/526] wait to get render region until after starting frame
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk/wip/chergert/glproto: 466/526] wait to get render region until after starting frame
- Date: Tue, 16 Feb 2021 01:14:38 +0000 (UTC)
commit 8499c00947fdee1f4912d70cc0eb16af97b2096f
Author: Christian Hergert <chergert redhat com>
Date: Sun Feb 7 18:50:36 2021 -0800
wait to get render region until after starting frame
gsk/next/gskglrenderer.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
---
diff --git a/gsk/next/gskglrenderer.c b/gsk/next/gskglrenderer.c
index 804accc83b..ee1dd75af2 100644
--- a/gsk/next/gskglrenderer.c
+++ b/gsk/next/gskglrenderer.c
@@ -199,7 +199,6 @@ gsk_next_renderer_render (GskRenderer *renderer,
surface = gdk_draw_context_get_surface (GDK_DRAW_CONTEXT (self->context));
scale_factor = gdk_surface_get_scale_factor (surface);
- render_region = get_render_region (surface, self->context);
viewport.origin.x = 0;
viewport.origin.y = 0;
@@ -209,6 +208,9 @@ gsk_next_renderer_render (GskRenderer *renderer,
gdk_gl_context_make_current (self->context);
gdk_draw_context_begin_frame (GDK_DRAW_CONTEXT (self->context), update_area);
+ /* Must be called *after* gdk_draw_context_begin_frame() */
+ render_region = get_render_region (surface, self->context);
+
gsk_next_driver_begin_frame (self->driver, self->command_queue);
job = gsk_gl_render_job_new (self->driver, &viewport, scale_factor, render_region, 0);
#ifdef G_ENABLE_DEBUG
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]