From de284f931d75d985a6cffc2da52614334512be76 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Verschelde?= Date: Fri, 4 Sep 2020 10:43:11 +0200 Subject: [PATCH] doc: Sync classref with current source --- doc/classes/EditorFeatureProfile.xml | 10 +++++----- doc/classes/GPUParticles2D.xml | 2 +- doc/classes/GPUParticles3D.xml | 2 +- doc/classes/VisualShader.xml | 6 ++++-- editor/editor_feature_profile.cpp | 2 +- scene/resources/shader.cpp | 2 -- scene/resources/visual_shader.cpp | 3 +++ 7 files changed, 15 insertions(+), 12 deletions(-) diff --git a/doc/classes/EditorFeatureProfile.xml b/doc/classes/EditorFeatureProfile.xml index eb03d3010f7..e05a685dd7f 100644 --- a/doc/classes/EditorFeatureProfile.xml +++ b/doc/classes/EditorFeatureProfile.xml @@ -135,15 +135,15 @@ Scene tree editing. If this feature is disabled, the Scene tree dock will still be visible but will be read-only. - - The Import dock. If this feature is disabled, the Import dock won't be visible. - - + The Node dock. If this feature is disabled, signals and groups won't be visible and modifiable from the editor. - + The FileSystem dock. If this feature is disabled, the FileSystem dock won't be visible. + + The Import dock. If this feature is disabled, the Import dock won't be visible. + Represents the size of the [enum Feature] enum. diff --git a/doc/classes/GPUParticles2D.xml b/doc/classes/GPUParticles2D.xml index 5bed28aaf71..244bdcf2f3c 100644 --- a/doc/classes/GPUParticles2D.xml +++ b/doc/classes/GPUParticles2D.xml @@ -33,7 +33,7 @@ Particle draw order. Uses [enum DrawOrder] values. - + If [code]true[/code], particles are being emitted. diff --git a/doc/classes/GPUParticles3D.xml b/doc/classes/GPUParticles3D.xml index 3e17963407b..3fc9e73ccf9 100644 --- a/doc/classes/GPUParticles3D.xml +++ b/doc/classes/GPUParticles3D.xml @@ -68,7 +68,7 @@ The number of draw passes when rendering particles. - + If [code]true[/code], particles are being emitted. diff --git a/doc/classes/VisualShader.xml b/doc/classes/VisualShader.xml index 40b0f524696..12954beb43c 100644 --- a/doc/classes/VisualShader.xml +++ b/doc/classes/VisualShader.xml @@ -193,7 +193,6 @@ - The offset vector of the whole graph. @@ -210,7 +209,10 @@ A shader for light calculations. - + + A compute shader, to use the GPU for abstract computation. + + Represents the size of the [enum Type] enum. diff --git a/editor/editor_feature_profile.cpp b/editor/editor_feature_profile.cpp index 418370a7c32..7335563dd9f 100644 --- a/editor/editor_feature_profile.cpp +++ b/editor/editor_feature_profile.cpp @@ -271,9 +271,9 @@ void EditorFeatureProfile::_bind_methods() { BIND_ENUM_CONSTANT(FEATURE_SCRIPT); BIND_ENUM_CONSTANT(FEATURE_ASSET_LIB); BIND_ENUM_CONSTANT(FEATURE_SCENE_TREE); - BIND_ENUM_CONSTANT(FEATURE_IMPORT_DOCK); BIND_ENUM_CONSTANT(FEATURE_NODE_DOCK); BIND_ENUM_CONSTANT(FEATURE_FILESYSTEM_DOCK); + BIND_ENUM_CONSTANT(FEATURE_IMPORT_DOCK); BIND_ENUM_CONSTANT(FEATURE_MAX); } diff --git a/scene/resources/shader.cpp b/scene/resources/shader.cpp index 42495425676..92f0353abf0 100644 --- a/scene/resources/shader.cpp +++ b/scene/resources/shader.cpp @@ -142,8 +142,6 @@ void Shader::_bind_methods() { ClassDB::bind_method(D_METHOD("has_param", "name"), &Shader::has_param); - //ClassDB::bind_method(D_METHOD("get_param_list"),&Shader::get_fragment_code); - ADD_PROPERTY(PropertyInfo(Variant::STRING, "code", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR), "set_code", "get_code"); BIND_ENUM_CONSTANT(MODE_SPATIAL); diff --git a/scene/resources/visual_shader.cpp b/scene/resources/visual_shader.cpp index 33de24ad146..c774fb4b69d 100644 --- a/scene/resources/visual_shader.cpp +++ b/scene/resources/visual_shader.cpp @@ -1577,9 +1577,12 @@ void VisualShader::_bind_methods() { ADD_PROPERTY(PropertyInfo(Variant::VECTOR2, "graph_offset", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR), "set_graph_offset", "get_graph_offset"); ADD_PROPERTY(PropertyInfo(Variant::STRING, "version", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR), "set_version", "get_version"); + ADD_PROPERTY_DEFAULT("code", ""); // Inherited from Shader, prevents showing default code as override in docs. + BIND_ENUM_CONSTANT(TYPE_VERTEX); BIND_ENUM_CONSTANT(TYPE_FRAGMENT); BIND_ENUM_CONSTANT(TYPE_LIGHT); + BIND_ENUM_CONSTANT(TYPE_COMPUTE); BIND_ENUM_CONSTANT(TYPE_MAX); BIND_CONSTANT(NODE_ID_INVALID);