Answers.Body: <p>Apparently <code>createNewSequenceFromClips</code> was not available in my version of Premiere Pro (v14.0.1). When I updated to v14.4 all worked as it should.</p>
  <p>This <a href="https://gitlab.com/b_a/premiere-pro-automation" rel="nofollow noreferrer">example script</a> using that function works as expected.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2020-10-09T16:21:29.533Z
Answers.LastActivityDate: 2020-10-10T13:07:51.393Z
Answers.LastEditDate: 2020-10-10T13:07:51.393Z
Answers.UserDisplayName: Saaru Lindestøkke
Body: <p>I have a large amount of DV footage, which I want to convert into a video per day.</p>
  <p>I've tried doing this by scripting <code>ffmpeg</code>:</p>
  <pre class="lang-bash prettyprint-override"><code>ffmpeg -safe 0 -f concat -i day1-files.txt -fflags +igndts -ac 2 -ar 32000 -vf scale=768x576,setsar=1:1,yadif sq08_output.mov
  </code></pre>
  <p>but results varied from perfect to garbled audio or video.</p>
  <p>Then I tried this manually in Premiere Pro with the following steps:</p>
  <ol>
  <li>Import footage of a single day</li>
  <li>Automate to sequence</li>
  <li>Export media</li>
  </ol>
  <p>Results were perfect (for the same clips that <code>ffmpeg</code> couldn't decode).</p>
  <p>As I have thousands of clips I don't want to repeat the Premiere Pro steps manually, so I looked into <a href="https://premiere-scripting-guide.readthedocs.io/" rel="nofollow noreferrer">Premiere Pro scripting</a></p>
  <p>I completed step 1 with <a href="https://premiere-scripting-guide.readthedocs.io/general/project.html#project-importfiles" rel="nofollow noreferrer"><code>app.project.importFiles</code></a>:</p>
  <pre class="lang-js prettyprint-override"><code>app.project.importFiles([&quot;day1-1.mov&quot;, &quot;day1-2.mov&quot;, &quot;day1-3.mov&quot;], true, app.project.rootItem, false)
  </code></pre>
  <p>I tried to do step 2 with <a href="https://premiere-scripting-guide.readthedocs.io/general/project.html#project-createnewsequencefromclips" rel="nofollow noreferrer"><code>app.project.createNewSequenceFromClips</code></a>:</p>
  <pre class="lang-js prettyprint-override"><code>app.project.createNewSequenceFromClips(&quot;sequenceName&quot;
      , [app.project.rootItem.children[0]
      , app.project.rootItem.children[1]
      , app.project.rootItem.children[2]]
      , app.project.rootItem);
  </code></pre>
  <p>But got greeted with:</p>
  <pre><code>createNewSequenceFromClips is not a function
  </code></pre>
  <p>How can I automate creating a sequence from a set of clips?</p>
  
Tags: <ffmpeg><premiere><automation><mini-dv><extendscript>
Title: How can I automate creating a sequence from a set of clips?
UserDisplayName: Saaru Lindestøkke
ThreadText: # How can I automate creating a sequence from a set of clips?
  
  (Asked by: username_0 on 2020-10-08)
  
  I have a large amount of DV footage, which I want to convert into a video per day.
  
  I've tried doing this by scripting `ffmpeg`:
  
  ```bash
  ffmpeg -safe 0 -f concat -i day1-files.txt -fflags +igndts -ac 2 -ar 32000 -vf scale=768x576,setsar=1:1,yadif sq08_output.mov
  
  ```
  
  but results varied from perfect to garbled audio or video.
  
  Then I tried this manually in Premiere Pro with the following steps:
  
  1. Import footage of a single day
  2. Automate to sequence
  3. Export media
  
  Results were perfect (for the same clips that `ffmpeg` couldn't decode).
  
  As I have thousands of clips I don't want to repeat the Premiere Pro steps manually, so I looked into [Premiere Pro scripting](https://premiere-scripting-guide.readthedocs.io/)
  
  I completed step 1 with [`app.project.importFiles`](https://premiere-scripting-guide.readthedocs.io/general/project.html#project-importfiles):
  
  ```js
  app.project.importFiles(["day1-1.mov", "day1-2.mov", "day1-3.mov"], true, app.project.rootItem, false)
  
  ```
  
  I tried to do step 2 with [`app.project.createNewSequenceFromClips`](https://premiere-scripting-guide.readthedocs.io/general/project.html#project-createnewsequencefromclips):
  
  ```js
  app.project.createNewSequenceFromClips("sequenceName"
      , [app.project.rootItem.children[0]
      , app.project.rootItem.children[1]
      , app.project.rootItem.children[2]]
      , app.project.rootItem);
  
  ```
  
  But got greeted with:
  
  ```
  createNewSequenceFromClips is not a function
  
  ```
  
  How can I automate creating a sequence from a set of clips?
  
  **Tags:** ffmpeg, premiere, automation, mini-dv, extendscript
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_0 on 2020-10-09. Score: 0
  
  Apparently `createNewSequenceFromClips` was not available in my version of Premiere Pro (v14.0.1). When I updated to v14.4 all worked as it should.
  
  This [example script](https://gitlab.com/b_a/premiere-pro-automation) using that function works as expected.
  
  
  ---
  
  