Archive for Scripting

Final Cut Pro to After Effects Scripting without the hassle

With the release of Automatic Duck as a free product there really isn’t a great reason to use this script except as an example of XML parsing and Comp creation from parsed properties. For general FCP to AE workflows I’d recommend downloading Automatic Duck Pro Import AE 5.0. Depending on what happens with FCPX and After Effects I may write new tools for import from FCPX.

One of the most popular pieces of content here is Moving Between Final Cut Pro and After Effects: The Scripting Option. I think the idea of using scripting to move between Final Cut Pro and After Effects resonated with people working in a production environment.

Unfortunately, the post was more of a tech demo of the kinds of things that were possible with After Effects scripting and less of a practical demonstration for non-technical users. I still urge non-technical folks to dip their toes into the scripting waters, it can be really rewarding, but the challenges presented in “rolling your own” in this situation may be a bit much. So, I decided to write a small application to provide a way for readers who don’t want to deal with the scripting hassle to use some of the techniques I described in the article.

FCPToAE (working title) is an application for OSX 10.4 and above designed to create a .jsx file from a Final Cut XML file for import into After Effects without the hassle of scripting the different parts yourself. Read the rest of this entry »

Comments (231)

After Effects Background Render Script from Lloyd Alvarez

Lloyd Alvarez recently released his BG Renderer script for After Effects 7 which will work with both Mac and Windows. BG Renderer is a handy script for managing background rendering tasks including launching multiple instances if you have multiple CPU’s. Lloyd’s put a lot of work into this script and it shows.

If you’re looking for commercial software to get more bang for your rendering buck, take a look at Nucleo and Nucleo Pro from GridIron software.

Comments off

Great After Effects Scripts

As I take a chance to catch my breath after a bunch of big projects, I’ve been taking a look around to see what’s happening with other folks. While I was doing research I ran across the scripts, expressions and experiments at nabscripts.com. nabscripts is written in french so although I’ve noticed it in the past, it’s on my blogroll and nab is a regular poster at aenhancers, I haven’t dug into his (her?) site as much as I might normally.

Well, recently I ran across his collected scripts in english, and I must say they are a really nice set of scripts. I particularly like the auto orient camera script and createCylinder script. There are also a ton of utility scripts for making your every day life easier. The script collection section is also available in the original french. Nice work all around.

Comments (3)

Scripting Basics: pulling random values from within a defined range in After Effects

A common scripting requirement is to pull random values from within a defined range. For example, in the block dissolve transition the individual blocks of video are extracted from the video in a random order. Let’s revisit our float away video wall script and customize it to work in the same manner as a block dissolve but with a little more flair. We will scale the individual blocks up instead of just transitioning on and off.

Read the rest of this entry »

Comments off

Script to automate rigging a camera in After Effects

final update July 15, 2006

Added a new Point of Interest expression instead of dealing with the Auto-Orient dialog as detailed in the comments.

second update July 14, 2006

Chris Prosser suggested a decent workaround of using app.executeCommand(app.findMenuCommandId(”Auto-Orient…”)) to auto-launch the Auto Orient dialog. Which in my opinion makes the script pretty usable, even with the slider range problem. Right now, I’m launching a dialog that reads “Auto Camera Rig” needs to have Auto-Orient set to “Off”, please set it in the following dialog and then immediately launching the Auto-Orient dialog. I’d be interested in feedback on whether I should leave the two dialog boxes for context or use a saveSetting() preference to give the user a Never Show Again option as well as Ok. Power users could always just comment out the alert line. Scripting UI’s are always difficult for me, I think I know how I’d handle it in a regular mac app, but I’m not so sure how to handle it here.

update July 14, 2006

Stu Maschwitz pointed out some deficiencies with the original version of this script and provided a sample project of a much better implementation of a rigged camera project. Unfortunately, there seem to be a couple of show stoppers for recreating his project via scripting and I’d love some feedback if anybody has worked through these issues, and if not I’ll send them off to aebugs@adobe.com. The first is the addCamera() method assumes a point of interest in its constructor. That seems to make the UI equivalent of layer:transform:Auto Orient:Off impossible. I’ve tried setting the property to Null, etc. with no success. Interestingly, there is a useful assistant to set the property. Secondly, I can’t seem to set the slider control range via scripting. I can set the value but not the range so this may be less of a show stopper than the first. I’ve uploaded the changes that reflect Stu’s sample project, so if you find running the script then turning Auto orient off (command-option 0, on the Mac..control-alt 0, windows? I don’t have a Windows box handy), and can live with the slider range limitation, then great. Send any fixes my way and I’ll incorporate them. I think I see why nobody took this one on .

I was doing a bit of research and ran across Kyle Sim’s request to automate his process of rigging an After Effects camera on aenhancers and the adobe forums. Seemed like a really useful script and as near as I can tell nobody has tackled it, so I decided to give it a shot.

Usage is really straight forward, copy the script to After Effects:Scripts and run it from the scripts menu with an active Comp selected. I’m not doing any layer name checking because I think it’s possible that you might want more than one camera and null, although we’d have to adjust the expressions accordingly.

When I run the script my effect window for the Mover Null looks like this and it does a great job of making the camera move really straight forward.

Null Effect Controls from automated camera rig script for After Effects

You’ll have to thank Kyle or whoever set up the original expressions for the idea, this just automates the creation of the rig.

