Tagged: Sound Keys

Animating with audio

Extracting raw keyframe data from After Effects keyframe data

You can easily “export” keyframe data from After Effects by copying the key frames in the timeline, then pasting them to a text file.

We want to extract raw key frame data, from After Effects formatted key fame data, via shell script, so that it can be used by Maya or other animation apps.

After Effects keyframe data looks like this:

Adobe After Effects 8.0 Keyframe Data Units Per Second 29.97 Source Width 900 Source Height 506 Source Pixel Aspect Ratio 1 Comp Pixel Aspect Ratio 1 Effects Sound Keys #1 Output 1 #22 Frame 1 0.000261479 2 0.00608461 3 0.0153011 4 0.0274689 5 0.0395869 6 0.0493024 7 0.0562797 8 0.0557284

We need something more like this:

0.000261479 0.00608461 0.0153011 0.0274689 0.0395869 0.0493024 0.0562797 0.0557284

Use this shell script to extract the keys: AfterEffectsKeyExtract.sh
Read this for a detailed explanation of the script.
Usage (in the terminal): path/to/AfterEffectsKeyExtract.sh path/to/keyFrameData.txt


Use this shell script to batch process several files:
BatchExtract.sh
Usage (in the terminal): path/to/BatchExtract.sh path/to/directory

Also see: http://oliverwolfson.com/importing-keyframe-data-to-maya/

Here is a primer on shell scripting. You can run a shell script on a Mac or in Linux, through the Terminal, or on a PC with a app like Cygwin.

UPDATE! The NEW! The python script, linked here, will do the same, import After Effects Sound Keys keyframes, from .txt files, to Maya, but it will also take care of the formatting, so there is no need to run the shell script on your After Effects keyframes before importing. Look for the NEW! script.