summaryrefslogtreecommitdiff
path: root/scene/main
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2019-03-03 13:43:43 +0100
committerGitHub <noreply@github.com>2019-03-03 13:43:43 +0100
commit88e0bed081b1b48c4f0e5caaaba53fc71ee3b23c (patch)
treecb9cb860a0a9f686aa139bd79e70f02ed7b7bfd8 /scene/main
parentdd5376f9dffa1d03a6a60ff9c41012ae5c3b06d2 (diff)
parent95837049e8ff920c6a2df5b093040a5d8e581c75 (diff)
Merge pull request #26514 from clayjohn/hide_properties_gles2
Hide hdr and shadow_contact in gles2
Diffstat (limited to 'scene/main')
-rw-r--r--scene/main/viewport.cpp7
-rw-r--r--scene/main/viewport.h1
2 files changed, 8 insertions, 0 deletions
diff --git a/scene/main/viewport.cpp b/scene/main/viewport.cpp
index 090e6bdcb0..5bfdb5a9fd 100644
--- a/scene/main/viewport.cpp
+++ b/scene/main/viewport.cpp
@@ -2923,6 +2923,13 @@ bool Viewport::is_handling_input_locally() const {
return handle_input_locally;
}
+void Viewport::_validate_property(PropertyInfo &property) const {
+
+ if (VisualServer::get_singleton()->is_low_end() && property.name == "hdr") {
+ property.usage = PROPERTY_USAGE_NOEDITOR | PROPERTY_USAGE_INTERNAL;
+ }
+}
+
void Viewport::_bind_methods() {
ClassDB::bind_method(D_METHOD("set_use_arvr", "use"), &Viewport::set_use_arvr);
diff --git a/scene/main/viewport.h b/scene/main/viewport.h
index 4d0a4e8c87..b8b5bf07a7 100644
--- a/scene/main/viewport.h
+++ b/scene/main/viewport.h
@@ -390,6 +390,7 @@ private:
protected:
void _notification(int p_what);
static void _bind_methods();
+ virtual void _validate_property(PropertyInfo &property) const;
public:
Listener *get_listener() const;