Skip to content

Instantly share code, notes, and snippets.

@ff6347
Created August 15, 2012 09:31
Show Gist options
  • Save ff6347/3358079 to your computer and use it in GitHub Desktop.
Save ff6347/3358079 to your computer and use it in GitHub Desktop.
get length of verticies of mask in AE
// based on knowledge by redefinery http://www.redefinery.com/ae/fundamentals/masks/
// and the AECS6 scripting guide also written by redefinery
var layer = app.project.activeItem.selectedLayers[0];
var masksGroup = layer("Masks");
if (masksGroup != null){
var my_maskShape = layer.mask(1).property("ADBE Mask Shape").value;
alert (my_maskShape.vertices.length);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment