Creative Communities of the World Forums

The peer to peer support community for media production professionals.

Activity Forums Adobe After Effects Scripting Question

  • Scripting Question

    Posted by Jon Merrifield on August 7, 2012 at 9:33 pm

    Before I dig in further and expand my javascript and scripting skills in AE, I have a question related to one thing I would like to try and achieve.

    My question is “yes” or “no” and requires nothing further of your time.

    I have a certain task I do often, change the Output Device and Output Mode of the AE Video Preview preference. Reason in parenthesis at the bottom if you must know.

    QUESTION:
    can I do this essentially macro or action function, changing preference parameters as it were, by writing a script?

    Thank you,
    -Jon

    (so I can review heavy comps in realtime, checking animation timing etc, on the computer monitor only. Heavy comps (many layers, 2K etc.) often cannot get realtime ram previews through the Kona through my HD Element media raid and media cache , just saying… often switch back to Output device Kona for critical detail viewing during comp work. I make efficient of use of keyboard shortcuts but I would still like a macro, action, or script as it were for an even faster change to the video preview output preferences)

    Jon Merrifield
    VFX Artist / Supervisor
    PELi Studios, Austin TX

    Jon Merrifield replied 13 years, 9 months ago 2 Members · 4 Replies
  • 4 Replies
  • Dan Fredley

    August 8, 2012 at 4:25 pm

    I don’t think it’s possible via ExtendScript or Applescript GUI scripting. You have to set it through the preferences in AE. But if you’re on a Mac you can go to System Preferences and add a custom keyboard shortcut under Adobe After Effects and just type “Video Preview…” for the menu item and then assign it the keyboard shortcut you want and it will open the “Video Preview Preferences” for you–saves you from having to go to the menu>submenu at least.

  • Jon Merrifield

    August 8, 2012 at 5:32 pm

    Thanks Dan,

    One step less helps of course. I have just been using the [command] : shortcut to get to the preferences and thinking about how to write a script for the whole thing every time I do.

    thanks again. Now I can put both pant legs on at the same time even if I still have to zip and button them.

    Jon Merrifield
    VFX Artist / Supervisor
    PELi Studios, Austin TX

  • Dan Fredley

    August 8, 2012 at 6:32 pm

    This script “tricks” AE into setting the video preview device to “Computer Monitor Only”, but there seems to be no way to set the preference to a specific device, so you’ll have to use the above solution to switch back to your external video output:

    {
    app.preferences.savePrefAsString("MacOS Video Preview Pref Section", "Device", "Computer Monitor Only");
    app.preferences.saveToDisk();
    app.preferences.reload();
    }

    Including “Computer Monitor Only” in the first line of code really doesn’t matter–it basically sets the preference to an unknown device, forcing AE to default to “Computer Monitor Only” behind the scenes. I only wrote it out literally to show what the script is trying to do even though it doesn’t mean anything. If that makes sense. It gets you one step closer.

  • Jon Merrifield

    August 8, 2012 at 8:23 pm

    Thanks so much for your time.
    I learned something and got more than I asked for.
    My hat, (and my hair).. are off.
    cheers

    Jon Merrifield
    VFX Artist / Supervisor
    PELi Studios, Austin TX

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