This repository was archived by the owner on Nov 30, 2020. It is now read-only.
File tree Expand file tree Collapse file tree
PostProcessing/Resources/Shaders Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -164,7 +164,7 @@ VaryingsMultitex VertMultitex(AttributesDefault v)
164164#endif
165165
166166 VaryingsMultitex o;
167- o.pos = mul (UNITY_MATRIX_MVP, v.vertex);
167+ o.pos = UnityObjectToClipPos ( v.vertex);
168168 o.uv = v.texcoord.xy;
169169 o.uv01 = uvAlt;
170170 o.uvSPR = UnityStereoTransformScreenSpaceTex (uvAlt);
Original file line number Diff line number Diff line change @@ -19,7 +19,7 @@ Shader "Hidden/Post FX/Blit"
1919 Varyings VertBlit (AttributesDefault v)
2020 {
2121 Varyings o;
22- o.vertex = mul ( UNITY_MATRIX_MVP , v.vertex);
22+ o.vertex = UnityObjectToClipPos ( v.vertex);
2323 o.uv = UnityStereoScreenSpaceUVAdjust (v.texcoord, _MainTex_ST);
2424 return o;
2525 }
Original file line number Diff line number Diff line change @@ -60,7 +60,7 @@ Shader "Hidden/Post FX/Bloom"
6060 VaryingsMultitex VertMultitex (AttributesDefault v)
6161 {
6262 VaryingsMultitex o;
63- o.pos = mul ( UNITY_MATRIX_MVP , v.vertex);
63+ o.pos = UnityObjectToClipPos ( v.vertex);
6464 o.uvMain = UnityStereoScreenSpaceUVAdjust (v.texcoord.xy, _MainTex_ST);
6565 o.uvBase = o.uvMain;
6666
Original file line number Diff line number Diff line change @@ -39,7 +39,7 @@ struct VaryingsDefault
3939VaryingsDefault VertDefault (AttributesDefault v)
4040{
4141 VaryingsDefault o;
42- o.pos = mul (UNITY_MATRIX_MVP, v.vertex);
42+ o.pos = UnityObjectToClipPos ( v.vertex);
4343 o.uv = v.texcoord.xy;
4444 o.uvSPR = UnityStereoScreenSpaceUVAdjust (v.texcoord.xy, _MainTex_ST);
4545 return o;
Original file line number Diff line number Diff line change @@ -34,12 +34,12 @@ VaryingsDOF VertDOF(AttributesDefault v)
3434#endif
3535
3636 VaryingsDOF o;
37- #if defined (UNITY_SINGLE_PASS_STEREO)
3837 o.pos = UnityObjectToClipPos (v.vertex);
38+
39+ #if defined (UNITY_SINGLE_PASS_STEREO)
3940 o.uv = UnityStereoScreenSpaceUVAdjust (v.texcoord, _MainTex_ST);
4041 o.uvAlt = UnityStereoScreenSpaceUVAdjust (uvAlt, _MainTex_ST);
4142#else
42- o.pos = mul (UNITY_MATRIX_MVP, v.vertex);
4343 o.uv = v.texcoord;
4444 o.uvAlt = uvAlt;
4545#endif
Original file line number Diff line number Diff line change @@ -134,7 +134,7 @@ Shader "Hidden/Post FX/Eye Adaptation"
134134 VaryingsEditorHisto VertEditorHisto (AttributesDefault v)
135135 {
136136 VaryingsEditorHisto o;
137- o.pos = mul ( UNITY_MATRIX_MVP , v.vertex);
137+ o.pos = UnityObjectToClipPos ( v.vertex);
138138 o.uv = v.texcoord.xy;
139139 o.maxValue = 1.0 / FindMaxHistogramValue ();
140140 o.avgLuminance = GetAverageLuminance (o.maxValue);
Original file line number Diff line number Diff line change @@ -59,7 +59,7 @@ struct VaryingsMultitex
5959VaryingsMultitex VertMultitex (AttributesDefault v)
6060{
6161 VaryingsMultitex o;
62- o.pos = mul (UNITY_MATRIX_MVP, v.vertex);
62+ o.pos = UnityObjectToClipPos ( v.vertex);
6363 o.uv0 = v.texcoord.xy;
6464 o.uv1 = v.texcoord.xy;
6565
Original file line number Diff line number Diff line change @@ -97,7 +97,7 @@ Shader "Hidden/Post FX/Screen Space Reflection"
9797 {
9898 v2f o;
9999
100- o.pos = mul ( UNITY_MATRIX_MVP , v.vertex);
100+ o.pos = UnityObjectToClipPos ( v.vertex);
101101 o.uv = v.texcoord.xy;
102102 o.uv2 = v.texcoord.xy;
103103
Original file line number Diff line number Diff line change @@ -58,7 +58,7 @@ VaryingsSolver VertSolver(AttributesDefault input)
5858{
5959 VaryingsSolver output;
6060
61- float4 vertex = mul (UNITY_MATRIX_MVP, input.vertex);
61+ float4 vertex = UnityObjectToClipPos ( input.vertex);
6262
6363 output.vertex = vertex;
6464 output.uv = input.texcoord.xyxy;
Original file line number Diff line number Diff line change @@ -86,7 +86,7 @@ Shader "Hidden/Post FX/Uber Shader"
8686 VaryingsFlipped VertUber (AttributesDefault v)
8787 {
8888 VaryingsFlipped o;
89- o.pos = mul ( UNITY_MATRIX_MVP , v.vertex);
89+ o.pos = UnityObjectToClipPos ( v.vertex);
9090 o.uv = v.texcoord.xy;
9191 o.uvSPR = UnityStereoScreenSpaceUVAdjust (v.texcoord.xy, _MainTex_ST);
9292 o.uvFlipped = v.texcoord.xy;
You can’t perform that action at this time.
0 commit comments