mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
Make sure to not leave cull distance uninitialized in other paths, if we do write to it in some path.
This commit is contained in:
parent
edc4e69c3d
commit
906a04f1fd
1 changed files with 4 additions and 1 deletions
|
@ -1135,7 +1135,10 @@ bool GenerateVertexShader(const VShaderID &id, char *buffer, const ShaderLanguag
|
|||
WRITE(p, " if (u_cullRangeMin.w > 0.0) {\n");
|
||||
WRITE(p, " %sgl_CullDistance%s = projPos.z - u_cullRangeMin.z;\n", compat.vsOutPrefix, cull0);
|
||||
WRITE(p, " %sgl_CullDistance%s = u_cullRangeMax.z - projPos.z;\n", compat.vsOutPrefix, cull1);
|
||||
WRITE(p, " }\n");
|
||||
WRITE(p, " } else {\n");
|
||||
WRITE(p, " %sgl_CullDistance%s = 0.0;\n", compat.vsOutPrefix, cull0);
|
||||
WRITE(p, " %sgl_CullDistance%s = 0.0;\n", compat.vsOutPrefix, cull1);
|
||||
WRITE(p, " }");
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue