Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects AE script to make layers appear

  • AE script to make layers appear

    Posted by Leon Trinidad on June 1, 2019 at 1:50 pm

    Hi,

    I would like to create a AE script that make pics appear.
    For example, I have 4 imported pics (.png) in my project window named “arnold”, “billy”, “carrie”, “dylan”
    If I write “dylan” in a prompt then push “OK”, the “dylan” pic appears/goes in my composition window. Same if I write “arnold”, the “arnold” pic appears, ect.

    Is it possible ? Does somebody know how to make it ? Would be very helpful.

    Leo.

    Sergio Cabrera replied 7 years, 2 months ago 3 Members · 4 Replies
  • 4 Replies
  • Leon Trinidad

    June 2, 2019 at 6:04 am

    I work with After Effect for more than 5 years.

    I know it’s useless for AE, I just need to know how to do it and how it would work since I’m not familiar with scripting.
    That’s why I’m asking for help.

  • Walter Soyka

    June 2, 2019 at 8:54 am

    What you’re asking for is a relatively simple script for an experienced developer. For someone just getting started with scripting, though there’s a lot to understand: Javascript and the After Effects object model, building and interacting with a GUI, text manipulation, how to locate items in the project panel, how to add them to compositions, plus all the considerations you’d have to make for error correction if the user does something you don’t expect.

    I’d suggest you spend a little time learning how scripting in Ae works in general before attacking this specific problem. Here are a couple of good resources to get you started:

    https://www.provideocoalition.com/after-effects-extendscript-training-complete-series/

    https://aescripts.com/introduction-to-after-effects-scripting-video-course/

    Walter Soyka
    Designer & Mad Scientist at Keen Live [link]
    Motion Graphics, Widescreen Events, Presentation Design, and Consulting
    @keenlive   |   RenderBreak [blog]   |   Profile [LinkedIn]

  • Leon Trinidad

    June 2, 2019 at 8:19 pm

    Thank you!

  • Sergio Cabrera

    June 3, 2019 at 12:47 am

    Hello, it depends on what you mean by “appear”. You could make a hidden layer visible with the following script line:

    app.project.item(1).layer(1).enabled = true;

    And this to hide the layer:

    app.project.item(1).layer(1).enabled = false;

    Make sure to specify the item and layer numbers correctly.

We use anonymous cookies to give you the best experience we can.
Our Privacy policy | GDPR Policy