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:
authorTon Roosendaal <ton@blender.org>2009-02-17 16:37:06 +0300
committerTon Roosendaal <ton@blender.org>2009-02-17 16:37:06 +0300
commit7a66002753e8da11e53cb8cdad28bde606847758 (patch)
tree2001f2f686712264397c5ace5a595621fb4620fe /source/blender/nodes
parent8020515ab2bf52aedc4250a51f7f928f057092e4 (diff)
2.5
Node/Composite tinkering: - titles in headers and on collapsed nodes back - backdrop option draws again (no scroll operator yet) - added preview option in blur, filter and mix nodes. Just for fun while working :) Probably every node should get this...
Diffstat (limited to 'source/blender/nodes')
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_blur.c4
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_filter.c4
-rw-r--r--source/blender/nodes/intern/CMP_nodes/CMP_mixrgb.c4
3 files changed, 9 insertions, 3 deletions
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_blur.c b/source/blender/nodes/intern/CMP_nodes/CMP_blur.c
index e7e799b6e76..2c7974d129d 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_blur.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_blur.c
@@ -665,6 +665,8 @@ static void node_composit_exec_blur(void *data, bNode *node, bNodeStack **in, bN
if(img!=in[0]->data)
free_compbuf(img);
}
+
+ generate_preview(node, out[0]->data);
}
static void node_composit_init_blur(bNode* node)
@@ -677,7 +679,7 @@ bNodeType cmp_node_blur= {
/* type code */ CMP_NODE_BLUR,
/* name */ "Blur",
/* width+range */ 120, 80, 200,
- /* class+opts */ NODE_CLASS_OP_FILTER, NODE_OPTIONS,
+ /* class+opts */ NODE_CLASS_OP_FILTER, NODE_PREVIEW|NODE_OPTIONS,
/* input sock */ cmp_node_blur_in,
/* output sock */ cmp_node_blur_out,
/* storage */ "NodeBlurData",
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_filter.c b/source/blender/nodes/intern/CMP_nodes/CMP_filter.c
index 6011ac3b58a..2c3b78e13a3 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_filter.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_filter.c
@@ -211,6 +211,8 @@ static void node_composit_exec_filter(void *data, bNode *node, bNodeStack **in,
}
out[0]->data= stackbuf;
+
+ generate_preview(node, out[0]->data);
}
}
@@ -220,7 +222,7 @@ bNodeType cmp_node_filter= {
/* type code */ CMP_NODE_FILTER,
/* name */ "Filter",
/* width+range */ 80, 40, 120,
- /* class+opts */ NODE_CLASS_OP_FILTER, NODE_OPTIONS,
+ /* class+opts */ NODE_CLASS_OP_FILTER, NODE_PREVIEW|NODE_OPTIONS,
/* input sock */ cmp_node_filter_in,
/* output sock */ cmp_node_filter_out,
/* storage */ "",
diff --git a/source/blender/nodes/intern/CMP_nodes/CMP_mixrgb.c b/source/blender/nodes/intern/CMP_nodes/CMP_mixrgb.c
index 6a4916b3fac..ca6de027b1d 100644
--- a/source/blender/nodes/intern/CMP_nodes/CMP_mixrgb.c
+++ b/source/blender/nodes/intern/CMP_nodes/CMP_mixrgb.c
@@ -73,6 +73,8 @@ static void node_composit_exec_mix_rgb(void *data, bNode *node, bNodeStack **in,
composit3_pixel_processor(node, stackbuf, in[1]->data, in[1]->vec, in[2]->data, in[2]->vec, in[0]->data, fac, do_mix_rgb, CB_RGBA, CB_RGBA, CB_VAL);
out[0]->data= stackbuf;
+
+ generate_preview(node, out[0]->data);
}
}
@@ -82,7 +84,7 @@ bNodeType cmp_node_mix_rgb= {
/* type code */ CMP_NODE_MIX_RGB,
/* name */ "Mix",
/* width+range */ 110, 60, 120,
- /* class+opts */ NODE_CLASS_OP_COLOR, NODE_OPTIONS,
+ /* class+opts */ NODE_CLASS_OP_COLOR, NODE_PREVIEW|NODE_OPTIONS,
/* input sock */ cmp_node_mix_rgb_in,
/* output sock */ cmp_node_mix_rgb_out,
/* storage */ "",