Commit efed4c33 authored by H. Verbeet's avatar H. Verbeet Committed by Alexandre Julliard

wined3d: gl_FragDepth is a float, so fixup the write mask.

parent 4352934b
...@@ -711,9 +711,11 @@ static void shader_glsl_get_register_name( ...@@ -711,9 +711,11 @@ static void shader_glsl_get_register_name(
static DWORD shader_glsl_get_write_mask(const DWORD param, char *write_mask) { static DWORD shader_glsl_get_write_mask(const DWORD param, char *write_mask) {
char *ptr = write_mask; char *ptr = write_mask;
DWORD mask = param & WINED3DSP_WRITEMASK_ALL; DWORD mask = param & WINED3DSP_WRITEMASK_ALL;
DWORD reg_type = shader_get_regtype(param);
/* gl_FogFragCoord and glPointSize are floats, fixup the write mask. */ /* gl_FogFragCoord, gl_PointSize and gl_FragDepth are floats, fixup the write mask. */
if ((shader_get_regtype(param) == WINED3DSPR_RASTOUT) && ((param & WINED3DSP_REGNUM_MASK) != 0)) { if (((reg_type == WINED3DSPR_RASTOUT) && ((param & WINED3DSP_REGNUM_MASK) != 0))
|| reg_type == WINED3DSPR_DEPTHOUT) {
mask = WINED3DSP_WRITEMASK_0; mask = WINED3DSP_WRITEMASK_0;
} else { } else {
*ptr++ = '.'; *ptr++ = '.';
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment