FXScript

FXScript is a scripting language for Final Cut Pro and Final Cut Express.

FXBuilder is the scripting utility in which users are able to modify existing FCP FXScripts or program completely new ones. For example, to scale an image, only two lines are necessary to scale an image from its full size to half size:

scale(Region, CenterOfScale, 0.5, 0.5);
blitrect(ImageBuffer, OrigRegion, Destination-Buffer, Region);

First the region, which might be a rectangle, is scaled by the statement scale and its parameters. Then the statement blitrect copies a region of an image into a changed region. When the OrigRegion and the new Region have different sizes, Final Cut Pro scales the image to fit into the new region. A Statement is a command that accomplishes a single action. In our example, the statements are scale and blitrect. In FXBuilder users can create and test FXScripts, optionally in multiple windows.

FX groups

Inside Final Cut Pro/Express and FXScript are three types of effects:

Script structure

A FXScript has two parts:

Normally the flow of the script is from top to bottom. Users can take flow control by using loops (for example, For/Next) and conditional branches (for example, If/Else). FXScript also allows breaking scripts up into subroutines that can be called from other parts of the script by using their names.

This article is issued from Wikipedia - version of the 9/1/2011. The text is available under the Creative Commons Attribution/Share Alike but additional terms may apply for the media files.