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:
authorSergey Sharybin <sergey.vfx@gmail.com>2011-11-07 16:56:05 +0400
committerSergey Sharybin <sergey.vfx@gmail.com>2011-11-07 16:56:05 +0400
commit7b43abb90e2895292e183fcbca7140447025acd7 (patch)
tree145b1c4a94598cd0810ab999e49bdd5a331367cd /source/blender/editors/space_node/drawnode.c
parent27d42c63d9b507b1771ed5a7923c389c719b877b (diff)
Camera tracking integration
=========================== Rest of changes from camera tracking gsoc project. This commit includes: - New compositor nodes: * Movie Clip input node * Movie Undistortion node * Transformation node * 2D stabilization node - Slight changes in existing node to prevent code duplication
Diffstat (limited to 'source/blender/editors/space_node/drawnode.c')
-rw-r--r--source/blender/editors/space_node/drawnode.c48
1 files changed, 48 insertions, 0 deletions
diff --git a/source/blender/editors/space_node/drawnode.c b/source/blender/editors/space_node/drawnode.c
index 24ea51567ad..b4d89e1365d 100644
--- a/source/blender/editors/space_node/drawnode.c
+++ b/source/blender/editors/space_node/drawnode.c
@@ -1679,6 +1679,40 @@ static void node_composit_buts_ycc(uiLayout *layout, bContext *UNUSED(C), Pointe
uiItemR(layout, ptr, "mode", 0, "", ICON_NONE);
}
+static void node_composit_buts_movieclip(uiLayout *layout, bContext *C, PointerRNA *ptr)
+{
+ uiTemplateID(layout, C, ptr, "clip", NULL, "CLIP_OT_open", NULL);
+}
+
+static void node_composit_buts_stabilize2d(uiLayout *layout, bContext *C, PointerRNA *ptr)
+{
+ bNode *node= ptr->data;
+
+ uiTemplateID(layout, C, ptr, "clip", NULL, "CLIP_OT_open", NULL);
+
+ if(!node->id)
+ return;
+
+ uiItemR(layout, ptr, "filter_type", 0, "", 0);
+}
+
+static void node_composit_buts_transform(uiLayout *layout, bContext *UNUSED(C), PointerRNA *ptr)
+{
+ uiItemR(layout, ptr, "filter_type", 0, "", 0);
+}
+
+static void node_composit_buts_moviedistortion(uiLayout *layout, bContext *C, PointerRNA *ptr)
+{
+ bNode *node= ptr->data;
+
+ uiTemplateID(layout, C, ptr, "clip", NULL, "CLIP_OT_open", NULL);
+
+ if(!node->id)
+ return;
+
+ uiItemR(layout, ptr, "distortion_type", 0, "", 0);
+}
+
/* only once called */
static void node_composit_set_butfunc(bNodeType *ntype)
{
@@ -1829,6 +1863,20 @@ static void node_composit_set_butfunc(bNodeType *ntype)
case CMP_NODE_SEPYCCA:
ntype->uifunc=node_composit_buts_ycc;
break;
+ case CMP_NODE_MOVIECLIP:
+ ntype->uifunc= node_composit_buts_movieclip;
+ break;
+ case CMP_NODE_STABILIZE2D:
+ ntype->uifunc= node_composit_buts_stabilize2d;
+ break;
+ case CMP_NODE_TRANSFORM:
+ ntype->uifunc= node_composit_buts_transform;
+ break;
+ case CMP_NODE_MOVIEDISTORTION:
+ ntype->uifunc= node_composit_buts_moviedistortion;
+ break;
+ default:
+ ntype->uifunc= NULL;
}
if (ntype->uifuncbut == NULL) ntype->uifuncbut = ntype->uifunc;