Namespace

DuAE

DuAE

After Effects general tools

View Source DuAEF.jsxinc, line 19240

Members

int

# static readonly Axis

The axis or channels
Properties:
Name Type Description
X int
Y int
Z int
RED int
GREEN int
BLUE int
ALPHA int
HUE int
SATURATION int
VALUE int

View Source DuAEF.jsxinc, line 19247

# static readonly ColorLabels

Default color labels
To Do:
  • get real labels (from pref file?)

View Source DuAEF.jsxinc, line 19706

Object

# static CompactExpression

Associative array that converts property match names to their compact English expression statements.

View Source DuAEF.jsxinc, line 19306

Example
DuAE.CompactExpression["ADBE Transform Group"]
//returns "'transform'"
DuList

# static DuAELayeredFileType

List of file extensions whih may be imported as several items with the same source

View Source DuAEF.jsxinc, line 19685

string

# static readonly LayerAttribute

Attributes of layers in Ae
Properties:
Name Type Description
SELECTED string
VISIBLE string
AUDIO string
SOLO string
LOCKED string
SHY string
EFFECTS_ENABLED string
MOTION_BLUR string
THREE_D string
GUIDE string

View Source DuAEF.jsxinc, line 19627

int

# static readonly LayerPlacement

How to place new layers
Properties:
Name Type Description
BOTTOM int
UNDER_LAYER int
ABOVE_LAYER int
TOP int

View Source DuAEF.jsxinc, line 19598

string

# static readonly LayerType

Types of layers used by Ae
Properties:
Name Type Description
NULL string
SOLID string
SHAPE string
TEXT string
ADJUSTMENT string
LIGHT string
CAMERA string

View Source DuAEF.jsxinc, line 19611

string

# static readonly LoopType

Loop types
Properties:
Name Type Description
HOLD string
NONE string
CYCLE string
PINGPONG string
OFFSET string
CONTINUE string

View Source DuAEF.jsxinc, line 19646

int

# static readonly MenuCommandID

Menu Command Ids
These are the ids which can be found using app.findMenuCommandID("insertMenuNameHere");
Use app.executeCommand(id) to run them.
Properties:
Name Type Description
CUT int
COPY int
COPY_WITH_PROPERTY_LINKS int
PASTE int
DUPLICATE int
UNDO int
GENERAL_PREFERENCES int
SCRIPTING_PREFERENCES int
LAYER_CONTROLS int
REVEAL_EXPRESSION_ERRORS int
CONVERT_AUDIO_TO_KEYFRAMES int

View Source DuAEF.jsxinc, line 19577

Example
app.executeCommand(DuAE.MenuCommandID.COPY); //copies the selection
app.executeCommand(DuAE.MenuCommandID.PASTE); //pastes the selection
int

# static readonly PrefType

The type of AE preferences
Properties:
Name Type Description
BOOL int
STRING int
FLOAT int
LONG int

View Source DuAEF.jsxinc, line 19673

int

# static readonly SelectionMode

Enum for selections
Properties:
Name Type Description
SELECTED_PROPERTIES int
SELECTED_LAYERS int
ACTIVE_COMPOSITION int
SELECTED_COMPOSITIONS int
ALL_COMPOSITIONS int

View Source DuAEF.jsxinc, line 19693

string

# static readonly TimeAlignment

How to align in time
Properties:
Name Type Description
CENTER string
IN_POINT string
OUT_POINT string

View Source DuAEF.jsxinc, line 19661

int

# static readonly Type

Types of values
Properties:
Name Type Description
VALUE int
SPEED int
VELOCITY int

View Source DuAEF.jsxinc, line 19266

string

# static readonly Unit

Abbreviated units used in the UI.
These strings are localized based on internal After Effects dictionnaries.
Properties:
Name Type Description
PIXELS string
DEGREES string
PERCENT string

View Source DuAEF.jsxinc, line 19279

string

# static readonly UnitText

Units used in the UI
These strings are localized based on internal After Effects dictionnaries.
Properties:
Name Type Description
PERCENT string
DEGREES string
PIXELS string

View Source DuAEF.jsxinc, line 19292

DuVersion

# static readonly version

Informations about the version of after effects.

View Source DuAEF.jsxinc, line 19821

Methods

# static beginUndoGroup(groupName, autoCloseopt)

Begins an undoGroup.
Automatically prepend the group name with the script name.
Using this method is safer than the native one, as DuAEF will try to avoid opening several undo groups at once.
The group name is translatable.
Parameters:
Name Type Attributes Default Description
groupName string The name of the Undo Group.
autoClose boolean <optional>
true By default, DuAEF will close any previously opened undogroup (which has a different name) to prevent any error.
Set this to false in order to ignore this new group beginning and keep the previously opened one.

View Source DuAEF.jsxinc, line 19941

# static convertCollectionToArray(collection) → {Array}

Converts an AE Collection to an Array
This method is deprecated, you should use a DuList otherwise
Parameters:
Name Type Description
collection Array | Collection The collection to convert
Deprecated:
  • Yes

View Source DuAEF.jsxinc, line 20122

The array
Array

# static copy()

Copies the selection (runs the copy menu command)

View Source DuAEF.jsxinc, line 20010

Copies the selection with property links (runs the copy menu command)
Only on versions of After Effects greater than 11.0 (CS6)
On CS6 and below, a standard copy will be done.

View Source DuAEF.jsxinc, line 20026

# static cut()

Cuts the selection (runs the cut menu command)

