Free Function Friday Ep.40 – getLayFXMatchNames

June 24th 2016 08:00:44am

Welcome to Free Function Friday episode getLayFXMatchNames. This week we go over getting match names of plugin effects with a simple function that takes a layer object as the argument and loops through it’s Effects property group getting their match names. This function is mostly a utility for developers, but could be implemented into a regular script as well.

Source Code:

var a = app.project.activeItem.layer(1);
alert(getLayFXMatchNames(a));

function getLayFXMatchNames(layObj){
	var fxMatchNames, fx, fxLen;
	fxMatchNames = new Array();
	fx = layObj.property("ADBE Effect Parade");
	fxLen = fx.numProperties;
	if(fxLen > 0){
		for(var e=1; e <= fxLen; e++){
			fxMatchNames.push(fx.property(e).matchName);
		}
		return fxMatchNames;
	}
	return null;
}
Checkout more:
Houdini Mardini Rural
Free Function Friday Ep.26 – applyPluginEffect
Free Function Friday Ep.12 – findCompByName
Free Function Friday Ep.20 – showHideControls
X-Particles Liquid Streaks