Page 1 of 1

Change Render Queue Output Module settings

Posted: October 27th, 2005, 2:11 pm
by bohdi
I'm trying to write code to change the Output Module settings of comps sent to the render queue. So far I've scripted to get all the new comps sent to the queue, and the render queue window pops up when the script is done. But I can't seem to change the Output Module settings. I have a saved template for the Output Module. Here is the code that I'm playing with as it is now but it doesn't work:

var myoutputModule = "MJPEG-A_75%_High_MOS";
...

...
app.project.renderQueue.items.outputModule.applyTemplate(myoutputModule)

Any suggestions? Thanks!

Posted: October 28th, 2005, 4:32 am
by byronnash
You are on the right track, I think the script doesn't know which OM you are applying the template to. Try this:

Code: Select all

var movRS = "Preview_Web";  //Render Setting Template
var movOM = "Preview_Web";  //Output Module Template


var qItem = app.project.renderQueue.item(1);
qItem.outputModules[1].applyTemplate(movOM); //apply OM template
qItem.applyTemplate(movRS); //apply render setting template

what about multiple...

Posted: October 28th, 2005, 4:17 pm
by bohdi
That works to get the first comp in the queue and set the right outputModule. Thanks. What about for multiple comps? I need to set the same outputModule for all the comps in the queue. Thanks!

Posted: October 31st, 2005, 5:41 am
by byronnash
You will have to loop through all the render items and change the OM for each Queue item, one at a time. This shouldn't be too difficult.

Unless I'm missing something ...

Posted: October 31st, 2005, 3:55 pm
by scribling
Why wouldn't you just set that module to be the default? Now any render item has that module and no need for a script.

If there is a reason you aren't doing this how about this, use the command line renderer and tell it to use whichever module you want.

Problem solved....other question in new post though.

Posted: November 3rd, 2005, 6:43 pm
by bohdi
The key here was automation and eliminating as many steps as possible. This is for a repetitive process used daily.

Here is how I was able to get all the comps into the render queue and set the output module for all of them:

for (i=1; i <= app.project.renderQueue.numItems; i++) {
var movRS = "Best-Full-Current"; //Render Setting Template
var movOM = myoutputModule; //Output ModuleTemplate
var qItem = app.project.renderQueue.items;
qItem.outputModules[1].applyTemplate(movOM); //apply OM template
qItem.applyTemplate(movRS); //apply render setting template
}


Thanks all! I am stuck though at another step and am looking for help. I'll add this in a separate post titled "Changing the 'output to' setting..."