We are currently migrating Bugzilla to GitHub issues.
Any changes made to the bug tracker now will be lost, so please do not post new bugs or make changes to them.
When we're done, all bug URLs will redirect to their equivalent location on the new bug tracker.

Bug 5392 - 0 alpha size setting not respected on EGL (Wayland)
Summary: 0 alpha size setting not respected on EGL (Wayland)
Status: ASSIGNED
Alias: None
Product: SDL
Classification: Unclassified
Component: video (show other bugs)
Version: HG 2.1
Hardware: Other Other
: P2 normal
Assignee: Ryan C. Gordon
QA Contact: Sam Lantinga
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2020-12-11 18:07 UTC by greg
Modified: 2020-12-13 03:27 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description greg 2020-12-11 18:07:30 UTC
In sdl_egl, EGL_ALPHA_SIZE is only set if gl_config.alpha_size is "true" (non-zero):

http://hg.libsdl.org/SDL/file/6044f03a6809/src/video/SDL_egl.c#l711

But it should always be set!

On Wayland, having alpha is the default. SDL users expect no alpha to be the default – it is even mentioned in https://wiki.libsdl.org/SDL_GL_SetAttribute that SDL_GL_ALPHA_SIZE defaults to 0. But this if condition breaks that by interpreting *that* zero as "just use platform default", so there's basically no way to create an SDL window without transparency on Wayland.