diff options
Diffstat (limited to '3ner.cginc')
| -rw-r--r-- | 3ner.cginc | 10 |
1 files changed, 9 insertions, 1 deletions
@@ -161,14 +161,22 @@ v2f domain( return o; } -float4 frag(v2f i, uint facing : SV_IsFrontFace) : SV_Target { +float4 frag(v2f i, uint facing : SV_IsFrontFace +#if defined(_CUSTOM31_TUBES) +, out float depth : SV_DepthLessEqual +#endif +) : SV_Target { i.normal *= facing ? 1 : -1; i.normal = normalize(i.normal); i.tangent.xyz = normalize(i.tangent.xyz); Pbr pbr = getPbr(i); +#if defined(_UNLIT) + return pbr.albedo; +#else LightData light_data; GetLighting(i, pbr, light_data); return brdf(pbr, light_data); +#endif } #endif // __3NER_INC |
