summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>2024-04-22 14:27:16 +0200
committerManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>2024-04-22 14:27:42 +0200
commitee37965fad79a815feea3f8a4a6cfec03d4a9029 (patch)
tree198d206f531f04d0ba13f8681327ea2667a5149d /src
parente39c96f419b598c2469efa1bd38c7e644f562df8 (diff)
Fix: Wayland use of alpha in glClearColor/glClear (#957)
Diffstat (limited to 'src')
-rw-r--r--src/drivers/Wayland/Fl_Wayland_Gl_Window_Driver.cxx1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/drivers/Wayland/Fl_Wayland_Gl_Window_Driver.cxx b/src/drivers/Wayland/Fl_Wayland_Gl_Window_Driver.cxx
index 8c14912f2..00c1ab0ca 100644
--- a/src/drivers/Wayland/Fl_Wayland_Gl_Window_Driver.cxx
+++ b/src/drivers/Wayland/Fl_Wayland_Gl_Window_Driver.cxx
@@ -299,6 +299,7 @@ void Fl_Wayland_Gl_Window_Driver::make_current_before() {
Fl_Wayland_Gl_Choice *g = (Fl_Wayland_Gl_Choice*)this->g();
egl_surface = eglCreateWindowSurface(egl_display, g->egl_conf, egl_window, NULL);
wl_surface_set_buffer_scale(surface, scale);
+ if (mode() & FL_ALPHA) wl_surface_set_opaque_region(surface, NULL);
// Tested apps: shape, glpuzzle, cube, fractals, gl_overlay, fullscreen, unittests,
// OpenGL3-glut-test, OpenGL3test.
// Tested wayland compositors: mutter, kde-plasma, weston, sway on FreeBSD.