Retime, insert, and clean up keyframes, and other useful keyframe stuff.
Move both included scripts (abKeyWrangler.mel and abKWBuildMarkingMenu.mel) into your Maya scripts directory and restart Maya (or rehash). Run the following script from the mel command line to bring up the script interface:
To retime an animation you first have to select a range of keyframes in the Graph Editor. You can then use the quick retime buttons at the top of the UI to add or subtract a set number of frames to the selected range or you can set your new desired range by entering values in the New Start and Endframe fields.
To insert frames you can select an object (or objects) or you can select animation curves in the Graph Editor. Frames are inserted (or deleted) before or after the current time based on the value of the "Insert/Delete After Current Time" checkbox.
The "Curve Color" menu allows you to color the translate, rotate and scale animation curves of selected objects (usually control curves) from dark to light in the order selected. This can be especially useful when you're working on a hierarchy of several control curves at the same time (like a spine or FK limb) and want to identify which animation curve goes with which control curve at a glance. It makes sense when you see it.
"Filter Curves By ChannelBox Selection" under the "Options" menu, when enabled, will limit the animation curves displayed in the Graph Editor to those that match the attributes selected in the ChannelBox.
As of version 1.3, the script has the ability to quickly convert curves from stepped to spline. When you click the "Convert" tab you'll see this interface. It allows you to specify different types of tangents (and whether those tangents are broken or free weighted) for each of four different keyframe situations.
Peaks (or valleys) are keyframes with neighbors that are both either above or below them. Ledges are keys with one neighbor at the same value and the other above or below it. Plateaus are found between ledges; they're the keys with both neighbors at the same value. And slopes are exactly what they sound like: keys with one neighbor above them and the other below.
Version 2.1 adds valleys to the mix as well. It also includes a quick select conversion profile pop up menu, accessible by right clicking on the "Convert Selected Curves" button.
Version 2.1 of the script now includes its own marking menu. It incorporates the features of my sonorously named tangentMarkingMenuMod script (among other things) without the hassle of having to replace files in the Maya install directory.
To activate it click "Enable Custom Marking Menu" under the "Options" menu of the script UI. Once enabled, it will add "Lock Tangents" and "Free Tangents" options to your shift+s Middle Mouse Button (MMB) marking menu and create an entirely new menu mapped to your shift+s Right Mouse Button (RMB). Here's a quick description of the new menu items and their functions:
Copy animCurve values based on the current selection. When copying with:
Paste animCurve values based on the current selection. When pasting with:
If you find that the custom marking menu has disappeared during your Maya session, you can reactivate it by calling the script again ("source abKeyWrangler.mel;abKeyRangler;"). Once the marking menu is back you can close the UI.
If you have issues with the Translate Tool marking menu showing up when you don't want it to while using the shift+s RMB marking menu, click "Disable Translate Tool MM In Graph Editor" in the "Options" menu. The marking menu will be disabled only while the mouse is above the Graph Editor.
If you want the custom marking menu installed by default when you start Maya, add the following to your userSetup.mel file (in your scripts directory):
That's it. Enjoy!