Skip to content

Commit

Permalink
2.6.14
Browse files Browse the repository at this point in the history
fix in metallic additive lighting
  • Loading branch information
poiyomi committed May 19, 2019
1 parent a6508ec commit a636bf4
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions _PoiyomiToonShader/Includes/PoiFrag.cginc
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
{
_light_direction_var = _WorldSpaceLightPos0;
}
_flat_lighting_var = clamp(getNewPoiLighting(_light_direction_var, i.normal, _ShadowStrength, attenuation, _AttenuationMultiplier,AOMap), _MinBrightness, _MaxBrightness);
_flat_lighting_var = clamp(getNewPoiLighting(_light_direction_var, i.normal, _ShadowStrength, attenuation, _AttenuationMultiplier, AOMap), _MinBrightness, _MaxBrightness);
#else
#if defined(POINT) || defined(SPOT)
float3 _light_direction_var = normalize(_WorldSpaceLightPos0.xyz - i.worldPos);
Expand Down Expand Up @@ -230,7 +230,9 @@

#ifdef LIGHTING
#if(defined(POINT) || defined(SPOT))
finalColor *= (1 - _metallic_map_var);
#ifdef METALLIC
finalColor *= (1 - _metallic_map_var);
#endif
#ifdef TRANSPARENT
finalColor.rgb *= finalColor.a;
#endif
Expand Down

0 comments on commit a636bf4

Please sign in to comment.