summaryrefslogtreecommitdiff
path: root/scene/resources/material.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'scene/resources/material.cpp')
-rw-r--r--scene/resources/material.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/scene/resources/material.cpp b/scene/resources/material.cpp
index 619af375da..190dc707c4 100644
--- a/scene/resources/material.cpp
+++ b/scene/resources/material.cpp
@@ -830,7 +830,7 @@ void SpatialMaterial::_update_shader() {
code += "\tALPHA = albedo.a * albedo_tex.a;\n";
}
- if (!VisualServer::get_singleton()->is_low_end() && proximity_fade_enabled) {
+ if (proximity_fade_enabled) {
code += "\tfloat depth_tex = textureLod(DEPTH_TEXTURE,SCREEN_UV,0.0).r;\n";
code += "\tvec4 world_pos = INV_PROJECTION_MATRIX * vec4(SCREEN_UV*2.0-1.0,depth_tex*2.0-1.0,1.0);\n";
code += "\tworld_pos.xyz/=world_pos.w;\n";