View Source DuAEF.jsxinc, line 20003

# static duplicate()

Duplcates the selection (runs the duplicate menu command)

View Source DuAEF.jsxinc, line 20017

# static endUndoGroup(groupNameopt)

Ends an undoGroup.
Using this method is safer than the native one, as DuAEF will try to avoid opening several undo groups at once.
Parameters:
Name Type Attributes Description
groupName string <optional>
The name of the Undo Group to end. Use this if you used DuAE.beginUndoGroup with the 'autoClose' argument set to false before.

View Source DuAEF.jsxinc, line 19961

# static executeCommand(commandID)

Runs app.executeCommand in a safer way, taking care of undogroups.
Parameters:
Name Type Description
commandID int | string The ID of the command as given by app.findMenuCommandID(), or if it is a string, the name of the command.

View Source DuAEF.jsxinc, line 19972

# static getAeRender() → {File|null}

Gets the aerender binary

View Source DuAEF.jsxinc, line 19914

The aerender binary, or null if not found
File | null

# static getAEVersion(versionAsFloatopt) → {DuVersion}

Gets the version of After Effects from its public name (like 13.8 for CC2015.3)
Parameters:
Name Type Attributes Description
versionAsFloat float <optional>
The version name.

View Source DuAEF.jsxinc, line 19867

The version.
DuVersion

# static getAEVersionName(versionAsFloatopt) → {string}

Gets the public name of a version of After Effects (like CC2015.3 for version 13.8)
Parameters:
Name Type Attributes Description
versionAsFloat float <optional>
The version as a float. If not provided, will default to the current version of the running instance of After Effects.

View Source DuAEF.jsxinc, line 19837

The version name.
string

# static getCompactExpression(matchName, nameopt, propopt)

Gets the compact expression synonym of a matchName
Parameters:
Name Type Attributes Description
matchName string The matchName of a property
name string <optional>
A replacement name (or index) in case the compact expression does not exist. If omitted, the matchName will be used.
prop Proeprty <optional>
The original property; may be needed to differenciate between 3D layers / cam / lights, etc

View Source DuAEF.jsxinc, line 19731

# static getDuAEProperty(props) → {Array.<DuAEProperty>}

Gets the DuAEProperty for the properties
Parameters:
Name Type Description
props Array.<PropertyBase> The Properties

View Source DuAEF.jsxinc, line 19791

The info
Array.<DuAEProperty>

# static getPref(section, key, fileopt, typeopt) → {any|null}

Gets a pref
Parameters:
Name Type Attributes Default Description
section string The section of the preferences
key string The key
file PREFType <optional>
PREFType.PREF_Type_MACHINE_SPECIFIC The preference file, from the PREFType enum value of the After Effects API
type DuAE.PrefType <optional>
DuAE.PrefType.STRING The type of the preference to return

View Source DuAEF.jsxinc, line 19767

The pref or null if it does not exists
any | null

# static hasPref(section, key, fileopt) → {Boolean}

Checks if After Effects has the given preference
Parameters:
Name Type Attributes Default Description
section string The section of the preferences
key string The key
file PREFType <optional>
PREFType.PREF_Type_MACHINE_SPECIFIC The preference file, from the PREFType enum value of the After Effects API

View Source DuAEF.jsxinc, line 19751

true if the pref exists
Boolean

# static isAutoSaveFolder(folder) → {boolean}

Checks if the Folder is an Auto-Save folder
Parameters:
Name Type Description
folder Folder | string The folder or path to check

View Source DuAEF.jsxinc, line 20050

true if the folder is an auto-save folder
boolean

# static isDebuggerEnabled() → {Boolean}

Checks if the javascript debugger is enabled

View Source DuAEF.jsxinc, line 19827

true if the debugger is enabled.
Boolean

# static isLayeredFile(fileopt) → {boolean}

Checks if the file is a layered type (psd, ai, psb, fla...)
Parameters:
Name Type Attributes Description
file String | File <optional>
The file or the path

View Source DuAEF.jsxinc, line 19810

true if it's a layered file
boolean

# static isVersionAtLeast(versionName) → {boolean}

Checks if the current version is at least a given one
Parameters:
Name Type Description
versionName string The minimum version

View Source DuAEF.jsxinc, line 19905

True if the current version is higher or the same
boolean

# static isVersionHigherThan(versionName) → {boolean}

Checks if the current version is higher than a given one
Parameters:
Name Type Description
versionName string The minimum version

View Source DuAEF.jsxinc, line 19895

True if the current version is higher (strict, will be false if they're equal)
boolean

# static openScriptUIPanel(panelScriptName)

Opens a ScriptUI Panel if it is installed, or displays an alert otherwise.
Parameters:
Name Type Description
panelScriptName string The Script name of the panel "script.jsx"

View Source DuAEF.jsxinc, line 19987

# static paste()

Pastes the selection (runs the paste menu command)

View Source DuAEF.jsxinc, line 20034

# static scriptFolders(suboflderopt) → {Array.<Folder>}

Gets the list of folders where scripts may be installed
Parameters:
Name Type Attributes Description
suboflder string <optional>
The name of a subfolder, like "ScriptUI Panels" or "Startup" or "Shutdown"...

View Source DuAEF.jsxinc, line 20079

the list of Folder objects.
Array.<Folder>

# static toggleLayerControls()

Shows/hides the layer controls

View Source DuAEF.jsxinc, line 20070

# static undo()

Undoes (runs the undo command)

View Source DuAEF.jsxinc, line 20041