diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2020-01-21 21:32:27 +0100 |
---|---|---|
committer | Rémi Verschelde <rverschelde@gmail.com> | 2020-01-21 21:41:54 +0100 |
commit | 4faaf6089a3880d673c5fc51a260128bfe59b351 (patch) | |
tree | 08232615d23839c83ae1bdd515a28d7e94ccdf83 /drivers/gles3/shaders | |
parent | 79aaafc686ac57ea535d0542e123e9f45a097e69 (diff) |
Remove unused #if 0'ed code
Diffstat (limited to 'drivers/gles3/shaders')
-rw-r--r-- | drivers/gles3/shaders/scene.glsl | 29 |
1 files changed, 0 insertions, 29 deletions
diff --git a/drivers/gles3/shaders/scene.glsl b/drivers/gles3/shaders/scene.glsl index a330dbef77..a45ac2eb8a 100644 --- a/drivers/gles3/shaders/scene.glsl +++ b/drivers/gles3/shaders/scene.glsl @@ -1224,35 +1224,6 @@ in highp float dp_clip; #endif -#if 0 -// need to save texture depth for this -vec3 light_transmittance(float translucency,vec3 light_vec, vec3 normal, vec3 pos, float distance) { - - float scale = 8.25 * (1.0 - translucency) / subsurface_scatter_width; - float d = scale * distance; - - /** - * Armed with the thickness, we can now calculate the color by means of the - * precalculated transmittance profile. - * (It can be precomputed into a texture, for maximum performance): - */ - float dd = -d * d; - vec3 profile = - vec3(0.233, 0.455, 0.649) * exp(dd / 0.0064) + - vec3(0.1, 0.336, 0.344) * exp(dd / 0.0484) + - vec3(0.118, 0.198, 0.0) * exp(dd / 0.187) + - vec3(0.113, 0.007, 0.007) * exp(dd / 0.567) + - vec3(0.358, 0.004, 0.0) * exp(dd / 1.99) + - vec3(0.078, 0.0, 0.0) * exp(dd / 7.41); - - /** - * Using the profile, we finally approximate the transmitted lighting from - * the back of the object: - */ - return profile * clamp(0.3 + dot(light_vec, normal),0.0,1.0); -} -#endif - void light_process_omni(int idx, vec3 vertex, vec3 eye_vec, vec3 normal, vec3 binormal, vec3 tangent, vec3 albedo, vec3 transmission, float roughness, float metallic, float specular, float rim, float rim_tint, float clearcoat, float clearcoat_gloss, float anisotropy, float p_blob_intensity, inout vec3 diffuse_light, inout vec3 specular_light, inout float alpha) { vec3 light_rel_vec = omni_lights[idx].light_pos_inv_radius.xyz - vertex; |