mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
Vulkan: Cleanup unused geometry shader vars.
Without clipping, these aren't used (but could be in the future with manual clipping.)
This commit is contained in:
parent
2832edcc37
commit
4df7a8f357
1 changed files with 2 additions and 2 deletions
|
@ -111,10 +111,10 @@ bool GenerateGeometryShader(const GShaderID &id, char *buffer, const ShaderLangu
|
|||
p.C(" for (int i = 0; i < 3; i++) {\n"); // TODO: 3 or gl_in.length()? which will be faster?
|
||||
p.C(" vec4 outPos = gl_in[i].gl_Position;\n");
|
||||
p.C(" gl_Position = outPos;\n");
|
||||
p.C(" vec3 projPos = outPos.xyz / outPos.w;\n");
|
||||
p.C(" float projZ = (projPos.z - u_depthRange.z) * u_depthRange.w;\n");
|
||||
// TODO: Not rectangles...
|
||||
if (gstate_c.Supports(GPU_SUPPORTS_CLIP_DISTANCE)) {
|
||||
p.C(" vec3 projPos = outPos.xyz / outPos.w;\n");
|
||||
p.C(" float projZ = (projPos.z - u_depthRange.z) * u_depthRange.w;\n");
|
||||
p.F(" gl_ClipDistance%s = projZ * outPos.w + outPos.w;\n", clip0);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue