Page 1 of 1

Add layer to comp

Posted: February 13th, 2018, 4:07 pm
by Mules
Hi!

Is it possible to add an existing asset (solid) from the project window (asset library) to the current composition 
via scripting ?

Thanks!

Re: Add layer to comp

Posted: February 14th, 2018, 12:55 pm
by zlovatt
Yes, you certainly can.

Look at "layers.add" : http://docs.aenhancers.com/layers/layer ... ection-add


Code: Select all

var item = // your solid;
var comp = app.project.activeItem;
var itemAsLayer = comp.layers.add(item);

Re: Add layer to comp

Posted: February 15th, 2018, 7:06 am
by Mules
Thanks for the snippet!! And the link,

m,