Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'source/blender/nodes/texture/nodes/node_texture_curves.c')
-rw-r--r--source/blender/nodes/texture/nodes/node_texture_curves.c30
1 files changed, 14 insertions, 16 deletions
diff --git a/source/blender/nodes/texture/nodes/node_texture_curves.c b/source/blender/nodes/texture/nodes/node_texture_curves.c
index 5980f938938..94235eae93c 100644
--- a/source/blender/nodes/texture/nodes/node_texture_curves.c
+++ b/source/blender/nodes/texture/nodes/node_texture_curves.c
@@ -54,32 +54,31 @@ static void time_colorfn(float *out, TexParams *p, bNode *node, bNodeStack **UNU
out[0] = CLAMPIS(fac, 0.0f, 1.0f);
}
-static void time_exec(void *data, bNode *node, bNodeStack **in, bNodeStack **out)
+static void time_exec(void *data, int UNUSED(thread), bNode *node, bNodeExecData *execdata, bNodeStack **in, bNodeStack **out)
{
- tex_output(node, in, out[0], &time_colorfn, data);
+ tex_output(node, execdata, in, out[0], &time_colorfn, data);
}
-static void time_init(bNodeTree *UNUSED(ntree), bNode *node, bNodeTemplate *UNUSED(ntemp))
+static void time_init(bNodeTree *UNUSED(ntree), bNode *node)
{
node->custom1= 1;
node->custom2= 250;
node->storage= curvemapping_add(1, 0.0f, 0.0f, 1.0f, 1.0f);
}
-void register_node_type_tex_curve_time(bNodeTreeType *ttype)
+void register_node_type_tex_curve_time()
{
static bNodeType ntype;
- node_type_base(ttype, &ntype, TEX_NODE_CURVE_TIME, "Time", NODE_CLASS_INPUT, NODE_OPTIONS);
+ tex_node_type_base(&ntype, TEX_NODE_CURVE_TIME, "Time", NODE_CLASS_INPUT, NODE_OPTIONS);
node_type_socket_templates(&ntype, NULL, time_outputs);
node_type_size(&ntype, 140, 100, 320);
node_type_init(&ntype, time_init);
node_type_storage(&ntype, "CurveMapping", node_free_curves, node_copy_curves);
- node_type_exec(&ntype, time_exec);
- node_type_exec_new(&ntype, node_initexec_curves, NULL, NULL); /* only for its initexec func */
+ node_type_exec(&ntype, node_initexec_curves, NULL, time_exec);
- nodeRegisterType(ttype, &ntype);
+ nodeRegisterType(&ntype);
}
/* **************** CURVE RGB ******************** */
@@ -102,27 +101,26 @@ static void rgb_colorfn(float *out, TexParams *p, bNode *node, bNodeStack **in,
out[3] = cin[3];
}
-static void rgb_exec(void *data, bNode *node, bNodeStack **in, bNodeStack **out)
+static void rgb_exec(void *data, int UNUSED(thread), bNode *node, bNodeExecData *execdata, bNodeStack **in, bNodeStack **out)
{
- tex_output(node, in, out[0], &rgb_colorfn, data);
+ tex_output(node, execdata, in, out[0], &rgb_colorfn, data);
}
-static void rgb_init(bNodeTree *UNUSED(ntree), bNode *node, bNodeTemplate *UNUSED(ntemp))
+static void rgb_init(bNodeTree *UNUSED(ntree), bNode *node)
{
node->storage= curvemapping_add(4, 0.0f, 0.0f, 1.0f, 1.0f);
}
-void register_node_type_tex_curve_rgb(bNodeTreeType *ttype)
+void register_node_type_tex_curve_rgb()
{
static bNodeType ntype;
- node_type_base(ttype, &ntype, TEX_NODE_CURVE_RGB, "RGB Curves", NODE_CLASS_OP_COLOR, NODE_OPTIONS);
+ tex_node_type_base(&ntype, TEX_NODE_CURVE_RGB, "RGB Curves", NODE_CLASS_OP_COLOR, NODE_OPTIONS);
node_type_socket_templates(&ntype, rgb_inputs, rgb_outputs);
node_type_size(&ntype, 200, 140, 320);
node_type_init(&ntype, rgb_init);
node_type_storage(&ntype, "CurveMapping", node_free_curves, node_copy_curves);
- node_type_exec(&ntype, rgb_exec);
- node_type_exec_new(&ntype, node_initexec_curves, NULL, NULL); /* only for its initexec func */
+ node_type_exec(&ntype, node_initexec_curves, NULL, rgb_exec);
- nodeRegisterType(ttype, &ntype);
+ nodeRegisterType(&ntype);
}