summaryrefslogtreecommitdiffstats
path: root/scene/resources/shader_graph.h
diff options
context:
space:
mode:
authorJuan Linietsky <juan@okamstudio.com>2015-01-19 02:39:58 -0300
committerJuan Linietsky <juan@okamstudio.com>2015-01-19 02:39:58 -0300
commita0511ed59a0e03232bf3abb49b3c916591453aef (patch)
tree1911b8cf77de024c526757ef0a6aff973b988397 /scene/resources/shader_graph.h
parente0c0aef615e8c8dac370fe745972190a077dc0cc (diff)
downloadredot-engine-a0511ed59a0e03232bf3abb49b3c916591453aef.tar.gz
Color Ramp and Curve Map added to visual shader editing.
Added Color Ramp and Curve Map to shader nodes. Fixed an issue that crashed Godot Editor right when opened.
Diffstat (limited to 'scene/resources/shader_graph.h')
-rw-r--r--scene/resources/shader_graph.h8
1 files changed, 8 insertions, 0 deletions
diff --git a/scene/resources/shader_graph.h b/scene/resources/shader_graph.h
index 88818f5615..ff2ca68335 100644
--- a/scene/resources/shader_graph.h
+++ b/scene/resources/shader_graph.h
@@ -175,6 +175,7 @@ private:
void _update_shader();
void _request_update();
+ void _plot_curve(const Vector2& p_a,const Vector2& p_b,const Vector2& p_c,const Vector2& p_d,uint8_t* p_heights,bool *p_useds);
void _add_node_code(ShaderType p_type,Node *p_node,const Vector<String>& p_inputs,String& code);
Array _get_node_list(ShaderType p_type) const;
@@ -316,6 +317,13 @@ public:
void vec_func_node_set_function(ShaderType p_which,int p_id,VecFunc p_func);
VecFunc vec_func_node_get_function(ShaderType p_which,int p_id) const;
+ void color_ramp_node_set_ramp(ShaderType p_which,int p_id,const DVector<Color>& p_colors, const DVector<real_t>& p_offsets);
+ DVector<Color> color_ramp_node_get_colors(ShaderType p_which,int p_id) const;
+ DVector<real_t> color_ramp_node_get_offsets(ShaderType p_which,int p_id) const;
+
+ void curve_map_node_set_points(ShaderType p_which, int p_id, const DVector<Vector2>& p_points);
+ DVector<Vector2> curve_map_node_get_points(ShaderType p_which,int p_id) const;
+
void input_node_set_name(ShaderType p_which,int p_id,const String& p_name);
String input_node_get_name(ShaderType p_which,int p_id);