2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-09 04:27:42 +00:00

Metal fixes

This commit is contained in:
Jack Andersen
2019-03-03 18:45:22 -10:00
parent 54f0724de5
commit ed4ebf0af1
8 changed files with 27 additions and 32 deletions

View File

@@ -15,7 +15,7 @@
"static float4 MainPostFunc(thread VertToFrag& vtf, constant LightingUniform& lu, float4 colorIn)\n" \
"{\n" \
" float fogZ;\n" \
" float fogF = saturate((lu.fog.A / (lu.fog.B - vtf.pos.z)) - lu.fog.C);\n" \
" float fogF = saturate((lu.fog.A / (lu.fog.B - (1.0 - vtf.pos.z))) - lu.fog.C);\n" \
" switch (lu.fog.mode)\n" \
" {\n" \
" case 2:\n" \
@@ -41,7 +41,7 @@
"#if %d\n" \
" return float4(mix(colorIn, float4(0.0), saturate(fogZ)).rgb, colorIn.a);\n" \
"#else\n" \
" return float4(mix(colorIn, fog.color, saturate(fogZ)).rgb, colorIn.a);\n" \
" return float4(mix(colorIn, lu.fog.color, saturate(fogZ)).rgb, colorIn.a);\n" \
"#endif\n" \
"}\n"