Skip to content

Instantly share code, notes, and snippets.

View benbrandt's full-sized avatar

Ben Brandt benbrandt

View GitHub Profile
@unycone
unycone / sortlayers.jsx
Created March 25, 2013 12:28
This AfterEffects script sorts layers in a composition according to their in-points.
/*
* This AfterEffects script sorts layers in a composition according to their in-points.
*
* 1. Save this file as "sortlayers.jsx".
* 2. Select a target composition in project panel of your AfterEffects.
* 3. Run "sortlayers.jsx" from Menu->"File"->"Scripts"->"Run Script File".
*/
app.beginUndoGroup("Sort layers");
var item = app.project.activeItem;
if (item != null && item instanceof CompItem) {