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
path: root/source
diff options
context:
space:
mode:
authorNathan Letwory <nathan@letworyinteractive.com>2007-04-04 17:58:12 +0400
committerNathan Letwory <nathan@letworyinteractive.com>2007-04-04 17:58:12 +0400
commitfb0f61c0b09aedaf536369becdc9e9e77609275f (patch)
treee48cfe75de05619b5de5cc5c04ffaec7597629e4 /source
parentafdd54fa3720c267f30e48ed45c449d80449bac0 (diff)
=== Node editor ===
* refactor copying and freeing of node->storage by handlerizing them. - freestoragefunc - copystoragefunc - node_util.c/h have generic handlers for these.
Diffstat (limited to 'source')
-rw-r--r--source/blender/blenkernel/BKE_node.h11
-rw-r--r--source/blender/blenkernel/intern/node.c52
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_alphaOver.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_blur.c23
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_channelMatte.c23
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_chromaMatte.c23
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_colorSpill.c25
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_composite.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_curves.c21
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_defocus.c9
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_diffMatte.c23
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_dilate.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_displace.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_filter.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_flip.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_hueSatVal.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_idMask.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_image.c46
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_lummaMatte.c23
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_mapUV.c5
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_mapValue.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_math.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_mixrgb.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_normal.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_outputFile.c5
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_rgb.c5
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_rotate.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_scale.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_sepcombHSVA.c30
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_sepcombRGBA.c14
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_sepcombYCCA.c32
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_sepcombYUVA.c30
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_setalpha.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_splitViewer.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_texture.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_translate.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_valToRgb.c13
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_value.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_vecBlur.c10
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_viewer.c7
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_zcombine.c7
-rw-r--r--source/blender/nodes/intern/CMP_util.h2
-rw-r--r--source/blender/nodes/intern/SHD_nodes/SHD_camera.c7
-rw-r--r--source/blender/nodes/intern/SHD_nodes/SHD_curves.c12
-rw-r--r--source/blender/nodes/intern/SHD_nodes/SHD_geom.c7
-rw-r--r--source/blender/nodes/intern/SHD_nodes/SHD_mapping.c7
-rw-r--r--source/blender/nodes/intern/SHD_nodes/SHD_material.c7
-rw-r--r--source/blender/nodes/intern/SHD_nodes/SHD_math.c23
-rw-r--r--source/blender/nodes/intern/SHD_nodes/SHD_mixRgb.c7
-rw-r--r--source/blender/nodes/intern/SHD_nodes/SHD_normal.c7
-rw-r--r--source/blender/nodes/intern/SHD_nodes/SHD_output.c7
-rw-r--r--source/blender/nodes/intern/SHD_nodes/SHD_rgb.c7
-rw-r--r--source/blender/nodes/intern/SHD_nodes/SHD_squeeze.c23
-rw-r--r--source/blender/nodes/intern/SHD_nodes/SHD_texture.c7
-rw-r--r--source/blender/nodes/intern/SHD_nodes/SHD_valToRgb.c30
-rw-r--r--source/blender/nodes/intern/SHD_nodes/SHD_value.c7
-rw-r--r--source/blender/nodes/intern/SHD_nodes/SHD_vectMath.c7
-rw-r--r--source/blender/nodes/intern/SHD_util.h1
-rw-r--r--source/blender/nodes/intern/node_util.c52
-rw-r--r--source/blender/nodes/intern/node_util.h42
60 files changed, 549 insertions, 283 deletions
diff --git a/source/blender/blenkernel/BKE_node.h b/source/blender/blenkernel/BKE_node.h
index 63bdc08af82..cde75f2091f 100644
--- a/source/blender/blenkernel/BKE_node.h
+++ b/source/blender/blenkernel/BKE_node.h
@@ -78,10 +78,17 @@ typedef struct bNodeType {
void (*execfunc)(void *data, struct bNode *, struct bNodeStack **, struct bNodeStack **);
- /* after this line is set on startup of blender */
+ /* this line is set on startup of blender */
int (*butfunc)(struct uiBlock *, struct bNodeTree *, struct bNode *, struct rctf *);
- void (*initfunc)(struct bNode *);
+ void (*initfunc)(struct bNode *);
+ void (*freestoragefunc)(struct bNode *);
+ void (*copystoragefunc)(struct bNode *, struct bNode *);
+
+ /* for use with dynamic typedefs */
+ ID *id;
+ void *script; /* holds pointer to python script */
+ void *dict; /* holds pointer to python script dictionary (scope)*/
} bNodeType;
diff --git a/source/blender/blenkernel/intern/node.c b/source/blender/blenkernel/intern/node.c
index 8f954e5ecb4..1f4da92dc86 100644
--- a/source/blender/blenkernel/intern/node.c
+++ b/source/blender/blenkernel/intern/node.c
@@ -239,7 +239,7 @@ void ntreeVerifyTypes(bNodeTree *ntree)
/* ************** Group stuff ********** */
bNodeType node_group_typeinfo= {
- /* next,prev */ NULL, NULL,
+ /* next,prev */ NULL, NULL,
/* type code */ NODE_GROUP,
/* name */ "Group",
/* width+range */ 120, 60, 200,
@@ -248,8 +248,11 @@ bNodeType node_group_typeinfo= {
/* output sock */ NULL,
/* storage */ "",
/* execfunc */ NULL,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
/* tag internal sockets */
@@ -349,13 +352,13 @@ void ntreeMakeOwnType(bNodeTree *ngroup)
}
/* make own type struct */
- ngroup->owntype= MEM_mallocN(sizeof(bNodeType), "group type");
+ ngroup->owntype= MEM_callocN(sizeof(bNodeType), "group type");
*ngroup->owntype= node_group_typeinfo; /* copy data, for init */
/* input type arrays */
if(totin) {
bNodeSocketType *stype;
- bNodeSocketType *inputs= MEM_mallocN(sizeof(bNodeSocketType)*(totin+1), "bNodeSocketType");
+ bNodeSocketType *inputs= MEM_callocN(sizeof(bNodeSocketType)*(totin+1), "bNodeSocketType");
a= 0;
for(node= ngroup->nodes.first; node; node= node->next) {
@@ -380,7 +383,7 @@ void ntreeMakeOwnType(bNodeTree *ngroup)
/* output type arrays */
if(totout) {
bNodeSocketType *stype;
- bNodeSocketType *outputs= MEM_mallocN(sizeof(bNodeSocketType)*(totout+1), "bNodeSocketType");
+ bNodeSocketType *outputs= MEM_callocN(sizeof(bNodeSocketType)*(totout+1), "bNodeSocketType");
a= 0;
for(node= ngroup->nodes.first; node; node= node->next) {
@@ -817,23 +820,8 @@ bNode *nodeCopyNode(struct bNodeTree *ntree, struct bNode *node)
if(nnode->id)
nnode->id->us++;
- if(nnode->storage) {
- /* another candidate for handlerizing! */
- if(ntree->type==NTREE_SHADER) {
- if(node->type==SH_NODE_CURVE_VEC || node->type==SH_NODE_CURVE_RGB)
- nnode->storage= curvemapping_copy(node->storage);
- else
- nnode->storage= MEM_dupallocN(nnode->storage);
- }
- else if(ntree->type==NTREE_COMPOSIT) {
- if(ELEM3(node->type, CMP_NODE_TIME, CMP_NODE_CURVE_VEC, CMP_NODE_CURVE_RGB))
- nnode->storage= curvemapping_copy(node->storage);
- else
- nnode->storage= MEM_dupallocN(nnode->storage);
- }
- else
- nnode->storage= MEM_dupallocN(nnode->storage);
- }
+ if(node->typeinfo->copystoragefunc)
+ node->typeinfo->copystoragefunc(node, nnode);
node->new_node= nnode;
nnode->new_node= NULL;
@@ -1012,22 +1000,8 @@ void nodeFreeNode(bNodeTree *ntree, bNode *node)
MEM_freeN(node->preview->rect);
MEM_freeN(node->preview);
}
- if(node->storage) {
- /* could be handlerized at some point, now only 1 exception still */
- if(ntree->type==NTREE_SHADER) {
- if(node->type==SH_NODE_CURVE_VEC || node->type==SH_NODE_CURVE_RGB)
- curvemapping_free(node->storage);
- else
- MEM_freeN(node->storage);
- }
- else if(ntree->type==NTREE_COMPOSIT) {
- if(ELEM3(node->type, CMP_NODE_TIME, CMP_NODE_CURVE_VEC, CMP_NODE_CURVE_RGB))
- curvemapping_free(node->storage);
- else
- MEM_freeN(node->storage);
- }
- else
- MEM_freeN(node->storage);
+ if(node->typeinfo && node->typeinfo->freestoragefunc) {
+ node->typeinfo->freestoragefunc(node);
}
MEM_freeN(node);
}
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_alphaOver.c b/source/blender/nodes/intern/CMP_nodes/CMP_alphaOver.c
index 16ed447921a..aedaa036d67 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_alphaOver.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_alphaOver.c
@@ -117,8 +117,11 @@ bNodeType cmp_node_alphaover= {
/* output sock */ cmp_node_alphaover_out,
/* storage */ "",
/* execfunc */ node_composit_exec_alphaover,
- /* butfunc */ NULL,
- /*initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_blur.c b/source/blender/nodes/intern/CMP_nodes/CMP_blur.c
index 4b0a0774f6d..4d9f2e31f52 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_blur.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_blur.c
@@ -629,16 +629,19 @@ static void node_composit_init_blur(bNode* node)
bNodeType cmp_node_blur= {
/* *next,*prev */ NULL, NULL,
- /* type code */ CMP_NODE_BLUR,
- /* name */ "Blur",
- /* width+range */ 120, 80, 200,
- /* class+opts */ NODE_CLASS_OP_FILTER, NODE_OPTIONS,
- /* input sock */ cmp_node_blur_in,
- /* output sock */ cmp_node_blur_out,
- /* storage */ "NodeBlurData",
- /* execfunc */ node_composit_exec_blur,
- /* butfunc */ NULL,
- /*initfunc */ node_composit_init_blur
+ /* type code */ CMP_NODE_BLUR,
+ /* name */ "Blur",
+ /* width+range */ 120, 80, 200,
+ /* class+opts */ NODE_CLASS_OP_FILTER, NODE_OPTIONS,
+ /* input sock */ cmp_node_blur_in,
+ /* output sock */ cmp_node_blur_out,
+ /* storage */ "NodeBlurData",
+ /* execfunc */ node_composit_exec_blur,
+ /* butfunc */ NULL,
+ /* initfunc */ node_composit_init_blur,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_channelMatte.c b/source/blender/nodes/intern/CMP_nodes/CMP_channelMatte.c
index 0a833e52e35..d0cc4e5b88d 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_channelMatte.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_channelMatte.c
@@ -191,14 +191,17 @@ static void node_composit_init_channel_matte(bNode *node)
bNodeType cmp_node_channel_matte={
/* *next,*prev */ NULL, NULL,
- /* type code */ CMP_NODE_CHANNEL_MATTE,
- /* name */ "Channel Key",
- /* width+range */ 200, 80, 250,
- /* class+opts */ NODE_CLASS_MATTE, NODE_PREVIEW|NODE_OPTIONS,
- /* input sock */ cmp_node_channel_matte_in,
- /* output sock */ cmp_node_channel_matte_out,
- /* storage */ "NodeChroma",
- /* execfunc */ node_composit_exec_channel_matte,
- /* butfunc */ NULL,
- node_composit_init_channel_matte
+ /* type code */ CMP_NODE_CHANNEL_MATTE,
+ /* name */ "Channel Key",
+ /* width+range */ 200, 80, 250,
+ /* class+opts */ NODE_CLASS_MATTE, NODE_PREVIEW|NODE_OPTIONS,
+ /* input sock */ cmp_node_channel_matte_in,
+ /* output sock */ cmp_node_channel_matte_out,
+ /* storage */ "NodeChroma",
+ /* execfunc */ node_composit_exec_channel_matte,
+ /* butfunc */ NULL,
+ /* initfunc */ node_composit_init_channel_matte,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_chromaMatte.c b/source/blender/nodes/intern/CMP_nodes/CMP_chromaMatte.c
index e1eb4420066..d836a829696 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_chromaMatte.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_chromaMatte.c
@@ -174,16 +174,19 @@ static void node_composit_init_chroma_matte(bNode *node)
bNodeType cmp_node_chroma={
/* *next,*prev */ NULL, NULL,
- /* type code */ CMP_NODE_CHROMA,
- /* name */ "Chroma Key",
- /* width+range */ 200, 80, 300,
- /* class+opts */ NODE_CLASS_MATTE, NODE_PREVIEW|NODE_OPTIONS,
- /* input sock */ cmp_node_chroma_in,
- /* output sock */ cmp_node_chroma_out,
- /* storage */ "NodeChroma",
- /* execfunc */ node_composit_exec_chroma_matte,
- /* butfunc */ NULL,
- node_composit_init_chroma_matte
+ /* type code */ CMP_NODE_CHROMA,
+ /* name */ "Chroma Key",
+ /* width+range */ 200, 80, 300,
+ /* class+opts */ NODE_CLASS_MATTE, NODE_PREVIEW|NODE_OPTIONS,
+ /* input sock */ cmp_node_chroma_in,
+ /* output sock */ cmp_node_chroma_out,
+ /* storage */ "NodeChroma",
+ /* execfunc */ node_composit_exec_chroma_matte,
+ /* butfunc */ NULL,
+ /* initfunc */ node_composit_init_chroma_matte,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_colorSpill.c b/source/blender/nodes/intern/CMP_nodes/CMP_colorSpill.c
index 3c2054e400d..152180afc08 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_colorSpill.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_colorSpill.c
@@ -123,19 +123,22 @@ static void node_composit_init_color_spill(bNode *node)
c->fsize= 0.0f;
c->fstrength= 0.0f;
node->custom1= 2; /* green channel */
-};
+}
bNodeType cmp_node_color_spill={
/* *next,*prev */ NULL, NULL,
- /* type code */ CMP_NODE_COLOR_SPILL,
- /* name */ "Color Spill",
- /* width+range */ 140, 80, 200,
- /* class+opts */ NODE_CLASS_MATTE, NODE_OPTIONS,
- /* input sock */ cmp_node_color_spill_in,
- /* output sock */ cmp_node_color_spill_out,
- /* storage */ "NodeChroma",
- /* execfunc */ node_composit_exec_color_spill,
- /* butfunc */ NULL,
- node_composit_init_color_spill
+ /* type code */ CMP_NODE_COLOR_SPILL,
+ /* name */ "Color Spill",
+ /* width+range */ 140, 80, 200,
+ /* class+opts */ NODE_CLASS_MATTE, NODE_OPTIONS,
+ /* input sock */ cmp_node_color_spill_in,
+ /* output sock */ cmp_node_color_spill_out,
+ /* storage */ "NodeChroma",
+ /* execfunc */ node_composit_exec_color_spill,
+ /* butfunc */ NULL,
+ /* initfunc */ node_composit_init_color_spill,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_composite.c b/source/blender/nodes/intern/CMP_nodes/CMP_composite.c
index 317715278de..89bd8e43694 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_composite.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_composite.c
@@ -97,6 +97,9 @@ bNodeType cmp_node_composite= {
/* output sock */ NULL,
/* storage */ "",
/* execfunc */ node_composit_exec_composite,
- /* butfunc */ NULL,
- /*initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_curves.c b/source/blender/nodes/intern/CMP_nodes/CMP_curves.c
index 7f0310de9aa..754d016fb25 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_curves.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_curves.c
@@ -68,8 +68,11 @@ bNodeType cmp_node_curve_time= {
/* output sock */ cmp_node_time_out,
/* storage */ "CurveMapping",
/* execfunc */ node_composit_exec_curves_time,
- /* butfunc */ NULL,
- /* initfunc */ node_composit_init_curves_time
+ /* butfunc */ NULL,
+ /* initfunc */ node_composit_init_curves_time,
+ /* freestoragefunc */ node_free_curves,
+ /* copystoragefunc */ node_copy_curves,
+ /* id */ NULL
};
@@ -108,8 +111,11 @@ bNodeType cmp_node_curve_vec= {
/* output sock */ cmp_node_curve_vec_out,
/* storage */ "CurveMapping",
/* execfunc */ node_composit_exec_curve_vec,
- /* butfunc */ NULL,
- /* initfunc */ node_composit_init_curve_vec
+ /* butfunc */ NULL,
+ /* initfunc */ node_composit_init_curve_vec,
+ /* freestoragefunc */ node_free_curves,
+ /* copystoragefunc */ node_copy_curves,
+ /* id */ NULL
};
@@ -191,7 +197,10 @@ bNodeType cmp_node_curve_rgb= {
/* output sock */ cmp_node_curve_rgb_out,
/* storage */ "CurveMapping",
/* execfunc */ node_composit_exec_curve_rgb,
- /* butfunc */ NULL,
- /* initfunc */ node_composit_init_curve_rgb
+ /* butfunc */ NULL,
+ /* initfunc */ node_composit_init_curve_rgb,
+ /* freestoragefunc */ node_free_curves,
+ /* copystoragefunc */ node_copy_curves,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_defocus.c b/source/blender/nodes/intern/CMP_nodes/CMP_defocus.c
index edefd0fbadf..2573639b84f 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_defocus.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_defocus.c
@@ -811,7 +811,7 @@ static void node_composit_init_defocus(bNode* node)
nbd->scale = 1.f;
nbd->no_zbuf = 1;
node->storage = nbd;
-};
+}
bNodeType cmp_node_defocus = {
/* *next,*prev */ NULL, NULL,
@@ -823,8 +823,11 @@ bNodeType cmp_node_defocus = {
/* output sock */ cmp_node_defocus_out,
/* storage */ "NodeDefocus",
/* execfunc */ node_composit_exec_defocus,
- /* butfunc */ NULL,
- /* initfunc */ node_composit_init_defocus
+ /* butfunc */ NULL,
+ /* initfunc */ node_composit_init_defocus,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_diffMatte.c b/source/blender/nodes/intern/CMP_nodes/CMP_diffMatte.c
index 1af5b943dbc..ade2111f246 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_diffMatte.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_diffMatte.c
@@ -199,16 +199,19 @@ static void node_composit_init_diff_matte(bNode *node)
bNodeType cmp_node_diff_matte={
/* *next,*prev */ NULL, NULL,
- /* type code */ CMP_NODE_DIFF_MATTE,
- /* name */ "Difference Key",
- /* width+range */ 200, 80, 250,
- /* class+opts */ NODE_CLASS_MATTE, NODE_PREVIEW|NODE_OPTIONS,
- /* input sock */ cmp_node_diff_matte_in,
- /* output sock */ cmp_node_diff_matte_out,
- /* storage */ "NodeChroma",
- /* execfunc */ node_composit_exec_diff_matte,
- /* butfunc */ NULL,
- /* initfunc */ node_composit_init_diff_matte
+ /* type code */ CMP_NODE_DIFF_MATTE,
+ /* name */ "Difference Key",
+ /* width+range */ 200, 80, 250,
+ /* class+opts */ NODE_CLASS_MATTE, NODE_PREVIEW|NODE_OPTIONS,
+ /* input sock */ cmp_node_diff_matte_in,
+ /* output sock */ cmp_node_diff_matte_out,
+ /* storage */ "NodeChroma",
+ /* execfunc */ node_composit_exec_diff_matte,
+ /* butfunc */ NULL,
+ /* initfunc */ node_composit_init_diff_matte,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_dilate.c b/source/blender/nodes/intern/CMP_nodes/CMP_dilate.c
index bb79a4c8f0d..81430436227 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_dilate.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_dilate.c
@@ -153,8 +153,11 @@ bNodeType cmp_node_dilateerode= {
/* output sock */ cmp_node_dilateerode_out,
/* storage */ "",
/* execfunc */ node_composit_exec_dilateerode,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_displace.c b/source/blender/nodes/intern/CMP_nodes/CMP_displace.c
index a87394815a2..0ec15d9eb77 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_displace.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_displace.c
@@ -154,7 +154,10 @@ bNodeType cmp_node_displace= {
/* output sock */ cmp_node_displace_out,
/* storage */ "",
/* execfunc */ node_composit_exec_displace,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_filter.c b/source/blender/nodes/intern/CMP_nodes/CMP_filter.c
index 7f578c56927..46a9d747ac1 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_filter.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_filter.c
@@ -224,8 +224,11 @@ bNodeType cmp_node_filter= {
/* output sock */ cmp_node_filter_out,
/* storage */ "",
/* execfunc */ node_composit_exec_filter,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_flip.c b/source/blender/nodes/intern/CMP_nodes/CMP_flip.c
index f44b890148c..cd6fdf70ac4 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_flip.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_flip.c
@@ -95,8 +95,11 @@ bNodeType cmp_node_flip= {
/* output sock */ cmp_node_flip_out,
/* storage */ "",
/* execfunc */ node_composit_exec_flip,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_hueSatVal.c b/source/blender/nodes/intern/CMP_nodes/CMP_hueSatVal.c
index d4258bdeeb3..eeddb4ce756 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_hueSatVal.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_hueSatVal.c
@@ -111,8 +111,11 @@ bNodeType cmp_node_hue_sat= {
/* output sock */ cmp_node_hue_sat_out,
/* storage */ "NodeHueSat",
/* execfunc */ node_composit_exec_hue_sat,
- /* butfunc */ NULL,
- /* initfunc */ node_composit_init_hue_sat
+ /* butfunc */ NULL,
+ /* initfunc */ node_composit_init_hue_sat,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_idMask.c b/source/blender/nodes/intern/CMP_nodes/CMP_idMask.c
index d4e6b065ba8..abb9fa98d97 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_idMask.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_idMask.c
@@ -94,8 +94,11 @@ bNodeType cmp_node_idmask= {
/* output sock */ cmp_node_idmask_out,
/* storage */ "",
/* execfunc */ node_composit_exec_idmask,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_image.c b/source/blender/nodes/intern/CMP_nodes/CMP_image.c
index 29845d8835c..20308e968d3 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_image.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_image.c
@@ -212,16 +212,19 @@ static void node_composit_init_image(bNode* node)
bNodeType cmp_node_image= {
/* *next,*prev */ NULL, NULL,
- /* type code */ CMP_NODE_IMAGE,
- /* name */ "Image",
- /* width+range */ 120, 80, 300,
- /* class+opts */ NODE_CLASS_INPUT, NODE_PREVIEW|NODE_OPTIONS,
- /* input sock */ NULL,
- /* output sock */ cmp_node_rlayers_out,
- /* storage */ "ImageUser",
- /* execfunc */ node_composit_exec_image,
- /* butfunc */ NULL,
- /* initfunc */ node_composit_init_image
+ /* type code */ CMP_NODE_IMAGE,
+ /* name */ "Image",
+ /* width+range */ 120, 80, 300,
+ /* class+opts */ NODE_CLASS_INPUT, NODE_PREVIEW|NODE_OPTIONS,
+ /* input sock */ NULL,
+ /* output sock */ cmp_node_rlayers_out,
+ /* storage */ "ImageUser",
+ /* execfunc */ node_composit_exec_image,
+ /* butfunc */ NULL,
+ /* initfunc */ node_composit_init_image,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
/* **************** RENDER RESULT ******************** */
@@ -330,16 +333,19 @@ static void node_composit_exec_rlayers(void *data, bNode *node, bNodeStack **in,
bNodeType cmp_node_rlayers= {
/* *next,*prev */ NULL, NULL,
- /* type code */ CMP_NODE_R_LAYERS,
- /* name */ "Render Layers",
- /* width+range */ 150, 100, 300,
- /* class+opts */ NODE_CLASS_INPUT, NODE_PREVIEW|NODE_OPTIONS,
- /* input sock */ NULL,
- /* output sock */ cmp_node_rlayers_out,
- /* storage */ "",
- /* execfunc */ node_composit_exec_rlayers,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* type code */ CMP_NODE_R_LAYERS,
+ /* name */ "Render Layers",
+ /* width+range */ 150, 100, 300,
+ /* class+opts */ NODE_CLASS_INPUT, NODE_PREVIEW|NODE_OPTIONS,
+ /* input sock */ NULL,
+ /* output sock */ cmp_node_rlayers_out,
+ /* storage */ "",
+ /* execfunc */ node_composit_exec_rlayers,
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_lummaMatte.c b/source/blender/nodes/intern/CMP_nodes/CMP_lummaMatte.c
index d909e47538f..973d74d71ff 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_lummaMatte.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_lummaMatte.c
@@ -105,15 +105,18 @@ static void node_composit_init_luma_matte(bNode *node)
bNodeType cmp_node_luma_matte={
/* *next,*prev */ NULL, NULL,
- /* type code */ CMP_NODE_LUMA_MATTE,
- /* name */ "Luminance Key",
- /* width+range */ 200, 80, 250,
- /* class+opts */ NODE_CLASS_MATTE, NODE_PREVIEW|NODE_OPTIONS,
- /* input sock */ cmp_node_luma_matte_in,
- /* output sock */ cmp_node_luma_matte_out,
- /* storage */ "NodeChroma",
- /* execfunc */ node_composit_exec_luma_matte,
- /* butfunc */ NULL,
- /* initfunc */ node_composit_init_luma_matte
+ /* type code */ CMP_NODE_LUMA_MATTE,
+ /* name */ "Luminance Key",
+ /* width+range */ 200, 80, 250,
+ /* class+opts */ NODE_CLASS_MATTE, NODE_PREVIEW|NODE_OPTIONS,
+ /* input sock */ cmp_node_luma_matte_in,
+ /* output sock */ cmp_node_luma_matte_out,
+ /* storage */ "NodeChroma",
+ /* execfunc */ node_composit_exec_luma_matte,
+ /* butfunc */ NULL,
+ /* initfunc */ node_composit_init_luma_matte,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_mapUV.c b/source/blender/nodes/intern/CMP_nodes/CMP_mapUV.c
index 4c7b4402ba7..ae3e5875aae 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_mapUV.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_mapUV.c
@@ -140,7 +140,10 @@ bNodeType cmp_node_mapuv= {
/* storage */ "",
/* execfunc */ node_composit_exec_mapuv,
/* butfunc */ NULL,
- /* initfunc */ NULL
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_mapValue.c b/source/blender/nodes/intern/CMP_nodes/CMP_mapValue.c
index 97faa9488d1..8f0f9621c2e 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_mapValue.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_mapValue.c
@@ -89,8 +89,11 @@ bNodeType cmp_node_map_value= {
/* output sock */ cmp_node_map_value_out,
/* storage */ "TexMapping",
/* execfunc */ node_composit_exec_map_value,
- /* butfunc */ NULL,
- /* initfunc */ node_composit_init_map_value
+ /* butfunc */ NULL,
+ /* initfunc */ node_composit_init_map_value,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_math.c b/source/blender/nodes/intern/CMP_nodes/CMP_math.c
index 7515dff166e..27d7da16a59 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_math.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_math.c
@@ -168,8 +168,11 @@ bNodeType cmp_node_math= {
/* output sock */ cmp_node_math_out,
/* storage */ "",
/* execfunc */ node_composit_exec_math,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_mixrgb.c b/source/blender/nodes/intern/CMP_nodes/CMP_mixrgb.c
index 6a0cd63d1f1..790b24a105a 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_mixrgb.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_mixrgb.c
@@ -87,7 +87,10 @@ bNodeType cmp_node_mix_rgb= {
/* output sock */ cmp_node_mix_rgb_out,
/* storage */ "",
/* execfunc */ node_composit_exec_mix_rgb,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_normal.c b/source/blender/nodes/intern/CMP_nodes/CMP_normal.c
index d1b3aa5f37f..5219b224c6c 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_normal.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_normal.c
@@ -87,8 +87,11 @@ bNodeType cmp_node_normal= {
/* output sock */ cmp_node_normal_out,
/* storage */ "",
/* execfunc */ node_composit_exec_normal,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_outputFile.c b/source/blender/nodes/intern/CMP_nodes/CMP_outputFile.c
index 94b6772cf41..722b00d57a9 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_outputFile.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_outputFile.c
@@ -102,7 +102,10 @@ bNodeType cmp_node_output_file= {
/* storage */ "NodeImageFile",
/* execfunc */ node_composit_exec_output_file,
/* butfunc */ NULL,
- /* initfunc */ node_composit_init_output_file
+ /* initfunc */ node_composit_init_output_file,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_rgb.c b/source/blender/nodes/intern/CMP_nodes/CMP_rgb.c
index 1c690ef0113..ae2678dc5f0 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_rgb.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_rgb.c
@@ -54,7 +54,10 @@ bNodeType cmp_node_rgb= {
/* storage */ "",
/* execfunc */ node_composit_exec_rgb,
/* butfunc */ NULL,
- /* initfunc */ NULL
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_rotate.c b/source/blender/nodes/intern/CMP_nodes/CMP_rotate.c
index c09fe56b28f..d32c2ccd9e7 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_rotate.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_rotate.c
@@ -142,6 +142,9 @@ bNodeType cmp_node_rotate= {
/* output sock */ cmp_node_rotate_out,
/* storage */ "",
/* execfunc */ node_composit_exec_rotate,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_scale.c b/source/blender/nodes/intern/CMP_nodes/CMP_scale.c
index 244a5d0685c..a8477f4264e 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_scale.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_scale.c
@@ -111,8 +111,11 @@ bNodeType cmp_node_scale= {
/* output sock */ cmp_node_scale_out,
/* storage */ "",
/* execfunc */ node_composit_exec_scale,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_sepcombHSVA.c b/source/blender/nodes/intern/CMP_nodes/CMP_sepcombHSVA.c
index 50eedcaabe4..e7598726555 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_sepcombHSVA.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_sepcombHSVA.c
@@ -106,8 +106,11 @@ bNodeType cmp_node_sephsva= {
/* output sock */ cmp_node_sephsva_out,
/* storage */ "",
/* execfunc */ node_composit_exec_sephsva,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
@@ -170,16 +173,19 @@ static void node_composit_exec_combhsva(void *data, bNode *node, bNodeStack **in
bNodeType cmp_node_combhsva= {
/* *next,*prev */ NULL, NULL,
- /* type code */ CMP_NODE_COMBHSVA,
- /* name */ "Combine HSVA",
- /* width+range */ 80, 40, 140,
- /* class+opts */ NODE_CLASS_CONVERTOR, NODE_OPTIONS,
- /* input sock */ cmp_node_combhsva_in,
- /* output sock */ cmp_node_combhsva_out,
- /* storage */ "",
- /* execfunc */ node_composit_exec_combhsva,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* type code */ CMP_NODE_COMBHSVA,
+ /* name */ "Combine HSVA",
+ /* width+range */ 80, 40, 140,
+ /* class+opts */ NODE_CLASS_CONVERTOR, NODE_OPTIONS,
+ /* input sock */ cmp_node_combhsva_in,
+ /* output sock */ cmp_node_combhsva_out,
+ /* storage */ "",
+ /* execfunc */ node_composit_exec_combhsva,
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_sepcombRGBA.c b/source/blender/nodes/intern/CMP_nodes/CMP_sepcombRGBA.c
index 50643cd9c43..08546c15450 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_sepcombRGBA.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_sepcombRGBA.c
@@ -84,8 +84,11 @@ bNodeType cmp_node_seprgba= {
/* output sock */ cmp_node_seprgba_out,
/* storage */ "",
/* execfunc */ node_composit_exec_seprgba,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
@@ -154,8 +157,11 @@ bNodeType cmp_node_combrgba= {
/* output sock */ cmp_node_combrgba_out,
/* storage */ "",
/* execfunc */ node_composit_exec_combrgba,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_sepcombYCCA.c b/source/blender/nodes/intern/CMP_nodes/CMP_sepcombYCCA.c
index 342a8e44114..6802fab0bfc 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_sepcombYCCA.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_sepcombYCCA.c
@@ -96,17 +96,20 @@ static void node_composit_exec_sepycca(void *data, bNode *node, bNodeStack **in,
}
bNodeType cmp_node_sepycca= {
- /* *next,*prev */ NULL, NULL,
- /* type code */ CMP_NODE_SEPYCCA,
- /* name */ "Separate YCbCrA",
- /* width+range */ 80, 40, 140,
- /* class+opts */ NODE_CLASS_CONVERTOR, 0,
- /* input sock */ cmp_node_sepycca_in,
- /* output sock */ cmp_node_sepycca_out,
- /* storage */ "",
- /* execfunc */ node_composit_exec_sepycca,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* *next,*prev */ NULL, NULL,
+ /* type code */ CMP_NODE_SEPYCCA,
+ /* name */ "Separate YCbCrA",
+ /* width+range */ 80, 40, 140,
+ /* class+opts */ NODE_CLASS_CONVERTOR, 0,
+ /* input sock */ cmp_node_sepycca_in,
+ /* output sock */ cmp_node_sepycca_out,
+ /* storage */ "",
+ /* execfunc */ node_composit_exec_sepycca,
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
@@ -184,8 +187,11 @@ bNodeType cmp_node_combycca= {
/* output sock */ cmp_node_combycca_out,
/* storage */ "",
/* execfunc */ node_composit_exec_combycca,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_sepcombYUVA.c b/source/blender/nodes/intern/CMP_nodes/CMP_sepcombYUVA.c
index ec171b63811..08027c5bc04 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_sepcombYUVA.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_sepcombYUVA.c
@@ -98,16 +98,19 @@ static void node_composit_exec_sepyuva(void *data, bNode *node, bNodeStack **in,
bNodeType cmp_node_sepyuva= {
/* *next,*prev */ NULL, NULL,
- /* type code */ CMP_NODE_SEPYUVA,
- /* name */ "Separate YUVA",
- /* width+range */ 80, 40, 140,
- /* class+opts */ NODE_CLASS_CONVERTOR, 0,
- /* input sock */ cmp_node_sepyuva_in,
- /* output sock */ cmp_node_sepyuva_out,
- /* storage */ "",
- /* execfunc */ node_composit_exec_sepyuva,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* type code */ CMP_NODE_SEPYUVA,
+ /* name */ "Separate YUVA",
+ /* width+range */ 80, 40, 140,
+ /* class+opts */ NODE_CLASS_CONVERTOR, 0,
+ /* input sock */ cmp_node_sepyuva_in,
+ /* output sock */ cmp_node_sepyuva_out,
+ /* storage */ "",
+ /* execfunc */ node_composit_exec_sepyuva,
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
@@ -178,7 +181,10 @@ bNodeType cmp_node_combyuva= {
/* output sock */ cmp_node_combyuva_out,
/* storage */ "",
/* execfunc */ node_composit_exec_combyuva,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_setalpha.c b/source/blender/nodes/intern/CMP_nodes/CMP_setalpha.c
index 79619dafec5..d56baecb587 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_setalpha.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_setalpha.c
@@ -80,7 +80,10 @@ bNodeType cmp_node_setalpha= {
/* output sock */ cmp_node_setalpha_out,
/* storage */ "",
/* execfunc */ node_composit_exec_setalpha,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_splitViewer.c b/source/blender/nodes/intern/CMP_nodes/CMP_splitViewer.c
index 572ed53b0f7..8ce5a7caa04 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_splitViewer.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_splitViewer.c
@@ -152,8 +152,11 @@ bNodeType cmp_node_splitviewer= {
/* output sock */ NULL,
/* storage */ "ImageUser",
/* execfunc */ node_composit_exec_splitviewer,
- /* butfunc */ NULL,
- /* initfunc */ node_composit_init_splitviewer
+ /* butfunc */ NULL,
+ /* initfunc */ node_composit_init_splitviewer,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_texture.c b/source/blender/nodes/intern/CMP_nodes/CMP_texture.c
index eec7ea379fa..9bf9777ebe0 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_texture.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_texture.c
@@ -127,8 +127,11 @@ bNodeType cmp_node_texture= {
/* output sock */ cmp_node_texture_out,
/* storage */ "",
/* execfunc */ node_composit_exec_texture,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_translate.c b/source/blender/nodes/intern/CMP_nodes/CMP_translate.c
index 56d5c114eae..0b198a18b4e 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_translate.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_translate.c
@@ -66,7 +66,10 @@ bNodeType cmp_node_translate= {
/* output sock */ cmp_node_translate_out,
/* storage */ "",
/* execfunc */ node_composit_exec_translate,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_valToRgb.c b/source/blender/nodes/intern/CMP_nodes/CMP_valToRgb.c
index d35c347d0db..0d50cb6374d 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_valToRgb.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_valToRgb.c
@@ -90,8 +90,11 @@ bNodeType cmp_node_valtorgb= {
/* output sock */ cmp_node_valtorgb_out,
/* storage */ "ColorBand",
/* execfunc */ node_composit_exec_valtorgb,
- /* butfunc */ NULL,
- /* initfunc */ node_composit_init_valtorgb
+ /* butfunc */ NULL,
+ /* initfunc */ node_composit_init_valtorgb,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
@@ -144,8 +147,10 @@ bNodeType cmp_node_rgbtobw= {
/* output sock */ cmp_node_rgbtobw_out,
/* storage */ "",
/* execfunc */ node_composit_exec_rgbtobw,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_value.c b/source/blender/nodes/intern/CMP_nodes/CMP_value.c
index 8681fce6e1b..7430a373d23 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_value.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_value.c
@@ -52,7 +52,10 @@ bNodeType cmp_node_value= {
/* output sock */ cmp_node_value_out,
/* storage */ "",
/* execfunc */ node_composit_exec_value,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_vecBlur.c b/source/blender/nodes/intern/CMP_nodes/CMP_vecBlur.c
index b23d0d4548d..9e6c963126b 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_vecBlur.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_vecBlur.c
@@ -90,7 +90,6 @@ static void node_composit_init_vecblur(bNode* node)
nbd->fac= 1.0f;
};
-
/* custom1: itterations, custom2: maxspeed (0 = nolimit) */
bNodeType cmp_node_vecblur= {
/* next, prev */ NULL, NULL,
@@ -101,8 +100,11 @@ bNodeType cmp_node_vecblur= {
/* input sock */ cmp_node_vecblur_in,
/* output sock */ cmp_node_vecblur_out,
/* storage */ "NodeBlurData",
- /* execfunc */ node_composit_exec_vecblur,
- /* butfunc */ NULL,
- /* initfunc */ node_composit_init_vecblur
+ /* execfunc */ node_composit_exec_vecblur,
+ /* butfunc */ NULL,
+ /* initfunc */ node_composit_init_vecblur,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_viewer.c b/source/blender/nodes/intern/CMP_nodes/CMP_viewer.c
index aee1663d4e3..c9e95e768c1 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_viewer.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_viewer.c
@@ -134,8 +134,11 @@ bNodeType cmp_node_viewer= {
/* output sock */ NULL,
/* storage */ "ImageUser",
/* execfunc */ node_composit_exec_viewer,
- /* butfunc */ NULL,
- /* initfunc */ node_composit_init_viewer
+ /* butfunc */ NULL,
+ /* initfunc */ node_composit_init_viewer,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_zcombine.c b/source/blender/nodes/intern/CMP_nodes/CMP_zcombine.c
index bff839cad65..29cf8f34d54 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_zcombine.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_zcombine.c
@@ -146,7 +146,10 @@ bNodeType cmp_node_zcombine= {
/* output sock */ cmp_node_zcombine_out,
/* storage */ "",
/* execfunc */ node_composit_exec_zcombine,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/CMP_util.h b/source/blender/nodes/intern/CMP_util.h
index fd132ab7d49..515980bc563 100644
--- a/source/blender/nodes/intern/CMP_util.h
+++ b/source/blender/nodes/intern/CMP_util.h
@@ -62,7 +62,7 @@
#include "BKE_library.h"
#include "../CMP_node.h"
-
+#include "node_util.h"
#include "BIF_gl.h"
#include "BIF_glutil.h"
diff --git a/source/blender/nodes/intern/SHD_nodes/SHD_camera.c b/source/blender/nodes/intern/SHD_nodes/SHD_camera.c
index 9c7cab47cb6..63260ff91ed 100644
--- a/source/blender/nodes/intern/SHD_nodes/SHD_camera.c
+++ b/source/blender/nodes/intern/SHD_nodes/SHD_camera.c
@@ -59,7 +59,10 @@ bNodeType sh_node_camera= {
/* output sock */ sh_node_camera_out,
/* storage */ "node_camera",
/* execfunc */ node_shader_exec_camera,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/SHD_nodes/SHD_curves.c b/source/blender/nodes/intern/SHD_nodes/SHD_curves.c
index ec2af791001..b6f1f8d52cd 100644
--- a/source/blender/nodes/intern/SHD_nodes/SHD_curves.c
+++ b/source/blender/nodes/intern/SHD_nodes/SHD_curves.c
@@ -66,8 +66,11 @@ bNodeType sh_node_curve_vec= {
/* output sock */ sh_node_curve_vec_out,
/* storage */ "CurveMapping",
/* execfunc */ node_shader_exec_curve_vec,
- /* butfunc */ NULL,
- /* initfunc */ node_shader_init_curve_vec
+ /* butfunc */ NULL,
+ /* initfunc */ node_shader_init_curve_vec,
+ /* freestoragefunc */ node_free_curves,
+ /* copystoragefunc */ node_copy_curves,
+ /* id */ NULL
};
@@ -108,6 +111,9 @@ bNodeType sh_node_curve_rgb= {
/* storage */ "CurveMapping",
/* execfunc */ node_shader_exec_curve_rgb,
/* butfunc */ NULL,
- /* initfunc */ node_shader_init_curve_rgb
+ /* initfunc */ node_shader_init_curve_rgb,
+ /* freestoragefunc */ node_free_curves,
+ /* copystoragefunc */ node_copy_curves,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/SHD_nodes/SHD_geom.c b/source/blender/nodes/intern/SHD_nodes/SHD_geom.c
index 584ceb0dbbd..3875dead2b0 100644
--- a/source/blender/nodes/intern/SHD_nodes/SHD_geom.c
+++ b/source/blender/nodes/intern/SHD_nodes/SHD_geom.c
@@ -124,7 +124,10 @@ bNodeType sh_node_geom= {
/* output sock */ sh_node_geom_out,
/* storage */ "NodeGeometry",
/* execfunc */ node_shader_exec_geom,
- /* butfunc */ NULL,
- /* initfunc */ node_shader_init_geometry
+ /* butfunc */ NULL,
+ /* initfunc */ node_shader_init_geometry,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/SHD_nodes/SHD_mapping.c b/source/blender/nodes/intern/SHD_nodes/SHD_mapping.c
index a22159dcf16..589954c8f7b 100644
--- a/source/blender/nodes/intern/SHD_nodes/SHD_mapping.c
+++ b/source/blender/nodes/intern/SHD_nodes/SHD_mapping.c
@@ -79,8 +79,11 @@ bNodeType sh_node_mapping= {
/* output sock */ sh_node_mapping_out,
/* storage */ "TexMapping",
/* execfunc */ node_shader_exec_mapping,
- /* butfunc */ NULL,
- /* initfunc */ node_shader_init_mapping
+ /* butfunc */ NULL,
+ /* initfunc */ node_shader_init_mapping,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/SHD_nodes/SHD_material.c b/source/blender/nodes/intern/SHD_nodes/SHD_material.c
index 30452ca36cb..1dc18f97496 100644
--- a/source/blender/nodes/intern/SHD_nodes/SHD_material.c
+++ b/source/blender/nodes/intern/SHD_nodes/SHD_material.c
@@ -145,8 +145,11 @@ bNodeType sh_node_material= {
/* output sock */ sh_node_material_out,
/* storage */ "",
/* execfunc */ node_shader_exec_material,
- /* butfunc */ NULL,
- /* initfunc */ node_shader_init_material
+ /* butfunc */ NULL,
+ /* initfunc */ node_shader_init_material,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/SHD_nodes/SHD_math.c b/source/blender/nodes/intern/SHD_nodes/SHD_math.c
index bd2fdb457c0..95162e508d5 100644
--- a/source/blender/nodes/intern/SHD_nodes/SHD_math.c
+++ b/source/blender/nodes/intern/SHD_nodes/SHD_math.c
@@ -180,15 +180,18 @@ bNodeStack **out)
bNodeType sh_node_math= {
/* *next,*prev */ NULL, NULL,
- /* type code */ SH_NODE_MATH,
- /* name */ "Math",
- /* width+range */ 120, 110, 160,
- /* class+opts */ NODE_CLASS_CONVERTOR, NODE_OPTIONS,
- /* input sock */ sh_node_math_in,
- /* output sock */ sh_node_math_out,
- /* storage */ "node_math",
- /* execfunc */ node_shader_exec_math,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* type code */ SH_NODE_MATH,
+ /* name */ "Math",
+ /* width+range */ 120, 110, 160,
+ /* class+opts */ NODE_CLASS_CONVERTOR, NODE_OPTIONS,
+ /* input sock */ sh_node_math_in,
+ /* output sock */ sh_node_math_out,
+ /* storage */ "node_math",
+ /* execfunc */ node_shader_exec_math,
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/SHD_nodes/SHD_mixRgb.c b/source/blender/nodes/intern/SHD_nodes/SHD_mixRgb.c
index fb0bf91a508..dba70253fda 100644
--- a/source/blender/nodes/intern/SHD_nodes/SHD_mixRgb.c
+++ b/source/blender/nodes/intern/SHD_nodes/SHD_mixRgb.c
@@ -70,7 +70,10 @@ bNodeType sh_node_mix_rgb= {
/* output sock */ sh_node_mix_rgb_out,
/* storage */ "",
/* execfunc */ node_shader_exec_mix_rgb,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/SHD_nodes/SHD_normal.c b/source/blender/nodes/intern/SHD_nodes/SHD_normal.c
index ac9d1707543..f1ffd3446af 100644
--- a/source/blender/nodes/intern/SHD_nodes/SHD_normal.c
+++ b/source/blender/nodes/intern/SHD_nodes/SHD_normal.c
@@ -67,7 +67,10 @@ bNodeType sh_node_normal= {
/* output sock */ sh_node_normal_out,
/* storage */ "",
/* execfunc */ node_shader_exec_normal,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/SHD_nodes/SHD_output.c b/source/blender/nodes/intern/SHD_nodes/SHD_output.c
index 4ed507f4774..0a9a30c452b 100644
--- a/source/blender/nodes/intern/SHD_nodes/SHD_output.c
+++ b/source/blender/nodes/intern/SHD_nodes/SHD_output.c
@@ -72,8 +72,11 @@ bNodeType sh_node_output= {
/* output sock */ NULL,
/* storage */ "",
/* execfunc */ node_shader_exec_output,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/SHD_nodes/SHD_rgb.c b/source/blender/nodes/intern/SHD_nodes/SHD_rgb.c
index d1c874c151b..4e56e26d3ad 100644
--- a/source/blender/nodes/intern/SHD_nodes/SHD_rgb.c
+++ b/source/blender/nodes/intern/SHD_nodes/SHD_rgb.c
@@ -52,7 +52,10 @@ bNodeType sh_node_rgb= {
/* output sock */ sh_node_rgb_out,
/* storage */ "",
/* execfunc */ node_shader_exec_rgb,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/SHD_nodes/SHD_squeeze.c b/source/blender/nodes/intern/SHD_nodes/SHD_squeeze.c
index f0031113b94..30abad666c4 100644
--- a/source/blender/nodes/intern/SHD_nodes/SHD_squeeze.c
+++ b/source/blender/nodes/intern/SHD_nodes/SHD_squeeze.c
@@ -56,15 +56,18 @@ bNodeStack **out)
bNodeType sh_node_squeeze= {
/* *next,*prev */ NULL, NULL,
- /* type code */ SH_NODE_SQUEEZE,
- /* name */ "Squeeze Value",
- /* width+range */ 120, 110, 160,
- /* class+opts */ NODE_CLASS_CONVERTOR, NODE_OPTIONS,
- /* input sock */ sh_node_squeeze_in,
- /* output sock */ sh_node_squeeze_out,
- /* storage */ "node_squeeze",
- /* execfunc */ node_shader_exec_squeeze,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* type code */ SH_NODE_SQUEEZE,
+ /* name */ "Squeeze Value",
+ /* width+range */ 120, 110, 160,
+ /* class+opts */ NODE_CLASS_CONVERTOR, NODE_OPTIONS,
+ /* input sock */ sh_node_squeeze_in,
+ /* output sock */ sh_node_squeeze_out,
+ /* storage */ "node_squeeze",
+ /* execfunc */ node_shader_exec_squeeze,
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/SHD_nodes/SHD_texture.c b/source/blender/nodes/intern/SHD_nodes/SHD_texture.c
index 8ba66d56b3c..ace11a20d42 100644
--- a/source/blender/nodes/intern/SHD_nodes/SHD_texture.c
+++ b/source/blender/nodes/intern/SHD_nodes/SHD_texture.c
@@ -120,8 +120,11 @@ bNodeType sh_node_texture= {
/* output sock */ sh_node_texture_out,
/* storage */ "",
/* execfunc */ node_shader_exec_texture,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/SHD_nodes/SHD_valToRgb.c b/source/blender/nodes/intern/SHD_nodes/SHD_valToRgb.c
index 90e8cb28fac..cf7e33d9dca 100644
--- a/source/blender/nodes/intern/SHD_nodes/SHD_valToRgb.c
+++ b/source/blender/nodes/intern/SHD_nodes/SHD_valToRgb.c
@@ -69,8 +69,11 @@ bNodeType sh_node_valtorgb= {
/* output sock */ sh_node_valtorgb_out,
/* storage */ "ColorBand",
/* execfunc */ node_shader_exec_valtorgb,
- /* butfunc */ NULL,
- /* initfunc */ node_shader_init_valtorgb
+ /* butfunc */ NULL,
+ /* initfunc */ node_shader_init_valtorgb,
+ /* freestoragefunc */ node_free_standard_storage,
+ /* copystoragefunc */ node_copy_standard_storage,
+ /* id */ NULL
};
@@ -95,16 +98,19 @@ static void node_shader_exec_rgbtobw(void *data, bNode *node, bNodeStack **in, b
bNodeType sh_node_rgbtobw= {
/* *next,*prev */ NULL, NULL,
- /* type code */ SH_NODE_RGBTOBW,
- /* name */ "RGB to BW",
- /* width+range */ 80, 40, 120,
- /* class+opts */ NODE_CLASS_CONVERTOR, 0,
- /* input sock */ sh_node_rgbtobw_in,
- /* output sock */ sh_node_rgbtobw_out,
- /* storage */ "",
- /* execfunc */ node_shader_exec_rgbtobw,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* type code */ SH_NODE_RGBTOBW,
+ /* name */ "RGB to BW",
+ /* width+range */ 80, 40, 120,
+ /* class+opts */ NODE_CLASS_CONVERTOR, 0,
+ /* input sock */ sh_node_rgbtobw_in,
+ /* output sock */ sh_node_rgbtobw_out,
+ /* storage */ "",
+ /* execfunc */ node_shader_exec_rgbtobw,
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/SHD_nodes/SHD_value.c b/source/blender/nodes/intern/SHD_nodes/SHD_value.c
index 9d6f6a34473..57ef7226066 100644
--- a/source/blender/nodes/intern/SHD_nodes/SHD_value.c
+++ b/source/blender/nodes/intern/SHD_nodes/SHD_value.c
@@ -54,8 +54,11 @@ bNodeType sh_node_value= {
/* output sock */ sh_node_value_out,
/* storage */ "",
/* execfunc */ node_shader_exec_value,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/SHD_nodes/SHD_vectMath.c b/source/blender/nodes/intern/SHD_nodes/SHD_vectMath.c
index 22da16b9620..8d0a4b3abe3 100644
--- a/source/blender/nodes/intern/SHD_nodes/SHD_vectMath.c
+++ b/source/blender/nodes/intern/SHD_nodes/SHD_vectMath.c
@@ -109,7 +109,10 @@ bNodeType sh_node_vect_math= {
/* output sock */ sh_node_vect_math_out,
/* storage */ "node_vect_math",
/* execfunc */ node_shader_exec_vect_math,
- /* butfunc */ NULL,
- /* initfunc */ NULL
+ /* butfunc */ NULL,
+ /* initfunc */ NULL,
+ /* freestoragefunc */ NULL,
+ /* copystoragefunc */ NULL,
+ /* id */ NULL
};
diff --git a/source/blender/nodes/intern/SHD_util.h b/source/blender/nodes/intern/SHD_util.h
index 5ab7e3a7031..6b9a26de350 100644
--- a/source/blender/nodes/intern/SHD_util.h
+++ b/source/blender/nodes/intern/SHD_util.h
@@ -60,6 +60,7 @@
#include "BKE_library.h"
#include "../SHD_node.h"
+#include "node_util.h"
#include "BIF_gl.h"
#include "BIF_glutil.h"
diff --git a/source/blender/nodes/intern/node_util.c b/source/blender/nodes/intern/node_util.c
new file mode 100644
index 00000000000..9c9807f6898
--- /dev/null
+++ b/source/blender/nodes/intern/node_util.c
@@ -0,0 +1,52 @@
+/**
+ * $Id$
+ *
+ * ***** BEGIN GPL LICENSE BLOCK *****
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software Foundation,
+ * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ *
+ * The Original Code is Copyright (C) 2007 Blender Foundation.
+ * All rights reserved.
+ *
+ * The Original Code is: all of this file.
+ *
+ * Contributor(s): Nathan Letwory.
+ *
+ * ***** END GPL LICENSE BLOCK *****
+ */
+
+#include "CMP_util.h"
+#include "SHD_util.h"
+
+void node_free_curves(bNode* node)
+{
+ curvemapping_free(node->storage);
+}
+
+void node_free_standard_storage(bNode *node)
+{
+ MEM_freeN(node->storage);
+}
+
+void node_copy_curves(bNode* orig_node, bNode* new_node)
+{
+ new_node->storage= curvemapping_copy(orig_node->storage);
+}
+
+void node_copy_standard_storage(bNode *orig_node, bNode *new_node)
+{
+ new_node->storage= MEM_dupallocN(orig_node->storage);
+}
+
diff --git a/source/blender/nodes/intern/node_util.h b/source/blender/nodes/intern/node_util.h
new file mode 100644
index 00000000000..660c935aaad
--- /dev/null
+++ b/source/blender/nodes/intern/node_util.h
@@ -0,0 +1,42 @@
+/**
+ * $Id$
+ *
+ * ***** BEGIN GPL LICENSE BLOCK *****
+ *
+ * This program is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU General Public License
+ * as published by the Free Software Foundation; either version 2
+ * of the License, or (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software Foundation,
+ * Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ *
+ * The Original Code is Copyright (C) 2007 Blender Foundation.
+ * All rights reserved.
+ *
+ * The Original Code is: all of this file.
+ *
+ * Contributor(s): Nathan Letwory.
+ *
+ * ***** END GPL LICENSE BLOCK *****
+ */
+
+#ifndef NODE_UTIL_H_
+#define NODE_UTIL_H_
+
+#include "MEM_guardedalloc.h"
+
+extern void node_free_curves(struct bNode* node);
+extern void node_free_standard_storage(struct bNode *node);
+
+extern void node_copy_curves(struct bNode* orig_node, struct bNode* new_node);
+extern void node_copy_standard_storage(struct bNode *orig_node, struct bNode *new_node);
+
+#endif
+