Matteo Bruni : wined3d: Use glClearDepthf() when available.
Alexandre Julliard
julliard at winehq.org
Thu Nov 26 16:31:00 CST 2020
Module: wine
Branch: master
Commit: 881e0a4310e5c9caf258ea9b45e70a0c948dfc77
URL: https://source.winehq.org/git/wine.git/?a=commit;h=881e0a4310e5c9caf258ea9b45e70a0c948dfc77
Author: Matteo Bruni <mbruni at codeweavers.com>
Date: Wed Nov 25 18:11:29 2020 +0100
wined3d: Use glClearDepthf() when available.
Signed-off-by: Matteo Bruni <mbruni at codeweavers.com>
Signed-off-by: Henri Verbeet <hverbeet at codeweavers.com>
Signed-off-by: Alexandre Julliard <julliard at winehq.org>
---
dlls/wined3d/texture.c | 5 ++++-
1 file changed, 4 insertions(+), 1 deletion(-)
diff --git a/dlls/wined3d/texture.c b/dlls/wined3d/texture.c
index 2f42a41754f..41e4415f13f 100644
--- a/dlls/wined3d/texture.c
+++ b/dlls/wined3d/texture.c
@@ -5398,7 +5398,10 @@ static void ffp_blitter_clear_rendertargets(struct wined3d_device *device, unsig
{
gl_info->gl_ops.gl.p_glDepthMask(GL_TRUE);
context_invalidate_state(context, STATE_DEPTH_STENCIL);
- gl_info->gl_ops.gl.p_glClearDepth(depth);
+ if (gl_info->supported[ARB_ES2_COMPATIBILITY])
+ GL_EXTCALL(glClearDepthf(depth));
+ else
+ gl_info->gl_ops.gl.p_glClearDepth(depth);
checkGLcall("glClearDepth");
clear_mask = clear_mask | GL_DEPTH_BUFFER_BIT;
}
More information about the wine-cvs
mailing list