October 17, 2018

Maya MEL Script: Insert “Blank” Frame

Joe explains a custom MEL script written for the storyboarding process used at Raconteur. It copies all the keyframes on a specified frame, then inserts a duplicate into the timeline to create a 2 identical sets of  keyframes.

Script:

select -r `ls -type animCurve`;
selectKey`ls -typ animCurve`;
setKeyframe;
timeSliderEditKeys addInbetween;
currentTime (`currentTime -q` + 1);
selectKey -clear;
selectKey -add -t (`currentTime -q`);
copyKey;
currentTime (`currentTime -q` – 1);
pasteKey -time (`currentTime -q`) -option merge;
keyTangent -itt auto -ott auto;
currentTime (`currentTime -q` + 1);

Get in Touch