diff options
Diffstat (limited to 'source/blender/editors/space_node')
-rw-r--r-- | source/blender/editors/space_node/drawnode.c | 16 | ||||
-rw-r--r-- | source/blender/editors/space_node/node_draw.c | 3 |
2 files changed, 17 insertions, 2 deletions
diff --git a/source/blender/editors/space_node/drawnode.c b/source/blender/editors/space_node/drawnode.c index 9b342ed8f44..9dd588e77ae 100644 --- a/source/blender/editors/space_node/drawnode.c +++ b/source/blender/editors/space_node/drawnode.c @@ -2654,10 +2654,21 @@ static void node_composit_buts_ellipsemask(uiLayout *layout, bContext *UNUSED(C) uiItemR(layout, ptr, "mask_type", 0, NULL, ICON_NONE); } +static void node_composit_buts_composite(uiLayout *layout, bContext *UNUSED(C), PointerRNA *ptr) +{ + uiItemR(layout, ptr, "use_straight_alpha", 0, NULL, ICON_NONE); +} + +static void node_composit_buts_viewer(uiLayout *layout, bContext *UNUSED(C), PointerRNA *ptr) +{ + uiItemR(layout, ptr, "use_straight_alpha", 0, NULL, ICON_NONE); +} + static void node_composit_buts_viewer_but(uiLayout *layout, bContext *UNUSED(C), PointerRNA *ptr) { uiLayout *col; + uiItemR(layout, ptr, "use_straight_alpha", 0, NULL, ICON_NONE); uiItemR(layout, ptr, "tile_order", 0, NULL, ICON_NONE); if (RNA_enum_get(ptr, "tile_order") == 0) { col = uiLayoutColumn(layout, TRUE); @@ -2965,10 +2976,13 @@ static void node_composit_set_butfunc(bNodeType *ntype) ntype->uifunc = node_composit_buts_bokehblur; break; case CMP_NODE_VIEWER: - ntype->uifunc = NULL; + ntype->uifunc = node_composit_buts_viewer; ntype->uifuncbut = node_composit_buts_viewer_but; ntype->uibackdropfunc = node_composit_backdrop_viewer; break; + case CMP_NODE_COMPOSITE: + ntype->uifunc = node_composit_buts_composite; + break; case CMP_NODE_MASK: ntype->uifunc = node_composit_buts_mask; break; diff --git a/source/blender/editors/space_node/node_draw.c b/source/blender/editors/space_node/node_draw.c index d5d2ace6fa7..34f7799d47c 100644 --- a/source/blender/editors/space_node/node_draw.c +++ b/source/blender/editors/space_node/node_draw.c @@ -368,7 +368,8 @@ static void node_update_basis(const bContext *C, bNodeTree *ntree, bNode *node) } /* buttons rect? */ - if ((node->flag & NODE_OPTIONS) && node->typeinfo->uifunc) { + /* TODO: NODE_OPTION shall be cleaned up */ + if (/*(node->flag & NODE_OPTIONS) && */node->typeinfo->uifunc) { dy -= NODE_DYS / 2; /* set this for uifunc() that don't use layout engine yet */ |