svn merge ^/trunk/blender -r47253:47272
[blender.git] / source / blender / editors / space_node / drawnode.c
index 676b1276569869917ce20864cc61fd609835bd68..5c9f066937aa138fe58c5a41417a4c20ab3e5b99 100644 (file)
@@ -2288,6 +2288,41 @@ static void node_composit_buts_viewer_but(uiLayout *layout, bContext *UNUSED(C),
        }
 }
 
+static void node_composit_buts_mask(uiLayout *layout, bContext *C, PointerRNA *ptr)
+{
+       uiTemplateID(layout, C, ptr, "mask", NULL, NULL, NULL);
+}
+
+static void node_composit_buts_keyingscreen(uiLayout *layout, bContext *C, PointerRNA *ptr)
+{
+       bNode *node= ptr->data;
+
+       uiTemplateID(layout, C, ptr, "clip", NULL, NULL, NULL);
+
+       if (node->id) {
+               MovieClip *clip = (MovieClip *) node->id;
+               uiLayout *col;
+               PointerRNA tracking_ptr;
+
+               RNA_pointer_create(&clip->id, &RNA_MovieTracking, &clip->tracking, &tracking_ptr);
+
+               col = uiLayoutColumn(layout, 1);
+               uiItemPointerR(col, ptr, "tracking_object", &tracking_ptr, "objects", "", ICON_OBJECT_DATA);
+       }
+}
+
+static void node_composit_buts_keying(uiLayout *layout, bContext *UNUSED(C), PointerRNA *ptr)
+{
+       /* bNode *node= ptr->data; */ /* UNUSED */
+
+       uiItemR(layout, ptr, "blur_pre", 0, NULL, ICON_NONE);
+       uiItemR(layout, ptr, "despill_factor", 0, NULL, ICON_NONE);
+       uiItemR(layout, ptr, "clip_black", 0, NULL, ICON_NONE);
+       uiItemR(layout, ptr, "clip_white", 0, NULL, ICON_NONE);
+       uiItemR(layout, ptr, "dilate_distance", 0, NULL, ICON_NONE);
+       uiItemR(layout, ptr, "blur_post", 0, NULL, ICON_NONE);
+}
+
 /* only once called */
 static void node_composit_set_butfunc(bNodeType *ntype)
 {
@@ -2477,7 +2512,15 @@ static void node_composit_set_butfunc(bNodeType *ntype)
                        ntype->uifuncbut = node_composit_buts_viewer_but;
                        ntype->uibackdropfunc = node_composit_backdrop_viewer;
                        break;
-
+               case CMP_NODE_MASK:
+                       ntype->uifunc= node_composit_buts_mask;
+                       break;
+               case CMP_NODE_KEYINGSCREEN:
+                       ntype->uifunc = node_composit_buts_keyingscreen;
+                       break;
+               case CMP_NODE_KEYING:
+                       ntype->uifunc = node_composit_buts_keying;
+                       break;
                default:
                        ntype->uifunc = NULL;
        }