From: Benjamin Otte Date: Wed, 24 May 2023 19:41:47 +0000 (+0200) Subject: gl: Update tracked buffers from 2 to 4 X-Git-Tag: archive/raspbian/4.12.3+ds-1+rpi1~1^2^2^2~22^2~1^2~221^2~1 X-Git-Url: https://dgit.raspbian.org/?a=commitdiff_plain;h=46e3454eb7730e49374ebdeacdf9078db335c1f9;p=gtk4.git gl: Update tracked buffers from 2 to 4 With XWayland and direct scanout it is possible that some apps get into a situation where more than 2 buffers are in flight and in that case we want to be able to still track the change regions for those buffers. Usually 3 buffers are in use, so we go one higher, just to be safe. --- diff --git a/gdk/gdkglcontextprivate.h b/gdk/gdkglcontextprivate.h index cd28d48a7a..9ce133c4b7 100644 --- a/gdk/gdkglcontextprivate.h +++ b/gdk/gdkglcontextprivate.h @@ -37,7 +37,7 @@ typedef enum { /* The maximum amount of buffers we track update regions for. * Note that this is equal to the max buffer age value we * can provide a damage region for */ -#define GDK_GL_MAX_TRACKED_BUFFERS 2 +#define GDK_GL_MAX_TRACKED_BUFFERS 4 #define GDK_GL_CONTEXT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), GDK_TYPE_GL_CONTEXT, GdkGLContextClass)) #define GDK_IS_GL_CONTEXT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), GDK_TYPE_GL_CONTEXT))