Skip to main content
Participant
April 20, 2022
Question

After effects scripting render output but keep "Output To" subfolder setting

  • April 20, 2022
  • 1 reply
  • 328 views

Hi! I'm writing a script to automate render file output locations, but want to keep the output to naming conventions of [comp folder]\[compname] 

you can select a "template" in the drop down list manually, but I can't find anything on whether you can access that through a script? 

This topic has been closed for replies.

1 reply

Dan Ebberts
Community Expert
Community Expert
April 20, 2022

I'm not sure exactly what your question is, but here's a little snippet that might help (it assumes myCompFolder is file folder object pointing to a folder on your hard drive):

 

var myRQItem = app.project.renderQueue.items.add(myComp);
myRQItem.applyTemplate("Best Settings");
var myOM = myRQItem.outputModule(1);
myOM.applyTemplate("Lossless");
var myOutputFilePath = myCompFolder.path + "/" + myCompFolder.name + "/" + encodeURI(myComp.name);
myOM.file = File(myOutputFilePath);
Participant
April 21, 2022

thank you!! sort of, i was wondering if there was an easy way to generate a sub folder for the render output, since you can load file location templates (i have since found the proper name for what I was looking for)

or accessing this through a script so I can add items to the render queue, change the file location but keep this structure that generates a comp folder for the render