diff options
author | RĂ©mi Verschelde <rverschelde@gmail.com> | 2019-03-03 13:43:43 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-03-03 13:43:43 +0100 |
commit | 88e0bed081b1b48c4f0e5caaaba53fc71ee3b23c (patch) | |
tree | cb9cb860a0a9f686aa139bd79e70f02ed7b7bfd8 /scene/3d | |
parent | dd5376f9dffa1d03a6a60ff9c41012ae5c3b06d2 (diff) | |
parent | 95837049e8ff920c6a2df5b093040a5d8e581c75 (diff) |
Merge pull request #26514 from clayjohn/hide_properties_gles2
Hide hdr and shadow_contact in gles2
Diffstat (limited to 'scene/3d')
-rw-r--r-- | scene/3d/light.cpp | 7 | ||||
-rw-r--r-- | scene/3d/light.h | 1 |
2 files changed, 8 insertions, 0 deletions
diff --git a/scene/3d/light.cpp b/scene/3d/light.cpp index 3b514dab8c..cf1af918f7 100644 --- a/scene/3d/light.cpp +++ b/scene/3d/light.cpp @@ -210,6 +210,13 @@ bool Light::is_editor_only() const { return editor_only; } +void Light::_validate_property(PropertyInfo &property) const { + + if (VisualServer::get_singleton()->is_low_end() && property.name == "shadow_contact") { + property.usage = PROPERTY_USAGE_NOEDITOR | PROPERTY_USAGE_INTERNAL; + } +} + void Light::_bind_methods() { ClassDB::bind_method(D_METHOD("set_editor_only", "editor_only"), &Light::set_editor_only); diff --git a/scene/3d/light.h b/scene/3d/light.h index 85e0ce3c24..ddd5bc6b3a 100644 --- a/scene/3d/light.h +++ b/scene/3d/light.h @@ -92,6 +92,7 @@ protected: static void _bind_methods(); void _notification(int p_what); + virtual void _validate_property(PropertyInfo &property) const; Light(VisualServer::LightType p_type); |