diff options
| author | Yuri Roubinsky <chaosus89@gmail.com> | 2020-09-07 10:28:13 +0300 |
|---|---|---|
| committer | Yuri Roubinsky <chaosus89@gmail.com> | 2020-09-07 13:33:51 +0300 |
| commit | dc6685d28fa147b05e64efab03796509b9640218 (patch) | |
| tree | 6431e5a3f0db61b4b3c0ba5ac1ebdb81a9946803 /editor/plugins/visual_shader_editor_plugin.h | |
| parent | 365dbde25d00520ff3aeb37a37daba2cc3b161e2 (diff) | |
| download | redot-engine-dc6685d28fa147b05e64efab03796509b9640218.tar.gz | |
Remakes particles in visual shaders
Diffstat (limited to 'editor/plugins/visual_shader_editor_plugin.h')
| -rw-r--r-- | editor/plugins/visual_shader_editor_plugin.h | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/editor/plugins/visual_shader_editor_plugin.h b/editor/plugins/visual_shader_editor_plugin.h index ff2b0dc6ab..6284c9a530 100644 --- a/editor/plugins/visual_shader_editor_plugin.h +++ b/editor/plugins/visual_shader_editor_plugin.h @@ -63,7 +63,9 @@ class VisualShaderEditor : public VBoxContainer { Button *add_node; Button *preview_shader; - OptionButton *edit_type; + OptionButton *edit_type = nullptr; + OptionButton *edit_type_standart; + OptionButton *edit_type_particles; PanelContainer *error_panel; Label *error_label; @@ -84,13 +86,18 @@ class VisualShaderEditor : public VBoxContainer { MenuButton *tools; bool preview_showed; + bool particles_mode; enum TypeFlags { TYPE_FLAGS_VERTEX = 1, TYPE_FLAGS_FRAGMENT = 2, TYPE_FLAGS_LIGHT = 4, - TYPE_FLAGS_COMPUTE = 8, - TYPE_FLAGS_VERTEX_FRAGMENT_LIGHT = TYPE_FLAGS_VERTEX | TYPE_FLAGS_FRAGMENT | TYPE_FLAGS_LIGHT, + }; + + enum ParticlesTypeFlags { + TYPE_FLAGS_EMIT = 1, + TYPE_FLAGS_PROCESS = 2, + TYPE_FLAGS_END = 4 }; enum ToolsMenuOptions { @@ -242,6 +249,8 @@ class VisualShaderEditor : public VBoxContainer { void _input_select_item(Ref<VisualShaderNodeInput> input, String name); void _uniform_select_item(Ref<VisualShaderNodeUniformRef> p_uniform, String p_name); + VisualShader::Type get_current_shader_type() const; + void _add_input_port(int p_node, int p_port, int p_port_type, const String &p_name); void _remove_input_port(int p_node, int p_port); void _change_input_port_type(int p_type, int p_node, int p_port); |
