While working on a film for one of my colleagues, I found myself staring at a folder of QuickTime movies that needed visual effects work done to them. I thought; wouldn’t it be cool if I could do something simple to make a composite for each one in After Effects (AE), without having to import and then make the composites manually – essentially make those first few steps automated.
I looked into it and came up with a solution:
- Use Automator to make a Droplet (app that takes input by dragging and dropping files onto it)
- Have Automator run a Python script that:
- takes the input files
- builds an After Effects jsx script that imports the footage and makes compositions based on them
- run an AppleScript script that starts AE and tells it to run the jsx script
- delete the jsx script
- Be robust enough to re-use without Automator later if needed
To use: drag and drop a file that AE can import onto the aepCreator icon. Multiple files will make one AE project that contains each file and a composition based on each one. One file will simply create an aep with one file and one composition. It should break if you drop a folder on it. It will probably break if you drop something that AE cannot import, such as a zip file. It will also probably break on PSD files and image sequences. If that is a problem, then let me know and I will make the program a little smarter. I needed it to handle video files, so that’s all I worried about.
The python script can be run from the command line without Automator so a shell script or another Python script could automate building multiple AE projects – when working with students or a team of artists, or if your pipeline is one project file per shot. I commented out a line in the jsx script that tells AE to exit after it has built the compositions and saved a new aep file. It is trivial to make the Droplets behave that way if interested.