diff options
Diffstat (limited to 'servers/rendering/shader_language.h')
-rw-r--r-- | servers/rendering/shader_language.h | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/servers/rendering/shader_language.h b/servers/rendering/shader_language.h index c02d6c47ec..7908658028 100644 --- a/servers/rendering/shader_language.h +++ b/servers/rendering/shader_language.h @@ -409,6 +409,7 @@ public: StringName name; StringName struct_name; bool is_const = false; + bool is_local = false; virtual DataType get_datatype() const override { return datatype_cache; } virtual String get_datatype_name() const override { return String(struct_name); } @@ -444,6 +445,7 @@ public: Node *assign_expression = nullptr; bool is_const = false; int array_size = 0; + bool is_local = false; virtual DataType get_datatype() const override { return datatype_cache; } virtual String get_datatype_name() const override { return String(struct_name); } @@ -690,8 +692,10 @@ public: int order = 0; int texture_order = 0; + int texture_binding = 0; DataType type = TYPE_VOID; DataPrecision precision = PRECISION_DEFAULT; + int array_size = 0; Vector<ConstantNode::Value> default_value; Scope scope = SCOPE_LOCAL; Hint hint = HINT_NONE; @@ -772,8 +776,9 @@ public: static DataType get_scalar_type(DataType p_type); static int get_cardinality(DataType p_type); static bool is_scalar_type(DataType p_type); + static bool is_float_type(DataType p_type); static bool is_sampler_type(DataType p_type); - static Variant constant_value_to_variant(const Vector<ShaderLanguage::ConstantNode::Value> &p_value, DataType p_type, ShaderLanguage::ShaderNode::Uniform::Hint p_hint = ShaderLanguage::ShaderNode::Uniform::HINT_NONE); + static Variant constant_value_to_variant(const Vector<ShaderLanguage::ConstantNode::Value> &p_value, DataType p_type, int p_array_size, ShaderLanguage::ShaderNode::Uniform::Hint p_hint = ShaderLanguage::ShaderNode::Uniform::HINT_NONE); static PropertyInfo uniform_to_property_info(const ShaderNode::Uniform &p_uniform); static uint32_t get_type_size(DataType p_type); @@ -939,6 +944,7 @@ private: const char *name; DataType rettype; const DataType args[MAX_ARGS]; + const char *args_names[MAX_ARGS]; SubClassTag tag; bool high_end; }; |