ADOBE AFTER EFFECTS: Forum Expressions Tutorials Creative Cloud

Create a new solid with composition size with javascript

COW Forums : Adobe After Effects

FAQ   •   VIEW ALL   •   ADD A NEW POST   •   PRINT
Respond to this post   •   Return to posts index   •   Read entire thread


Mário Pereira
Create a new solid with composition size with javascript
on Oct 29, 2016 at 5:04:32 pm

Hi all,

I've searched everywhere and I can't find a proper solution for what I want to accomplish.

I created a script that creates a new solid in my active composition that is automatically named "matte" and has the RGB values set to "0 255 0", also it changes the layer label color automatically, the javascript is as follows:

app.project.activeItem.layers.addSolid([0,255,0], "matte", 1920, 1080, 1).label = 16;

I would like the width, height and aspect ration of this layer to be whatever the active composition size is instead of it having a pre-defined value, can anyone help?

Thanks in advance!

Mário Pereira


Posts IndexRead Thread 


Current Message Thread:





podcasts
© 2019 CreativeCOW.net All Rights Reserved
[TOP]