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>2007-01-27 13:08:16 +0300
committerTon Roosendaal <ton@blender.org>2007-01-27 13:08:16 +0300
commit735b426344d8110cf8bb70a42e4e2a78bb269ad8 (patch)
treeffa722e36a7cdc1ac50b585068cec4877a7aa876 /source/blender/src/drawnode.c
parent8f075f9518c8173523e3726b436fa02de6fea994 (diff)
Two fixes:
- when rendering a scene, all composite trees of other trees should get signalled the render output changed. This only happened with a composite active in render. - the Mix node "A" option only works in Composite, as accidentally visible for shader trees.
Diffstat (limited to 'source/blender/src/drawnode.c')
-rw-r--r--source/blender/src/drawnode.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/source/blender/src/drawnode.c b/source/blender/src/drawnode.c
index 2bb8f387ad3..d3c086959f4 100644
--- a/source/blender/src/drawnode.c
+++ b/source/blender/src/drawnode.c
@@ -273,15 +273,17 @@ static int node_buts_mix_rgb(uiBlock *block, bNodeTree *ntree, bNode *node, rctf
{
if(block) {
uiBut *bt;
+ int a_but= (ntree->type==NTREE_COMPOSIT);
/* blend type */
uiBlockBeginAlign(block);
bt=uiDefButS(block, MENU, B_NODE_EXEC+node->nr, "Mix %x0|Add %x1|Subtract %x3|Multiply %x2|Screen %x4|Overlay %x9|Divide %x5|Difference %x6|Darken %x7|Lighten %x8|Dodge %x10|Burn %x11|Color %x15|Value %x14|Saturation %x13|Hue %x12",
- butr->xmin, butr->ymin, butr->xmax-butr->xmin-20, 20,
+ butr->xmin, butr->ymin, butr->xmax-butr->xmin -(a_but?20:0), 20,
&node->custom1, 0, 0, 0, 0, "");
uiButSetFunc(bt, node_but_title_cb, node, bt);
- /* Alpha option */
- uiDefButS(block, TOG, B_NODE_EXEC+node->nr, "A",
+ /* Alpha option, composite */
+ if(a_but)
+ uiDefButS(block, TOG, B_NODE_EXEC+node->nr, "A",
butr->xmax-20, butr->ymin, 20, 20,
&node->custom2, 0, 0, 0, 0, "Include Alpha of 2nd input in this operation");
}