Prototyping 2013-10-29 (Lens Based Media)

From XPUB & Lens-Based wiki

Introduction to Adobe After Effects

"Adobe After Effects is a digital motion graphics, visual effects and compositing software package published by Adobe Systems, used in the post-production process of filmmaking and television production. Its main uses are the origination of 2D and 2.5D animation, visual effects compositing and finishing (image adjustment, color correction etc.). After Effects can also be used as a basic non-linear editor and a media transcoder." ([1])

Example uses

Pros / Cons

  • Pros
    • Industry standard
    • Integration with other Adobe software (Photoshop , Premiere)
    • Scriptable
    • Huge amount of tutorials/examples


  • Cons
    • Limited 3D rendering options
    • Resource heavy (requires lots of RAM)
    • Proprietary (costly, version issues, not FLOSS -> Blender might be an alternative for some projects)
    • Windows & OSx only
    • Now only installable as a cloud app!

Expressions

Expressions in After Effects utilize a scripting language similar in syntax to Javascript/Flash Actionscript in order to manipulate layer properties and effects through mathematical equations. Property values can drive other property values. For example the rotation of one layer can drive the opacity of another. Expressions are applied by alt-clicking the stopwatch of a property. You can type any number, equation, or predifined function (such as wiggle) in this text field. To complete editing an expression hit enter on the keypad. For example, applying this expression to the position property of a layer makes it wiggle:

wiggle(5,40); //wiggle this layer 5 times a second by 40 pixels

Scripts

You can write scripts (in the JSX format, with a similar syntax to javascript) to perform certain automated tasks. Below is an example that creates textlayers in AE by reading a file.

//
// createTextLayersFromFile.jsx
//

//
// This script reads a user specified text file and
// creates a text layer for each line of text in a 
//  new comp called "my text comp"
//

{

  // create undo group

  app.beginUndoGroup("Create Text Layers From File");

  // Prompt user to select text file

  var myFile = File.openDialog("Please select input text file.");
  if (myFile != null){

    // open file
    var fileOK = myFile.open("r");
    if (fileOK){

      // create project if necessary

      var proj = app.project;
      if(!proj) proj = app.newProject();

      // create new comp named 'my text comp'

      var compW = 160; // comp width
      var compH = 120; // comp height
      var compL = 15;  // comp length (seconds)
      var compRate = 24; // comp frame rate
      var compBG = [48/255,63/255,84/255] // comp background color
  
      var myItemCollection = app.project.items;
      var myComp = myItemCollection.addComp('my text comp',compW,compH,1,compL,compRate);
      myComp.bgColor = compBG;

      // read text lines and create text layer for each
      // until end-of-file is reached

      var text;
      while (!myFile.eof){
        text = myFile.readln();
        if (text == "") text = "\r" ;
        myComp.layers.addText(text);
      }

      // close the file before exiting

      myFile.close();

    }else{
      alert("File open failed!");
    }
 
  }else{
    alert("No text file selected.");
  }

  app.endUndoGroup();
}

Resources