daily pastebin goal
42%
SHARE
TWEET

Untitled

a guest Jan 21st, 2019 61 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. float3 refl = reflect(e, n);
  2. float dist = length(L.xyz);
  3. float3 l = normalize(L.xyz);
  4. float attn = 1.0 / (1.0 + 1.0 / 30 * dist + 1.0 / 700 * dist * dist);
  5. d += saturate(dot(n,l)) * gLightColor[i].xyz * attn.xxx;
  6. s += pow(saturate(dot(-refl, l)), power) * gLightColor[i].xyz;
RAW Paste Data
We use cookies for various purposes including analytics. By continuing to use Pastebin, you agree to our use of cookies as described in the Cookies Policy. OK, I Understand
 
Top