Answers.Body: <p>The method in my comment still stands.</p>
  
  <p>Let's say you have two audio tracks. Basic command syntax is</p>
  
  <pre><code>ffmpeg -i picsou.mp4 \
         -i audio1.wav \
         -i audio2.wav \
         - filter_complex "[1:a]adelay=30000|30000[1a];\
                           [2:a]adelay=35000|35000[2a]" \
        -map 0:v -map "[1a]" -map "[2a]" -c:v copy -shortest \
    out.mxf
  </code></pre>
  
  <p>The adelay filter here expects two channels per input stream. Channel delay values are in milliseconds.</p>
  
  <p>On linux / OSX you may have to use single quotes around the arguments.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-09-23T10:02:33.353Z
Answers.Text: Pro Tools support MXF OPATOM, so you need to precise it with the following parameter `-f mxf_opatom`
Answers.UserDisplayName: Martin Delille
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-09-23T10:16:32.280Z
Answers.Text: Opatom only supports a single stream. In your Q, you state, "*I would like to create a new MXF media with the video file and mixing the audio files at specific timestamp and tracks:*" which can't be done with Op Atom.
Answers.UserDisplayName: Gyan
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-09-24T11:24:22.133Z
Answers.Text: Yes I know. I finally understood that MXF was a dead end and I will need to generate an OMF. I'll test your solution in order to generate a wav in the meantime!
Answers.UserDisplayName: Martin Delille
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-09-24T11:25:24.710Z
Answers.Text: Maybe I should update my question to go back to the audio pcm question if you don't mine?
Answers.UserDisplayName: Martin Delille
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-09-14T17:45:46.117Z
Answers.LastActivityDate: 2018-09-14T17:45:46.117Z
Answers.UserDisplayName: Gyan
Body: <p>I have several media:</p>
  
  <ul>
  <li>one video file</li>
  <li>several audio files</li>
  </ul>
  
  <p>I would like to create a new MXF media with the video file and mixing the audio files at specific timestamp and tracks:</p>
  
  <ul>
  <li>Starting time of the video file on the track 0: <code>00:00:00:00</code></li>
  <li>Starting time of the audio clip 1 on the track 1: <code>00:00:30:00</code></li>
  <li>Starting time of the audio clip 2 on the track 2: <code>00:00:35:00</code></li>
  <li>Starting time of the audio clip 3 on the track 2: <code>00:00:45:00</code></li>
  <li>...</li>
  </ul>
  
  <p>I made a first try with just with one video and one audio. I used the following command:</p>
  
  <pre><code>ffmpeg -y -i picsou.mp4 \
    -itsoffset 2 \
    -i picsou.wav \
    -shortest \
    out.mp4
  </code></pre>
  
  <p>Unfortunately, when I import it in <em>Pro Tools</em>, I cannot see the audio.</p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-09-11T14:05:53.257Z
Comments.Text: Adapt the method at https://stackoverflow.com/a/48169214/5726027
Comments.UserDisplayName: Gyan
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-09-11T14:24:41.520Z
Comments.Text: @Gyan when I look as the solution you propose, it seems that the `adelay` filter delay the full channel...
Comments.UserDisplayName: Martin Delille
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-09-11T15:15:18.740Z
Comments.Text: Share your command.
Comments.UserDisplayName: Gyan
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-09-14T16:26:49.080Z
Comments.Text: Ok the `-itsoffset` option solved my problem but change a little bit the subject to explain exactly what I want to do: a MXF file.
Comments.UserDisplayName: Martin Delille
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2018-09-14T16:59:22.030Z
Comments.Text: for *Pro Tools*
Comments.UserDisplayName: Martin Delille
Tags: <ffmpeg><timecode>
Title: Create a MXF media with a video and audio clip at specific timing compatible with Pro Tools
UserDisplayName: Martin Delille
ThreadText: # Create a MXF media with a video and audio clip at specific timing compatible with Pro Tools
  
  (Asked by: username_0 on 2018-09-11)
  
  I have several media:
  
  * one video file
  * several audio files
  
  I would like to create a new MXF media with the video file and mixing the audio files at specific timestamp and tracks:
  
  * Starting time of the video file on the track 0: `00:00:00:00`
  * Starting time of the audio clip 1 on the track 1: `00:00:30:00`
  * Starting time of the audio clip 2 on the track 2: `00:00:35:00`
  * Starting time of the audio clip 3 on the track 2: `00:00:45:00`
  * ...
  
  I made a first try with just with one video and one audio. I used the following command:
  
  ```
  ffmpeg -y -i picsou.mp4 \
    -itsoffset 2 \
    -i picsou.wav \
    -shortest \
    out.mp4
  
  ```
  
  Unfortunately, when I import it in *Pro Tools*, I cannot see the audio.
  
  **Tags:** ffmpeg, timecode
  
  > **Comments:**
  > **username_1**: Adapt the method at https://stackoverflow.com/a/48169214/5726027  
  > **username_0**: @username_1 when I look as the solution you propose, it seems that the `adelay` filter delay the full channel...  
  > **username_1**: Share your command.  
  > **username_0**: Ok the `-itsoffset` option solved my problem but change a little bit the subject to explain exactly what I want to do: a MXF file.  
  > **username_0**: for *Pro Tools*  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2018-09-14. Score: 1
  
  The method in my comment still stands.
  
  Let's say you have two audio tracks. Basic command syntax is
  
  ```
  ffmpeg -i picsou.mp4 \
         -i audio1.wav \
         -i audio2.wav \
         - filter_complex "[1:a]adelay=30000|30000[1a];\
                           [2:a]adelay=35000|35000[2a]" \
        -map 0:v -map "[1a]" -map "[2a]" -c:v copy -shortest \
    out.mxf
  
  ```
  
  The adelay filter here expects two channels per input stream. Channel delay values are in milliseconds.
  
  On linux / OSX you may have to use single quotes around the arguments.
  
  > **Comments:**
  > **username_0**: Pro Tools support MXF OPATOM, so you need to precise it with the following parameter `-f mxf_opatom`  
  > **username_1**: Opatom only supports a single stream. In your Q, you state, "*I would like to create a new MXF media with the video file and mixing the audio files at specific timestamp and tracks:*" which can't be done with Op Atom.  
  > **username_0**: Yes I know. I finally understood that MXF was a dead end and I will need to generate an OMF. I'll test your solution in order to generate a wav in the meantime!  
  > **username_0**: Maybe I should update my question to go back to the audio pcm question if you don't mine?  
  
  ---
  
  