summaryrefslogtreecommitdiff
path: root/scene/resources/shader_graph.h
diff options
context:
space:
mode:
Diffstat (limited to 'scene/resources/shader_graph.h')
-rw-r--r--scene/resources/shader_graph.h12
1 files changed, 9 insertions, 3 deletions
diff --git a/scene/resources/shader_graph.h b/scene/resources/shader_graph.h
index c73895db8a..55d09b4c38 100644
--- a/scene/resources/shader_graph.h
+++ b/scene/resources/shader_graph.h
@@ -115,7 +115,7 @@ public:
private:
- String _find_unique_name(ShaderType p_which, const String& p_base);
+ String _find_unique_name(const String& p_base);
struct SourceSlot {
@@ -151,6 +151,7 @@ private:
ShaderType shader_type;
const char *name;
const char *variable;
+ const char *postfix;
SlotType slot_type;
SlotDir dir;
};
@@ -175,6 +176,9 @@ private:
Array _get_node_list(ShaderType p_type) const;
Array _get_connections(ShaderType p_type) const;
+
+ void _set_data(const Dictionary& p_data);
+ Dictionary _get_data() const;
protected:
static void _bind_methods();
@@ -263,9 +267,8 @@ public:
RGB_MAX_OP
};
- void rgb_op_node_set_op(ShaderType p_which,float p_id,RGBOp p_op,float p_c);
+ void rgb_op_node_set_op(ShaderType p_which,float p_id,RGBOp p_op);
RGBOp rgb_op_node_get_op(ShaderType p_which,float p_id) const;
- float rgb_op_node_get_c(ShaderType p_which,float p_id) const;
void xform_vec_mult_node_set_no_translation(ShaderType p_which,int p_id,bool p_no_translation);
bool xform_vec_mult_node_get_no_translation(ShaderType p_which,int p_id) const;
@@ -345,6 +348,8 @@ public:
Variant node_get_state(ShaderType p_type, int p_node) const;
void node_set_state(ShaderType p_type, int p_id, const Variant& p_state);
+ GraphError get_graph_error(ShaderType p_type) const;
+
static int get_type_input_count(NodeType p_type);
static int get_type_output_count(NodeType p_type);
static SlotType get_type_input_type(NodeType p_type,int p_idx);
@@ -384,6 +389,7 @@ VARIANT_ENUM_CAST( ShaderGraph::VecScalarOp );
VARIANT_ENUM_CAST( ShaderGraph::RGBOp );
VARIANT_ENUM_CAST( ShaderGraph::ScalarFunc );
VARIANT_ENUM_CAST( ShaderGraph::VecFunc );
+VARIANT_ENUM_CAST( ShaderGraph::GraphError );
class MaterialShaderGraph : public ShaderGraph {