ParametricMeshLayer object¶
app.project.item(index).layer(index)
Note
This functionality was added in After Effects 26.3.
Description¶
The ParametricMeshLayer object represents a Parametric Mesh layer within a composition.
Info
ParametricMeshLayer is a subclass of AVLayer object. It inherits the following properties and property groups from AVLayer object:
- Marker
- Time Remap
- Transform
- Anchor Point
- Position
- Scale
- Orientation
- X Rotation
- Y Rotation
- Rotation
- Opacity
- Layer Styles
- Audio
- AudioLevels
Example¶
If the first item in the project is a CompItem, and the first layer of that CompItem is a ParametricMeshLayer, the following checks its type.
var layer = app.project.item(1).layer(1);
if (layer instanceof ParametricMeshLayer)
{
// do something
}
Attributes¶
ParametricMeshLayer.canAddOrRemoveMaterialOverride¶
app.project.item(index).layer(index).canAddOrRemoveMaterialOverride
Warning
This functionality is in After Effects (Beta) 27.1 and is subject to change while it remains in Beta.
Description¶
This value is false for parametric mesh layers because their material override is always present and cannot be removed. The material source can still be changed with MaterialPropertyGroup.setMaterialOverride().
Type¶
Boolean; read-only.
ParametricMeshLayer.materialAssignment¶
app.project.item(index).layer(index).materialAssignment
Warning
This functionality is in After Effects (Beta) 27.1 and is subject to change while it remains in Beta.
Description¶
The layer's material assignment group. A ParametricMeshLayer has one material assignment, accessible with MaterialAssignment.DEFAULT.
The assignment's material properties depend on its source. The default material exposes properties such as Base Color and Roughness. Substance and layer sources expose texture transform properties. Uniform Tiling and Randomize Offset are not available on parametric mesh layers.
Type¶
MaterialAssignmentPropertyGroup object; read-only.
ParametricMeshLayer.materialAssignmentCount¶
app.project.item(index).layer(index).materialAssignmentCount
Warning
This functionality is in After Effects (Beta) 27.1 and is subject to change while it remains in Beta.
Description¶
The total number of material assignments on the layer, including assignments whose material override has not been added. A ParametricMeshLayer has one material assignment. This value is the same as materialAssignment.numProperties.
Type¶
Integer; read-only.
ParametricMeshLayer.parametricMeshType¶
app.project.item(index).layer(index).parametricMeshType
Note
This functionality was added in After Effects 26.3.
Description¶
For a parametric mesh layer, its mesh type. Trying to set this attribute for a non-parametric mesh layer produces an error.
Type¶
A ParametricMeshType enumerated value; read/write. One of:
ParametricMeshType.SPHEREParametricMeshType.PLANEParametricMeshType.CYLINDERParametricMeshType.CONEParametricMeshType.TORUSParametricMeshType.CUBE
ParametricMeshLayer.parametricMeshOptions¶
app.project.item(index).layer(index).parametricMeshOptions
Note
This functionality was added in After Effects 26.3.
Description¶
Gets/sets details about the structure of the parametric mesh.
Type¶
ParametricMeshOptions based on the ParametricMeshType of the layer, as follows.
For ParametricMeshType.CUBE¶
parametricMeshOptions.widthparametricMeshOptions.heightparametricMeshOptions.depthparametricMeshOptions.smoothingAngle
For ParametricMeshType.SPHERE¶
parametricMeshOptions.radiusparametricMeshOptions.sidesparametricMeshOptions.sliceCapsparametricMeshOptions.sliceStartparametricMeshOptions.sliceEndparametricMeshOptions.smoothingAngle
For ParametricMeshType.PLANE¶
parametricMeshOptions.widthparametricMeshOptions.lengthparametricMeshOptions.cornerRadiusparametricMeshOptions.cornerSides
For ParametricMeshType.TORUS¶
parametricMeshOptions.ringRadiusparametricMeshOptions.pipeRadiusparametricMeshOptions.ringSidesparametricMeshOptions.pipeSidesparametricMeshOptions.capsparametricMeshOptions.sliceStartparametricMeshOptions.sliceEndparametricMeshOptions.smoothingAngle
For ParametricMeshType.CONE¶
parametricMeshOptions.topRadiusparametricMeshOptions.bottomRadiusparametricMeshOptions.heightparametricMeshOptions.sidesparametricMeshOptions.topCapparametricMeshOptions.bottomCapparametricMeshOptions.sliceCapsparametricMeshOptions.sliceStartparametricMeshOptions.sliceEndparametricMeshOptions.smoothingAngle
For ParametricMeshType.CYLINDER¶
parametricMeshOptions.radiusparametricMeshOptions.heightparametricMeshOptions.sidesparametricMeshOptions.topCapparametricMeshOptions.bottomCapparametricMeshOptions.sliceCapsparametricMeshOptions.sliceStartparametricMeshOptions.sliceEndparametricMeshOptions.smoothingAngle
ParametricMeshLayer.parametricBevelOptions¶
app.project.item(index).layer(index).parametricBevelOptions
Note
This functionality was added in After Effects 26.3.
Description¶
Gets/sets details about the beveling of the parametric mesh.
Info
Only Parametric Mesh Layers with ParametricMeshType.CUBE, ParametricMeshType.CONE, and ParametricMeshType.CYLINDER have parametricBevelOptions.
Type¶
ParametricBevelOptions based on the ParametricMeshType of the layer, as follows.
For ParametricMeshType.CUBE¶
parametricBevelOptions.radiusparametricBevelOptions.sides
For ParametricMeshType.CONE¶
parametricBevelOptions.topRadiusparametricBevelOptions.topSidesparametricBevelOptions.bottomRadiusparametricBevelOptions.bottomSides
For ParametricMeshType.CYLINDER¶
parametricBevelOptions.radiusparametricBevelOptions.sides