Bezier Path methods
Methods
-
static checkProperty(prop) → {PropertyInfo|null}
-
Checks if the property is a bezier property, or return the child bezier property if this is a shape or a mask
Parameters:
Name Type Description prop
Property | PropertyInfo The property -
static exportToJsxinc(shapePropopt, fileopt, offsetToCenteropt, appendopt, varNameopt) → {int}
-
Export the given shape property to the given file
The file name in the given path will be used to name the shape in the jsx codeParameters:
Name Type Attributes Default Description shapeProp
Property <optional>
The path property to export file
String <optional>
The path or File where the jsxinc shape will be written offsetToCenter
boolean <optional>
false If true, offset the path to the center append
boolean <optional>
false If true, appends the shape at the end of the file instead of overwriting it. varName
string <optional>
shape A name for the variable storing the shape Returns:
int - A status code. [0: success, ...]Example
var props = DuAEF.DuAE.Comp.getSelectedProps(PropertyValueType.SHAPE); var prop = props[0].getProperty(); var out = DuAEF.DuAE.Property.Shape.exportToJsxinc(prop, "D:/shape.test");
-
static horizontalSymetry(pathProperties)
-
Makes a horizontal symetry transformation on the paths, using the same axis of symetry for all shapes (shapes must be on the same layer).
Parameters:
Name Type Description pathProperties
Array.<Property> The After Effects Properties containing the paths to symetrize -
static scriptify(shapePropopt, offsetToCenteropt, varNameopt) → {string}
-
Scriptifies the given shape property.
Parameters:
Name Type Attributes Default Description shapeProp
Property <optional>
The path property to export offsetToCenter
boolean <optional>
false If true, offset the path to the center varName
string <optional>
shape A name for the variable storing the shape Returns:
string - The scriptified shape -
static verticalSymetry(pathProperties)
-
Makes a vertical symetry transformation on the paths, using the same axis of symetry for all shapes (shapes must be on the same layer).
Parameters:
Name Type Description pathProperties
Array.<Property> The After Effects Properties containing the paths to symetrize -
static verticesToComp(prop) → {Array.<Array.<float>>}
-
Gets the vertices array in comp coordinates.
Parameters:
Name Type Description prop
Property | PropertyInfo The property, a bezier path. Returns:
Array.<Array.<float>> - The vertices in comp coordinates.