Update 04.21.2007

Paul Tuersley kindly updated this script with some cool new features.

I've attached an update to your db_autoCameraRig script. 
I've added a  check for AE8 which then automatically 
turns of Auto-Orient. 
I also  streamlined the bit that sets  the position / POI 
values.

Here’s Paul’s new script, and I’ve left the original up as a legacy 1.0 version in case we get any problems out in the field.
JSX script With Paul’s Improvements
Original Source JSX script
Update 06.10.2007
Paul kindly sent me additonal updates to his modification of the script.
Paul writes…

I’ve tweaked how this version deals with the Auto-Orient issue, which
you may want to check out. In AE6.5 it puts up an alert to tell you
to turn Auto-Orient off, in AE7 it does the same and then opens the
Auto-Orient dialog and in AE8 it turns Auto-Orient off automatically.
I also added expressions to all the properties you shouldn’t alter,
effectively locking them.

Thanks Paul.

Paul’s lates modifications – JSX script in a zip archive

Comments (19)

How to make a “Float Away Video Wall” in After Effects via scripting

I was watching HBO a bit ago and noticed a fun promo where the playing video breaks into a grid and slowly floats away out of frame (Anybody familiar with the work know where I can find a link to a web video? update: 08-07-2006 Greg Grusby correctly pointed me to this page from Shilo which makes it clear that my script is just a tech demo <grin>.). Although I’m not a fan of duplicating a concept just to mimic it technically, I thought it might be fun to work through the steps necessary to pull off something similar via After Effects scripting.

Update July 12, 2006

Thanks to Jeff Almasol for the tips about Alpha Add and Null names in the comments below. I wasn’t aware of it, but it looks like his script rd_Slicer addressed a lot of this how-to without the float away expression in a really nice package. Jeff’s scripts and resources at redefinery are must see.

Read the rest of this entry »

Comments (9)

A line chart script for After Effects

the Line Chart script UI in After Effects

This one is a little rough around the edges, but I wanted to get it out there so I can get some feedback and feature requests from readers.

Read the rest of this entry »

Comments (5)

How to use a spreadsheet to generate Lower Thirds, Slates, Titles, etc. in After Effects

UPDATE 09.17.2010 Updated for AE CS5
UPDATE 08.16.2007 Interim solution for AE CS3, see details at the end of this post.
I’ve been posting for a while about integrating databases into our workflow. A good database and workflow architecture can really maximize your productivity. But the bottom line is that most collaborative work gets done in a piecemeal fashion either by email, cut and paste or sending documents back and forth to clients and collaborators. I’m sure you’ve run into a situation where you find your self cutting and pasting between an Excel document into a text field while making Lower Thirds, Slates, Titles or other text-centric project. In this article I’ll explain a workflow to automate creating Lower Thirds in After Effects and I’ll follow up with an article on how to do the same thing in Final Cut Pro shortly.

Read the rest of this entry »

Comments (72)

Converting a Web Color to an RGB float array for After Effects

I’m writing a script that needs hexadecimal color input, sometimes referred to as a web color, converted to a value usable for a solid in After Effects. After Effects wants an array of RGB values in the range 0 to 1: [R, G, B]. Luckily Javascript supports bit-wise operators so the conversion is pretty straight forward. I used this function.

var hex = 'ffaadd';
var colors = hexToRGBArray(hex);

alert("red =" + colors[0] + " green=" + colors[1] + " blue=" + colors[2]);

function hexToRGBArray(hex){
	var rgb = parseInt(hex, 16); 
	var red   = (rgb >>16) & 0xFF; 
	var green = (rgb >>8) & 0xFF; 
	var blue  = rgb & 0xFF;
	
	var colorArray = [red/255.0, green/255.0, blue/255.0];
	
	return colorArray;

}


Source for this script
Downloadable version of this script

Comments off

Beginning javascript tutorial: Parsing a date from a sequenced jpeg filename

The other day I ran across another post at aenhancers.com. (aenhancers is a really great AE scripting forum by the way). The poster, Dan wrote:

I have shot thousands of stills
that I am now wanting to make
a time lapse movie out of. Each
still is named with the date and time
it was taken. For example
0507270505011.jpg would have been
taken yy/mm/dd/hh/mm/ss/(camera ID).
...
is there a way to parse the filename
to convert it into something more
legible? So 0507230004461.jpg would
translate into July 23, 2005 - 12:10 AM?...


The more I thought about it, this is exactly the kind of task I’m hoping to cover here at Creative Workflow Hacks. So in addition to posting a usable solution at aenhancers I decided to do a tutorial here with the problem solving steps involved. You know, teach a guy to fish and all.

I’m also going to try something new here. From the feedback I’m getting from users, the skill level and interest in DIY varies a lot. Some of you are hoping for beginners tutorials, some are looking for more advanced ideas and inspiration, and some of you are looking for solutions that are already thought through where you can download a bit of software, do your work and forget about it. So, I’m going to try labeling categories with beginner, intermediate, advanced and shrinkwrapped (although not that much software is actually shrinkwrapped anymore) depending on the skill level and the degree of involvement necessary to get the solution working. Send some feedback if you find it useful or not.

Back to our date parsing problem. Like almost all computer problems, the key here is to break down the big problem into a series of smaller problems. Read the rest of this entry »

Comments (2)

« Newer Posts · Older Posts »