add auto-key for masks

This commit is contained in:
Campbell Barton
2012-05-25 10:04:10 +00:00
parent 5ed2e0d5bc
commit c6e0d24d02

View File

@@ -4910,6 +4910,20 @@ void special_aftertrans_update(bContext *C, TransInfo *t)
nodeUpdateID(t->scene->nodetree, &mask->id);
WM_event_add_notifier(C, NC_SCENE|ND_NODES, NULL);
}
/* TODO - dont key all masks... */
if (IS_AUTOKEY_ON(t->scene)) {
MaskObject *maskobj;
Scene *scene = t->scene;
int frame = CFRA;
for (maskobj = mask->maskobjs.first; maskobj; maskobj = maskobj->next) {
MaskObjectShape *maskobj_shape;
maskobj_shape = BKE_mask_object_shape_varify_frame(maskobj, frame);
BKE_mask_object_shape_from_mask(maskobj, maskobj_shape);
}
}
}
}
else if (t->spacetype == SPACE_ACTION) {