Vulkan: Set all four coordinates to NaN instead of just W. Fixes range culling on ARM. Fixes #11999.

This commit is contained in:
Henrik Rydgård
2019-08-08 23:14:20 +02:00
parent 59712eef92
commit caabc9023f
+1 -4
View File
@@ -47,9 +47,6 @@ static const char *vulkan_glsl_preamble =
// texcoord = 2
// fog = 3
#undef WRITE
#define WRITE p+=sprintf
@@ -634,7 +631,7 @@ bool GenerateVulkanGLSLVertexShader(const VShaderID &id, char *buffer) {
const char *outMin = "projPos.x < base.cullRangeMin.x || projPos.y < base.cullRangeMin.y || projPos.z < base.cullRangeMin.z";
const char *outMax = "projPos.x > base.cullRangeMax.x || projPos.y > base.cullRangeMax.y || projPos.z > base.cullRangeMax.z";
WRITE(p, " if (%s || %s) {\n", outMin, outMax);
WRITE(p, " outPos.w = base.cullRangeMax.w;\n");
WRITE(p, " outPos.xyzw = vec4(base.cullRangeMax.w);\n");
WRITE(p, " }\n");
WRITE(p, " }\n");
}