Change render bitrate through script?

johnmeyer wrote on 6/1/2004, 12:41 PM
I started what I thought would be an amazingly useful script, but realized (fortunately after only about twenty minutes of cutting/pasting) that I didn't know how to set the bitrate for a render (I want to set the video VBR or CBR average bitrate for an MPEG-2 render). After a half hour of research, I have concluded that Vegas scripting doesn't allow this.

I hope I am wrong.

Is there a way to do this?

Comments

jetdv wrote on 6/1/2004, 12:47 PM
Not that I am aware of. You CAN now set the parameters on the "Render As" screen now, though.
johnmeyer wrote on 6/1/2004, 12:49 PM
Boy, that was quick. I'm not sure how I canset bitrate parameters on the Render As screen without first pressing the "Custom..." button.
jetdv wrote on 6/1/2004, 1:36 PM
What about this:

Make PRESETS for the various bit-rate options you want to have and include those presets with the script???


As far as I know, there is no way to get to the options under the "custom" button.
johnmeyer wrote on 6/1/2004, 2:42 PM
Ed,

Yeah, I thought about the presets, and for my own use that would be fine. However, I wanted to create a script that would let relatively new users just click a button and render to DVD Architect at the best possible rate, without exceeding the size of a single DVD-R. I was going to put settable limits in the script for people that are worried about too high encoding rates reducing compatibility with older players, and I was going to have radio buttons to select either CBR or VBR, and AC-3 Stereo, AC-3 5.1, or PCM. Finally, I was going to put a quality warning up on the screen if the bitrate went below some threshhold, such as 4,000.

Anyway, having to create new presets defeats the idea of having something a new user can just download and use.

I also thought about writing code to create or modify a template, but when I finally found the files created when you save a template (sft and vpti files, stored in the Application Data area of my user name), it looked like more trouble than it was worth to reverse engineer them and then write code to punch in the bitrate.

I feel like I did a year ago when I found that you cannot get date/time information from the video file. I was going to write a script to insert markers at timecode changes so you could do timecode scene detection on a file which was captured without scene detection. This would let you capture in one big file (like Pinnacle products do), but still have the advantages of date/time scene detection.
SonyPJM wrote on 6/7/2004, 2:10 PM

This is similar to the problem with modifying individual effect
parameters via script... data is specific to a particular plug-in and
Vegas itself doesn't know the format of the data.

You might be able to just install the templates you've created.
SonyTSW wrote on 6/16/2004, 9:10 PM
Yes, installing the templates is now more straightforward in Vegas 5. It's just a matter of copying them to the right folder in the user's application data area. You may want to provide them within a zip file, as it can preserve the relative folder path structure (part of the template pathname is a GUID, which is a rather lengthy combination of letters and digits).

In Vegas 4 and earlier, templates had to be registered in the Windows Registry so that Vegas could find them. Vegas 5 enumerates the files in the folder, it does not look in the registry.

By default the Windows Explorer treats the user's application data folder as hidden. So if you decide to provide templates along with instructions for unzipping and installing them, you'll need to tell users to enable the Explorer pref to show hidden system files and folders.