Skip to content

Commit

Permalink
#3987 add env toggle to force RGBA internal format
Browse files Browse the repository at this point in the history
  • Loading branch information
totaam committed Jan 29, 2024
1 parent b2c0932 commit 2ce2313
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion xpra/client/gl/backing.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,6 +86,7 @@
CONTEXT_REINIT = envbool("XPRA_OPENGL_CONTEXT_REINIT", False)
NVJPEG = envbool("XPRA_OPENGL_NVJPEG", True)
NVDEC = envbool("XPRA_OPENGL_NVDEC", False)
ALWAYS_RGBA = envbool("XPRA_OPENGL_ALWAYS_RGBA", False)

CURSOR_IDLE_TIMEOUT: int = envint("XPRA_CURSOR_IDLE_TIMEOUT", 6)

Expand Down Expand Up @@ -297,7 +298,7 @@ def init_formats(self) -> None:
if self.bit_depth not in (0, 24, 32) and first_time(f"bit-depth-{self.bit_depth}"):
log.warn(f"Warning: invalid bit depth {self.bit_depth}, using 24")
# (pixels are always stored in 32bpp - but this makes it clearer when we do/don't support alpha)
if self._alpha_enabled:
if self._alpha_enabled or ALWAYS_RGBA:
self.internal_format = GL_RGBA8
else:
self.internal_format = GL_RGB8
Expand Down

0 comments on commit 2ce2313

Please sign in to comment.