Matteo Bruni : wined3d: Don't touch GL sRGB decode state when not supported.
Alexandre Julliard
julliard at winehq.org
Tue May 24 15:55:00 CDT 2022
Module: wine
Branch: master
Commit: 6c820bbcf07c8efd558abfafbb294f90b595e405
URL: https://source.winehq.org/git/wine.git/?a=commit;h=6c820bbcf07c8efd558abfafbb294f90b595e405
Author: Matteo Bruni <mbruni at codeweavers.com>
Date: Sun Apr 3 17:30:00 2022 +0200
wined3d: Don't touch GL sRGB decode state when not supported.
Signed-off-by: Matteo Bruni <mbruni at codeweavers.com>
---
dlls/wined3d/view.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/dlls/wined3d/view.c b/dlls/wined3d/view.c
index dbd385219f0..c502fcba992 100644
--- a/dlls/wined3d/view.c
+++ b/dlls/wined3d/view.c
@@ -1306,7 +1306,8 @@ void wined3d_shader_resource_view_gl_generate_mipmap(struct wined3d_shader_resou
if (gl_info->supported[ARB_SAMPLER_OBJECTS])
GL_EXTCALL(glBindSampler(context_gl->active_texture, 0));
gl_tex = wined3d_texture_gl_get_gl_texture(texture_gl, srgb);
- if (context_gl->c.d3d_info->wined3d_creation_flags & WINED3D_SRGB_READ_WRITE_CONTROL)
+ if (context_gl->c.d3d_info->wined3d_creation_flags & WINED3D_SRGB_READ_WRITE_CONTROL
+ && gl_info->supported[EXT_TEXTURE_SRGB_DECODE])
{
gl_info->gl_ops.gl.p_glTexParameteri(texture_gl->target,
GL_TEXTURE_SRGB_DECODE_EXT, GL_SKIP_DECODE_EXT);
More information about the wine-cvs
mailing list