Hi all,
I've been plugin away trying to get this to work but cant seam to get it right. What Im trying to do is run an individual effect on each layer from the top level of the document, for example.
Layer 1 will have effect A applied
layer 2 will have effect B applied and so on up to the 30th layer
I plan to create each effect as a function, this is what I have so far.
Code: Select allfunction processLayers(){
function getLayers( parent ){
for( var m = parent.layers.length -1; m >= 0; m-- ){
var layer = parent.layers[ m ];
if (m == 1){
effect1();
}else if(m == 2){
effect2();
}
}
}
getLayers(app.activeDocument);
};
fuction effect1(){
effect script goes here.
}
fuction effect2(){
effect script goes here.
}
Id also like to ignore the background layer as well if thats possible.
Run effect on each top level layer
-
Paul MR
Run effect on each top level layer
One option would be to create an actionset with your hundred or so different functions then you could use the index of the layer to select the action to run.