3 Replies Latest reply on Nov 22, 2010 3:44 PM by TeetowSBZ

    Scripting and task automation

    TeetowSBZ Level 1

      Writing a reply in another thread, I figured I'd just chime in with my views on the subject of scripting and / or automating tasks, since it's a large part of my daily workflow.

       

      We do virtually all our sound design in Sony Vegas -- anything from sound effect composites and voice processing to longer, complex montages, and even music. The reason we chose this particular application is its extensive scripting API, which allows us to leapfrog any limitations in the application itself, and arrange / process / analyse / render the project in a virtually unrestricted manner. Some examples of scripted tasks we currently do in Vegas:

       

      • Track asset usage
      • Write completely new editing tools
      • Batch-render with great flexibility (by track / by bus / by region name / etc)

       

      All of this, and much more, is clearly beyond the scope of the original application, yet we can do it because of the scripting API. This has kept us coming back for every upgrade, for almost a decade.

       

      Now, Audition is not Vegas, and it shouldn't be. We admittedly have little interest in the multitrack features, seeing how it overlaps with what Vegas already does to our satisfaction. But by virtue of the spectral editor alone, I can see a wide gamut of uses for a scripting API in Audition. Here are some spitball ideas:

       

      • Enhance selection
        • Select all overtones of the current selection
        • Select all frequency blobs louder than -12 dB
        • Invert frequency selection
      • More elegant use of favorites
        • If the file is mono, run my favorite SuperAdvanced Stereo Widener (TM) before applying this reverb preset
        • At each marker, apply a noise reduction plugin with the threshold set to the RMS volume of the selected frequency range
        • Split file by silence in the selected frequencies
        • Time-stretch the file based upon the dominant frequency
        • Sort regions by sonic similarity (would love to crack this one!)

       

      As you can see, none of these would make a lot of sense as actual feature requests, but they are all firmly within the scope of a proposed scripting API. As long as the API can provide the necessary raw data and methods, such as access to the spectrogram, selection tools, filters and basic operations, even a moderately talented programmer could then do the heavy lifting.

       

      Sorry for the giant wall of text, just figured I'd make the case at least once =)

        • 1. Re: Scripting and task automation
          _durin_ Adobe Employee

          Complex scripting isn't exposed in this release cycle, though I hope to see it open in future releases.  Adobe's ExtendScript platform is pretty simple and intuitive and allows for very complex functionality in the other applications supporting it.


          I'll add your notes to the Scripting feature in the database.  I'd love to see us expose FFT arrays and selection control via scripting, and it's great to get some feedback affirming that.

          • 2. Re: Scripting and task automation
            Scott Carver

            So, you guys are clearly serious scripting users -

             

            Vegas looks like it supports JavaScript and C# for scripting? Do you make more extensive use of one or the other? Any other language that would be preferred for scripting - Python, ActionScript, Lua, straight C++ (I don't mention ExtensionScript because it's essentially just JS)? Are you at the point where you would want to make, for example, plugins or extensions in C++?

             

            Also (guessing you work with a number of people cause of the we?) - do you have one or two people that generally write scripts that are used by everyone? Or, is everyone comfortable writing at least basic scripts for what they need to do?

             

            What kind of sound design work are you doing?

             

            Scott C

            • 3. Re: Scripting and task automation
              TeetowSBZ Level 1

              "We" is the audio department of a video games studio, and I'm the maintainer of the scripts that assist us in creating and rendering our audio assets. It's not a full-time job, though, I'm also a sound designer. This is one of the reasons we're Audition fans -- there are a lot of goodies in there for us noisebenders =)

               

              Being a coder-heavy outfit, we would have expertise in most of the languages you mentioned, with C++ being at an obvious forefront. C#, Lua and Python are commonly used in the tools, plugins and exporters we write for various applications such as Photoshop or Maya.

               

              Vegas ships with a set of .NET binaries for its scripting API, hence it supports C# (my weapon of choice), JScript and Visual Basic. You reference those binaries in your project, thereby gaining access to a Vegas object which contains collections of tracks, events, buses and so on. It also provides methods for modifying those collections (adding markers, moving events around, that sort of thing) or rendering files to disk. Vegas can be called upon to execute a script directly on launch, running "headless" without user interaction.

               

              I've personally taken quite a liking to C# and .NET; it gives you access to all kinds of helpful libraries, not the least using Windows Forms for the interactive parts. The scripts run in their own domain, so they have all the abilities of a regular .NET application -- including file operations and even web requests. I assume you'd want something a bit more platform agnostic for Audition, but there's something to be said for that degree of freedom.

               

              ---

               

              Addendum: As I posted this reply, I was informed that I had been logged out, and hitting the "back" button presented me with an empty form. After a brief rageface I proceeded to attach a debugger to Firefox, and managed to track down the post in the memory dump. Secure in my victory, I went back to post it... Only to discover the that your forum has an auto-save feature! Well played...