Answers.Body: <p>To update @MBrizzle answer, this functionality was added to After Effects CC 2014. There are 4 new methods:</p>
  
  <ul>
  <li>RenderQueueItem object getSetting, setSetting methods </li>
  <li>OutputModule object getSetting, setSetting methods</li>
  </ul>
  
  <p>You can find more about them at <a href="http://blogs.adobe.com/aftereffects/2014/04/new-changed-after-effects-cc-2014.html" rel="nofollow">http://blogs.adobe.com/aftereffects/2014/04/new-changed-after-effects-cc-2014.html</a></p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-09-10T00:12:48.770Z
Answers.Text: To update your answer Output Module setSetting only allow these keys: Audio Bit Depth
  Audio Channels
  Audio Sample Rate
  Channels :
  Color : Premultiplied (Matted)
  Crop : false
  Crop Bottom
  Crop Left
  Crop Right
  Crop Top : 0
  Depth : Millions of Colors
  Format : QuickTime
  Include Project Link : true
  Include Source XMP Metadata : false
  Lock Aspect Ratio : true
  Output Audio : Auto
  Output File Info : [object Object]
  Post-Render Action : 
  Resize : false
  Resize Quality : High
  Resize to : HDV/HDTV 720 25
  Starting #
  Use Comp Frame Number
  Use Region of Interest
  Video Output
Answers.UserDisplayName: James
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2016-09-10T00:12:59.900Z
Answers.Text: No codecs allowed
Answers.UserDisplayName: James
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2015-02-13T17:38:13.330Z
Answers.LastActivityDate: 2015-02-13T17:38:13.330Z
Answers.UserDisplayName: DaviBenNun
Answers.Body: <p>So, the answer to your question is 'yes, but...'</p>
  
  <p>It's perfectly feasible, but you have to create an output module with the settings that you want, and then save it to your computer.  You can create this by going to Edit -> Templates -> Output Module.  Click on the 'New' button in the pop-up window, and then Edit it for the settings you need (quicktime, h.264, etc).  Save it as a useful name ("H264HighQuality" or something like that).  Save the output module, and you'll be able to access it from your scripts from there on out.</p>
  
  <p>In order to use it in your script, just use:
  <code>app.project.renderQueue.items.add(myComp).applyTemplate("H264HighQuality");</code></p>
  
  <p>As long as you've <em>made</em> the template first, you can access it in your scripts as many times as you want.  However, After Effects does NOT allow you to programmatically create Output Modules or alter them on the fly, unfortunately.  But you only need to make the template once -- as long as you have that template on the computer you're running the script, it should work just fine.</p>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-08-15T08:04:28.153Z
Answers.Text: This answers my question. Thanks for the response!
Answers.UserDisplayName: cwiggo
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2014-08-15T03:23:00.970Z
Answers.LastActivityDate: 2014-08-15T03:23:00.970Z
Answers.UserDisplayName: MBrizzle
Body: <p>I've made a script that will loop through a (.txt) interchanging elements of a certain composition.</p>
  
  <p>Within the script, I add each changed composition to the render queue and output it.</p>
  
  <p>How can I pragmatically output the format in h.264 (.mp4) instead of it defaulting to (.avi).</p>
  
  <p>I've discovered that you can just change the default output module via edit -> templates -> output module, but still.. is there anyway of doing this via script?</p>
  
  <p>Thanks</p>
  
Tags: <video><after-effects><file-formats>
Title: Change output using a .jsx script for After Effects CS6
UserDisplayName: cwiggo
ThreadText: # Change output using a .jsx script for After Effects CS6
  
  (Asked by: username_0 on 2014-08-13)
  
  I've made a script that will loop through a (.txt) interchanging elements of a certain composition.
  
  Within the script, I add each changed composition to the render queue and output it.
  
  How can I pragmatically output the format in h.264 (.mp4) instead of it defaulting to (.avi).
  
  I've discovered that you can just change the default output module via edit -> templates -> output module, but still.. is there anyway of doing this via script?
  
  Thanks
  
  **Tags:** video, after-effects, file-formats
  
  
  ---
  
  ## 2 answers
  
  ### Answer by username_3 on 2014-08-15. Score: 4 | Accepted answer
  
  So, the answer to your question is 'yes, but...'
  
  It's perfectly feasible, but you have to create an output module with the settings that you want, and then save it to your computer. You can create this by going to Edit -> Templates -> Output Module. Click on the 'New' button in the pop-up window, and then Edit it for the settings you need (quicktime, h.264, etc). Save it as a useful name ("H264HighQuality" or something like that). Save the output module, and you'll be able to access it from your scripts from there on out.
  
  In order to use it in your script, just use:
  `app.project.renderQueue.items.add(myComp).applyTemplate("H264HighQuality");`
  
  As long as you've *made* the template first, you can access it in your scripts as many times as you want. However, After Effects does NOT allow you to programmatically create Output Modules or alter them on the fly, unfortunately. But you only need to make the template once -- as long as you have that template on the computer you're running the script, it should work just fine.
  
  > **Comments:**
  > **username_0**: This answers my question. Thanks for the response!  
  
  ---
  
  ### Answer by username_1 on 2015-02-13. Score: 2
  
  To update @username_3 answer, this functionality was added to After Effects CC 2014. There are 4 new methods:
  
  * RenderQueueItem object getSetting, setSetting methods
  * OutputModule object getSetting, setSetting methods
  
  You can find more about them at <http://blogs.adobe.com/aftereffects/2014/04/new-changed-after-effects-cc-2014.html>
  
  > **Comments:**
  > **username_2**: To update your answer Output Module setSetting only allow these keys: Audio Bit Depth Audio Channels Audio Sample Rate Channels : Color : Premultiplied (Matted) Crop : false Crop Bottom Crop Left Crop Right Crop Top : 0 Depth : Millions of Colors Format : QuickTime Include Project Link : true Include Source XMP Metadata : false Lock Aspect Ratio : true Output Audio : Auto Output File Info : [object Object] Post-Render Action :  Resize : false Resize Quality : High Resize to : HDV/HDTV 720 25 Starting # Use Comp Frame Number Use Region of Interest Video Output  
  > **username_2**: No codecs allowed  
  
  ---
  
  