HitResult and Ray structs. random function.
This commit is contained in:
@@ -10,7 +10,7 @@ vec3 applyLighting(vec3 hitPoint, vec3 view, vec3 normal, uint brick)
|
||||
|
||||
vec3 ambient = light_color * 0.1;
|
||||
vec3 diffuse = light_color * max(1.0-dot(normal, _SunDir), 0.0);
|
||||
vec3 specular = light_color * pow(max(dot(view, reflect(-_SunDir, normal)), 0.0), 32);
|
||||
vec3 specular = light_color * pow(max(dot(view, reflect(_SunDir, normal)), 0.0), 32);
|
||||
|
||||
// Combine colors
|
||||
vec3 object_color = _Materials[brick-1].albedo.rgb;//vec3(0.0, 0.1, 0.5);
|
||||
|
||||
Reference in New Issue
Block a user