Is there a script around that will search and report all the layers in the project that includes layers? Even better find and tag them in some way?
Thanks,
Russ
Identifying layers with expressions
Moderator: byronnash
-
- Posts: 33
- Joined: February 7th, 2005, 7:32 am
- Contact:
you mean sort between lights, cameras, footage and comps ?
it's fairly easy to do with scripting. If you still need it I'll give it a shot.
matt
it's fairly easy to do with scripting. If you still need it I'll give it a shot.
matt
Boom boom boom.
Sorry, I realize now that I wrote out my request incorrectly. I am looking for a script that will identify any layers that include expressions.mlk wrote:you mean sort between lights, cameras, footage and comps ?
it's fairly easy to do with scripting. If you still need it I'll give it a shot.
matt
The expressions in layers is never obvious, and if there was a script like Paul Tuersley "Search Effects" which found expressioned layers that would be handy.
Thanks
-
- Posts: 33
- Joined: February 7th, 2005, 7:32 am
- Contact:
Ah ok, I thought you wanted to use expressions to do the deed...
Actually it should be fairly straightforward, as you can query the 'expression' string of a layer
Actually it should be fairly straightforward, as you can query the 'expression' string of a layer
I'll give it a tug later, I do not have after effects at work (shake and nuke)app.project.item(index).layer(index).expression
Boom boom boom.
Great...look forward to it.mlk wrote:Ah ok, I thought you wanted to use expressions to do the deed...
Actually it should be fairly straightforward, as you can query the 'expression' string of a layer
I'll give it a tug later, I do not have after effects at work (shake and nuke)app.project.item(index).layer(index).expression
-
- Posts: 33
- Joined: February 7th, 2005, 7:32 am
- Contact:
Here ya go
I don't have time to code the whole 'iterate through ever property of each layer' thing (it only checks rot, pos, anchor, scale and opacity expressions) but I believe Jeff Almasol from http://www.redefinery.com/ has a gimmeprops AE script that could help you do that.
cheers
mlk
Code: Select all
var token = 0;
function selectExpressions(){
AI = app.project.activeItem;
for (a=1;a<AI.layers.length+1; a++){
AI.layers[a].selected=false;
curLayer = AI.layers[a];
if(curLayer.position.expression.length > 0 || curLayer.opacity.expression.length > 0 || curLayer.rotation.expression.length > 0 || curLayer.anchorPoint.expression.length > 0 || curLayer.scale.expression.length > 0){
token++;
curLayer.selected = true;
}
}
return token;
}
var result = selectExpressions();
alert("Found " + result + " layer(s) with expressions");
I don't have time to code the whole 'iterate through ever property of each layer' thing (it only checks rot, pos, anchor, scale and opacity expressions) but I believe Jeff Almasol from http://www.redefinery.com/ has a gimmeprops AE script that could help you do that.
cheers
mlk
Boom boom boom.
Thanks for that. Hopefully you or some other script wizard can pick this up and extend it a little more. I can do a bit of expressions, but scripting way beyond me.mlk wrote:Here ya go
Code: Select all
var token = 0; function selectExpressions(){ AI = app.project.activeItem; for (a=1;a<AI.layers.length+1; a++){ AI.layers[a].selected=false; curLayer = AI.layers[a]; if(curLayer.position.expression.length > 0 || curLayer.opacity.expression.length > 0 || curLayer.rotation.expression.length > 0 || curLayer.anchorPoint.expression.length > 0 || curLayer.scale.expression.length > 0){ token++; curLayer.selected = true; } } return token; } var result = selectExpressions(); alert("Found " + result + " layer(s) with expressions");
I don't have time to code the whole 'iterate through ever property of each layer' thing (it only checks rot, pos, anchor, scale and opacity expressions) but I believe Jeff Almasol from http://www.redefinery.com/ has a gimmeprops AE script that could help you do that.
cheers
mlk
In the mean time this is very helpful.
Thanks again.