Keying Screen node from tomato branch
[blender.git] / source / blender / editors / space_node / drawnode.c
index e6549034a855d5f688c9cc5d9d65a906ae7740ef..a42bf062b122bdee9614edd434b5482aed54cb5f 100644 (file)
@@ -2425,6 +2425,24 @@ static void node_composit_buts_mask(uiLayout *layout, bContext *C, PointerRNA *p
 
 }
 
 
 }
 
+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);
+       }
+}
+
 /* only once called */
 static void node_composit_set_butfunc(bNodeType *ntype)
 {
 /* only once called */
 static void node_composit_set_butfunc(bNodeType *ntype)
 {
@@ -2617,6 +2635,9 @@ static void node_composit_set_butfunc(bNodeType *ntype)
                case CMP_NODE_MASK:
                        ntype->uifunc= node_composit_buts_mask;
                        break;
                case CMP_NODE_MASK:
                        ntype->uifunc= node_composit_buts_mask;
                        break;
+               case CMP_NODE_KEYINGSCREEN:
+                       ntype->uifunc = node_composit_buts_keyingscreen;
+                       break;
                default:
                        ntype->uifunc = NULL;
        }
                default:
                        ntype->uifunc = NULL;
        }