diff options
| author | yum <yum.food.vr@gmail.com> | 2024-07-28 14:14:30 -0700 |
|---|---|---|
| committer | yum <yum.food.vr@gmail.com> | 2024-07-28 14:14:30 -0700 |
| commit | 22d3a28ef6ac9f4fc9204ae3bc0c67d82feac46e (patch) | |
| tree | 1cfe361a86a731e630ceece702e7654ce62cfabf /interpolators.cginc | |
| parent | aa932e9df0691f1de27fb44e06e8d786400c3d2a (diff) | |
Implement stereo instancing
Seems to fix VR flickering bug.
Also:
* Add vertex lighting factor
* Remove clearcoat 10x factors
* Lighting factors now affect clearcoat
* Simplify `#pragma multi_compile` bits
Diffstat (limited to 'interpolators.cginc')
| -rw-r--r-- | interpolators.cginc | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/interpolators.cginc b/interpolators.cginc index 27db59c..e14831a 100644 --- a/interpolators.cginc +++ b/interpolators.cginc @@ -11,6 +11,8 @@ struct appdata float3 normal : NORMAL; float2 uv0 : TEXCOORD0; float2 uv1 : TEXCOORD1; + + UNITY_VERTEX_INPUT_INSTANCE_ID }; struct v2f @@ -26,6 +28,8 @@ struct v2f #if defined(SSR_ENABLED) float4 screenPos : TEXCOORD5; #endif + + UNITY_VERTEX_OUTPUT_STEREO }; #else @@ -37,6 +41,8 @@ struct appdata float2 uv1 : TEXCOORD1; float3 normal : NORMAL; float4 tangent : TANGENT; + + UNITY_VERTEX_INPUT_INSTANCE_ID }; struct v2f @@ -58,6 +64,8 @@ struct v2f #if defined(SSR_ENABLED) float4 screenPos : TEXCOORD8; #endif + + UNITY_VERTEX_OUTPUT_STEREO }; #endif |
