mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-08-11 18:50:30 +00:00
VertexShaderGen: Clip z using user-defined clipping planes.
This commit is contained in:
parent
159247f4ad
commit
b1ed7e80fb
3 changed files with 10 additions and 0 deletions
|
@ -196,6 +196,8 @@ inline void GenerateVSOutputMembers(T& object, APIType api_type, u32 texgens,
|
|||
DefineOutputMember(object, api_type, qualifier, "float3", "WorldPos", -1, "TEXCOORD",
|
||||
texgens + 2);
|
||||
}
|
||||
|
||||
DefineOutputMember(object, api_type, qualifier, "float", "clipDist", -1, "SV_ClipDistance");
|
||||
}
|
||||
|
||||
template <class T>
|
||||
|
@ -216,6 +218,8 @@ inline void AssignVSOutputMembers(T& object, const char* a, const char* b, u32 t
|
|||
object.Write("\t%s.Normal = %s.Normal;\n", a, b);
|
||||
object.Write("\t%s.WorldPos = %s.WorldPos;\n", a, b);
|
||||
}
|
||||
|
||||
object.Write("\t%s.clipDist = %s.clipDist;\n", a, b);
|
||||
}
|
||||
|
||||
// We use the flag "centroid" to fix some MSAA rendering bugs. With MSAA, the
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue