Skip to main content
Tweeted twitter.com/#!/StackAVP/status/434093394147962880
deleted 14 characters in body
Source Link

I have mxf files which went over the 2G limit, so were split up in the camera to produce two mxf files. They have two audio streams, one from each mic, like this:

Duration: 00:10:01.60, start: 0.000000, bitrate: 27165 kb/s
Stream #0:0: Video: mpeg2video (Main), yuv420p(tv, bt709), 1440x1080 [SAR 4:3 DAR 16:9], max. 25000 kb/s, 29.97 fps, 29.97 tbr, 29.97 tbn, 59.94 tbc
Stream #0:1: Audio: pcm_s16le, 48000 Hz, 1 channels, s16, 768 kb/s
Stream #0:2: Audio: pcm_s16le, 48000 Hz, 1 channels, s16, 768 kb/s

I know how to concatenate them with ffmpeg:

ffmpeg -i "concat:a01.mxf|b02.mxf" -y -c copy result.mxf

But, this combines the audio streams and produces a file with just one, merged stream.

I also know how to split out the individual audio streams into individual files:

ffmpeg -i a01.mxf -map 0:1 -vn one.aiff
ffmpeg -i a01.mxf -map 0:2 -vn two.aiff

Grabs stream the streams and correctly transfers the streamsthem across untouched.

My question is, how to do this for the split up mxfs? I could rip their sound, then join the video, then put the sound back in, but it seems really unnecessary, and there should be a way to use a big -map command to do all of this.

I have mxf files which went over the 2G limit, so were split up in the camera to produce two mxf files. They have two audio streams, one from each mic, like this:

Duration: 00:10:01.60, start: 0.000000, bitrate: 27165 kb/s
Stream #0:0: Video: mpeg2video (Main), yuv420p(tv, bt709), 1440x1080 [SAR 4:3 DAR 16:9], max. 25000 kb/s, 29.97 fps, 29.97 tbr, 29.97 tbn, 59.94 tbc
Stream #0:1: Audio: pcm_s16le, 48000 Hz, 1 channels, s16, 768 kb/s
Stream #0:2: Audio: pcm_s16le, 48000 Hz, 1 channels, s16, 768 kb/s

I know how to concatenate them with ffmpeg:

ffmpeg -i "concat:a01.mxf|b02.mxf" -y -c copy result.mxf

But, this combines the audio streams and produces a file with just one, merged stream.

I also know how to split out the individual audio streams into individual files:

ffmpeg -i a01.mxf -map 0:1 -vn one.aiff
ffmpeg -i a01.mxf -map 0:2 -vn two.aiff

Grabs stream the streams and correctly transfers the streams across untouched.

My question is, how to do this for the split up mxfs? I could rip their sound, then join the video, then put the sound back in, but it seems really unnecessary, and there should be a way to use a big -map command to do all of this.

I have mxf files which went over the 2G limit, so were split up in the camera to produce two mxf files. They have two audio streams, one from each mic, like this:

Duration: 00:10:01.60, start: 0.000000, bitrate: 27165 kb/s
Stream #0:0: Video: mpeg2video (Main), yuv420p(tv, bt709), 1440x1080 [SAR 4:3 DAR 16:9], max. 25000 kb/s, 29.97 fps, 29.97 tbr, 29.97 tbn, 59.94 tbc
Stream #0:1: Audio: pcm_s16le, 48000 Hz, 1 channels, s16, 768 kb/s
Stream #0:2: Audio: pcm_s16le, 48000 Hz, 1 channels, s16, 768 kb/s

I know how to concatenate them with ffmpeg:

ffmpeg -i "concat:a01.mxf|b02.mxf" -y -c copy result.mxf

But, this combines the audio streams and produces a file with just one, merged stream.

I also know how to split out the individual audio streams into individual files:

ffmpeg -i a01.mxf -map 0:1 -vn one.aiff
ffmpeg -i a01.mxf -map 0:2 -vn two.aiff

Grabs the streams and correctly transfers them across untouched.

My question is, how to do this for the split up mxfs? I could rip their sound, then join the video, then put the sound back in, but it seems really unnecessary, and there should be a way to use a big -map command to do all of this.

Source Link

How to concatenate two mxf files with ffmpeg, preserving both audio channels?

I have mxf files which went over the 2G limit, so were split up in the camera to produce two mxf files. They have two audio streams, one from each mic, like this:

Duration: 00:10:01.60, start: 0.000000, bitrate: 27165 kb/s
Stream #0:0: Video: mpeg2video (Main), yuv420p(tv, bt709), 1440x1080 [SAR 4:3 DAR 16:9], max. 25000 kb/s, 29.97 fps, 29.97 tbr, 29.97 tbn, 59.94 tbc
Stream #0:1: Audio: pcm_s16le, 48000 Hz, 1 channels, s16, 768 kb/s
Stream #0:2: Audio: pcm_s16le, 48000 Hz, 1 channels, s16, 768 kb/s

I know how to concatenate them with ffmpeg:

ffmpeg -i "concat:a01.mxf|b02.mxf" -y -c copy result.mxf

But, this combines the audio streams and produces a file with just one, merged stream.

I also know how to split out the individual audio streams into individual files:

ffmpeg -i a01.mxf -map 0:1 -vn one.aiff
ffmpeg -i a01.mxf -map 0:2 -vn two.aiff

Grabs stream the streams and correctly transfers the streams across untouched.

My question is, how to do this for the split up mxfs? I could rip their sound, then join the video, then put the sound back in, but it seems really unnecessary, and there should be a way to use a big -map command to do all of this.