I'm using the following command to generate a watermarked 320Kbps MP3 preview of a wav file:
ffmpeg -i /path/input.wav -y -filter_complex "amovie=/path/wm_padded.wav:loop=0,asetpts=N/SR/TB,adelay=3000|3000[beep];[0][beep]amix=duration=shortest,volume=2" -b:a 320k /path/preview.mp3
(wm_padded.wav is the watermark file padded to 10 seconds and I'm using a Mac. The command was structured based on this post)
While this works as expected at times, it produces a short, garbled preview some other times. Any help in debugging this issue would be greatly appreciated. I've verified the input file and it seems to be fine and here's the FFMPEG command output:
$ ffmpeg -i /path/input.wav -y -filter_complex "amovie=/path/wm_padded.wav:loop=0,asetpts=N/SR/TB,adelay=3000|3000[beep];[0][beep]amix=duration=shortest,volume=2" -b:a 320k -vsync 2 /path/test-Preview.mp3
ffmpeg version 4.2.1 Copyright (c) 2000-2019 the FFmpeg developers
built with Apple clang version 11.0.0 (clang-1100.0.33.8)
configuration: --prefix=/usr/local/Cellar/ffmpeg/4.2.1_2 --enable-shared --enable-pthreads --enable-version3 --enable-avresample --cc=clang --host-cflags='-I/Library/Java/JavaVirtualMachines/adoptopenjdk-13.jdk/Contents/Home/include -I/Library/Java/JavaVirtualMachines/adoptopenjdk-13.jdk/Contents/Home/include/darwin -fno-stack-check' --host-ldflags= --enable-ffplay --enable-gnutls --enable-gpl --enable-libaom --enable-libbluray --enable-libmp3lame --enable-libopus --enable-librubberband --enable-libsnappy --enable-libtesseract --enable-libtheora --enable-libvidstab --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libx265 --enable-libxvid --enable-lzma --enable-libfontconfig --enable-libfreetype --enable-frei0r --enable-libass --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-librtmp --enable-libspeex --enable-libsoxr --enable-videotoolbox --disable-libjack --disable-indev=jack
libavutil 56. 31.100 / 56. 31.100
libavcodec 58. 54.100 / 58. 54.100
libavformat 58. 29.100 / 58. 29.100
libavdevice 58. 8.100 / 58. 8.100
libavfilter 7. 57.100 / 7. 57.100
libavresample 4. 0. 0 / 4. 0. 0
libswscale 5. 5.100 / 5. 5.100
libswresample 3. 5.100 / 3. 5.100
libpostproc 55. 5.100 / 55. 5.100
[wav # 0x7ff2ba801a00] Discarding ID3 tags because more suitable tags were found.
Guessed Channel Layout for Input Stream #0.0 : stereo
Input #0, wav, from '/path/input.wav':
Metadata:
comment : motion graphics, motion, textures
time_reference : 0
coding_history :
Duration: 00:00:01.75, bitrate: 1520 kb/s
Stream #0:0: Audio: pcm_s16le ([1][0][0][0] / 0x0001), 44100 Hz, stereo, s16, 1411 kb/s
Stream #0:1: Video: mjpeg (Baseline), yuvj420p(pc, bt470bg/unknown/unknown), 288x288 [SAR 72:72 DAR 1:1], 90k tbr, 90k tbn, 90k tbc (attached pic)
Metadata:
comment : Cover (front)
[Parsed_amovie_0 # 0x7ff2b9d0c040] Channel layout is not set in output stream 0, guessed channel layout is 'stereo'
Stream mapping:
Stream #0:0 (pcm_s16le) -> amix:input0 (graph 0)
volume (graph 0) -> Stream #0:0 (libmp3lame)
Stream #0:1 -> #0:1 (mjpeg (native) -> png (native))
Press [q] to stop, [?] for help
[swscaler # 0x108d00000] deprecated pixel format used, make sure you did set range correctly
[Parsed_amovie_0 # 0x7ff2b9e09840] Channel layout is not set in output stream 0, guessed channel layout is 'stereo'
Output #0, mp3, to '/path/preview.mp3':
Metadata:
comment : motion graphics, motion, textures
time_reference : 0
coding_history :
TSSE : Lavf58.29.100
Stream #0:0: Audio: mp3 (libmp3lame), 44100 Hz, stereo, fltp, 320 kb/s
Metadata:
encoder : Lavc58.54.100 libmp3lame
Stream #0:1: Video: png, rgb24(progressive), 288x288 [SAR 1:1 DAR 1:1], q=2-31, 200 kb/s, 90k fps, 90k tbn, 90k tbc (attached pic)
Metadata:
comment : Cover (front)
encoder : Lavc58.54.100 png
frame= 1 fps=0.0 q=-0.0 Lsize= 206kB time=00:00:00.10 bitrate=15994.8kbits/s speed=3.62x
video:200kB audio:5kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.598223%
Thanks in advance!
Upgrading to FFMPEG 2.8 solved the problem. On Mac, use:
brew install ffmpeg#2.8
Related
I have a movie that I have encoded using Handbrake on a Mac a long time ago. When I encoded the movie, I put the stereo audio as track 1 and the 5.1 audio as track 2. The starting filesize is 853,320,914 bytes. Below is the data from ffprobe.
ffprobe version 4.2.1-tessus https://evermeet.cx/ffmpeg/ Copyright (c) 2007-2019 the FFmpeg developers
built with Apple LLVM version 10.0.1 (clang-1001.0.46.4)
configuration: --cc=/usr/bin/clang --prefix=/opt/ffmpeg --extra-version=tessus --enable-avisynth --enable-fontconfig --enable-gpl --enable-libaom --enable-libass --enable-libbluray --enable-libdav1d --enable-libfreetype --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libmysofa --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenh264 --enable-libopenjpeg --enable-libopus --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvmaf --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-libzimg --enable-libzmq --enable-libzvbi --enable-version3 --pkg-config-flags=--static --disable-ffplay
libavutil 56. 31.100 / 56. 31.100
libavcodec 58. 54.100 / 58. 54.100
libavformat 58. 29.100 / 58. 29.100
libavdevice 58. 8.100 / 58. 8.100
libavfilter 7. 57.100 / 7. 57.100
libswscale 5. 5.100 / 5. 5.100
libswresample 3. 5.100 / 3. 5.100
libpostproc 55. 5.100 / 55. 5.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'Annabelle - Comes Home (2019).m4v':
Metadata:
major_brand : mp42
minor_version : 512
compatible_brands: isomiso2avc1mp41
creation_time : 2020-04-06T22:40:36.000000Z
encoder : HandBrake 1.1.2 2018090500
Duration: 01:46:04.86, start: 0.000000, bitrate: 1072 kb/s
Chapter #0:0: start 0.000000, end 476.986000
Metadata:
title : Chapter 1
Chapter #0:1: start 476.986000, end 933.608000
Metadata:
title : Chapter 2
Chapter #0:2: start 933.608000, end 1441.449000
Metadata:
title : Chapter 3
Chapter #0:3: start 1441.449000, end 1976.358000
Metadata:
title : Chapter 4
Chapter #0:4: start 1976.358000, end 2579.753000
Metadata:
title : Chapter 5
Chapter #0:5: start 2579.753000, end 3149.030000
Metadata:
title : Chapter 6
Chapter #0:6: start 3149.030000, end 3726.941000
Metadata:
title : Chapter 7
Chapter #0:7: start 3726.941000, end 3973.520000
Metadata:
title : Chapter 8
Chapter #0:8: start 3973.520000, end 4504.676000
Metadata:
title : Chapter 9
Chapter #0:9: start 4504.676000, end 4904.409000
Metadata:
title : Chapter 10
Chapter #0:10: start 4904.409000, end 5421.592000
Metadata:
title : Chapter 11
Chapter #0:11: start 5421.592000, end 5998.001000
Metadata:
title : Chapter 12
Chapter #0:12: start 5998.001000, end 6364.075000
Metadata:
title : Chapter 13
Stream #0:0(und): Video: h264 (Constrained Baseline) (avc1 / 0x31637661), yuv420p(tv, smpte170m/smpte170m/bt709), 720x360 [SAR 32:27 DAR 64:27], 519 kb/s, 23.98 fps, 23.98 tbr, 90k tbn, 180k tbc (default)
Metadata:
creation_time : 2020-04-06T22:40:36.000000Z
handler_name : VideoHandler
Stream #0:1(eng): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 162 kb/s (default)
Metadata:
creation_time : 2020-04-06T22:40:36.000000Z
handler_name : Stereo
Stream #0:2(eng): Audio: ac3 (ac-3 / 0x332D6361), 48000 Hz, 5.1(side), fltp, 384 kb/s
Metadata:
creation_time : 2020-04-06T22:40:36.000000Z
handler_name : Surround
Side data:
audio service type: main
Stream #0:3(eng): Data: bin_data (text / 0x74786574)
Metadata:
creation_time : 2020-04-06T22:40:36.000000Z
handler_name : SubtitleHandler
Unsupported codec with id 100359 for input stream 3
My goal is to swap the stereo audio track with the 5.1 audio track and make the 5.1 audio track the default without having to reencode. To do this, I used the following command:
ffmpeg -i "Annabelle - Comes Home (2019)/Annabelle - Comes Home (2019)_old.m4v" -map 0:v:0 -map 0:a:1 -map 0:a:0 -disposition:a:0 default -disposition:a:1 none -c copy "Annabelle - Comes Home (2019)/Annabelle - Comes Home (2019).m4v"
Everything works as it should, I think anyways as I didn't get any errors...
ffmpeg version 4.2.1-tessus https://evermeet.cx/ffmpeg/ Copyright (c) 2000-2019 the FFmpeg developers
built with Apple LLVM version 10.0.1 (clang-1001.0.46.4)
configuration: --cc=/usr/bin/clang --prefix=/opt/ffmpeg --extra-version=tessus --enable-avisynth --enable-fontconfig --enable-gpl --enable-libaom --enable-libass --enable-libbluray --enable-libdav1d --enable-libfreetype --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libmysofa --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenh264 --enable-libopenjpeg --enable-libopus --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvmaf --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-libzimg --enable-libzmq --enable-libzvbi --enable-version3 --pkg-config-flags=--static --disable-ffplay
libavutil 56. 31.100 / 56. 31.100
libavcodec 58. 54.100 / 58. 54.100
libavformat 58. 29.100 / 58. 29.100
libavdevice 58. 8.100 / 58. 8.100
libavfilter 7. 57.100 / 7. 57.100
libswscale 5. 5.100 / 5. 5.100
libswresample 3. 5.100 / 3. 5.100
libpostproc 55. 5.100 / 55. 5.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'Annabelle - Comes Home (2019)/Annabelle - Comes Home (2019)_old.m4v':
Metadata:
major_brand : mp42
minor_version : 512
compatible_brands: isomiso2avc1mp41
creation_time : 2020-04-06T22:40:36.000000Z
encoder : HandBrake 1.1.2 2018090500
Duration: 01:46:04.86, start: 0.000000, bitrate: 1072 kb/s
Chapter #0:0: start 0.000000, end 476.986000
Metadata:
title : Chapter 1
Chapter #0:1: start 476.986000, end 933.608000
Metadata:
title : Chapter 2
Chapter #0:2: start 933.608000, end 1441.449000
Metadata:
title : Chapter 3
Chapter #0:3: start 1441.449000, end 1976.358000
Metadata:
title : Chapter 4
Chapter #0:4: start 1976.358000, end 2579.753000
Metadata:
title : Chapter 5
Chapter #0:5: start 2579.753000, end 3149.030000
Metadata:
title : Chapter 6
Chapter #0:6: start 3149.030000, end 3726.941000
Metadata:
title : Chapter 7
Chapter #0:7: start 3726.941000, end 3973.520000
Metadata:
title : Chapter 8
Chapter #0:8: start 3973.520000, end 4504.676000
Metadata:
title : Chapter 9
Chapter #0:9: start 4504.676000, end 4904.409000
Metadata:
title : Chapter 10
Chapter #0:10: start 4904.409000, end 5421.592000
Metadata:
title : Chapter 11
Chapter #0:11: start 5421.592000, end 5998.001000
Metadata:
title : Chapter 12
Chapter #0:12: start 5998.001000, end 6364.075000
Metadata:
title : Chapter 13
Stream #0:0(und): Video: h264 (Constrained Baseline) (avc1 / 0x31637661), yuv420p(tv, smpte170m/smpte170m/bt709), 720x360 [SAR 32:27 DAR 64:27], 519 kb/s, 23.98 fps, 23.98 tbr, 90k tbn, 180k tbc (default)
Metadata:
creation_time : 2020-04-06T22:40:36.000000Z
handler_name : VideoHandler
Stream #0:1(eng): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 162 kb/s (default)
Metadata:
creation_time : 2020-04-06T22:40:36.000000Z
handler_name : Stereo
Stream #0:2(eng): Audio: ac3 (ac-3 / 0x332D6361), 48000 Hz, 5.1(side), fltp, 384 kb/s
Metadata:
creation_time : 2020-04-06T22:40:36.000000Z
handler_name : Surround
Side data:
audio service type: main
Stream #0:3(eng): Data: bin_data (text / 0x74786574)
Metadata:
creation_time : 2020-04-06T22:40:36.000000Z
handler_name : SubtitleHandler
[ipod # 0x7faff0014000] track 1: codec frame size is not set
Output #0, ipod, to 'Annabelle - Comes Home (2019)/Annabelle - Comes Home (2019).m4v':
Metadata:
major_brand : mp42
minor_version : 512
compatible_brands: isomiso2avc1mp41
encoder : Lavf58.29.100
Chapter #0:0: start 0.000000, end 476.986000
Metadata:
title : Chapter 1
Chapter #0:1: start 476.986000, end 933.608000
Metadata:
title : Chapter 2
Chapter #0:2: start 933.608000, end 1441.449000
Metadata:
title : Chapter 3
Chapter #0:3: start 1441.449000, end 1976.358000
Metadata:
title : Chapter 4
Chapter #0:4: start 1976.358000, end 2579.753000
Metadata:
title : Chapter 5
Chapter #0:5: start 2579.753000, end 3149.030000
Metadata:
title : Chapter 6
Chapter #0:6: start 3149.030000, end 3726.941000
Metadata:
title : Chapter 7
Chapter #0:7: start 3726.941000, end 3973.520000
Metadata:
title : Chapter 8
Chapter #0:8: start 3973.520000, end 4504.676000
Metadata:
title : Chapter 9
Chapter #0:9: start 4504.676000, end 4904.409000
Metadata:
title : Chapter 10
Chapter #0:10: start 4904.409000, end 5421.592000
Metadata:
title : Chapter 11
Chapter #0:11: start 5421.592000, end 5998.001000
Metadata:
title : Chapter 12
Chapter #0:12: start 5998.001000, end 6364.075000
Metadata:
title : Chapter 13
Stream #0:0(und): Video: h264 (Constrained Baseline) (avc1 / 0x31637661), yuv420p(tv, smpte170m/smpte170m/bt709), 720x360 [SAR 32:27 DAR 64:27], q=2-31, 519 kb/s, 23.98 fps, 23.98 tbr, 90k tbn, 90k tbc (default)
Metadata:
creation_time : 2020-04-06T22:40:36.000000Z
handler_name : VideoHandler
Stream #0:1(eng): Audio: ac3 (ac-3 / 0x332D6361), 48000 Hz, 5.1(side), fltp, 384 kb/s (default)
Metadata:
creation_time : 2020-04-06T22:40:36.000000Z
handler_name : Surround
Side data:
audio service type: main
Stream #0:2(eng): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 162 kb/s
Metadata:
creation_time : 2020-04-06T22:40:36.000000Z
handler_name : Stereo
Stream mapping:
Stream #0:0 -> #0:0 (copy)
Stream #0:2 -> #0:1 (copy)
Stream #0:1 -> #0:2 (copy)
Press [q] to stop, [?] for help
frame=152602 fps=12872 q=-1.0 Lsize= 834270kB time=01:46:04.79 bitrate=1073.8kbits/s speed= 537x
video:403702kB audio:424714kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: 0.706676%
Here is the resulting ffprobe of the new file showing it swapped the audio tracks:
ffprobe version 4.2.1-tessus https://evermeet.cx/ffmpeg/ Copyright (c) 2007-2019 the FFmpeg developers
built with Apple LLVM version 10.0.1 (clang-1001.0.46.4)
configuration: --cc=/usr/bin/clang --prefix=/opt/ffmpeg --extra-version=tessus --enable-avisynth --enable-fontconfig --enable-gpl --enable-libaom --enable-libass --enable-libbluray --enable-libdav1d --enable-libfreetype --enable-libgsm --enable-libmodplug --enable-libmp3lame --enable-libmysofa --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenh264 --enable-libopenjpeg --enable-libopus --enable-librubberband --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvmaf --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs --enable-libxvid --enable-libzimg --enable-libzmq --enable-libzvbi --enable-version3 --pkg-config-flags=--static --disable-ffplay
libavutil 56. 31.100 / 56. 31.100
libavcodec 58. 54.100 / 58. 54.100
libavformat 58. 29.100 / 58. 29.100
libavdevice 58. 8.100 / 58. 8.100
libavfilter 7. 57.100 / 7. 57.100
libswscale 5. 5.100 / 5. 5.100
libswresample 3. 5.100 / 3. 5.100
libpostproc 55. 5.100 / 55. 5.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'Annabelle - Comes Home (2019).m4v':
Metadata:
major_brand : M4V
minor_version : 512
compatible_brands: isomiso2avc1
encoder : Lavf58.29.100
Duration: 01:46:04.86, start: 0.000000, bitrate: 1073 kb/s
Chapter #0:0: start 0.000000, end 476.986000
Metadata:
title : Chapter 1
Chapter #0:1: start 476.986000, end 933.608000
Metadata:
title : Chapter 2
Chapter #0:2: start 933.608000, end 1441.449000
Metadata:
title : Chapter 3
Chapter #0:3: start 1441.449000, end 1976.358000
Metadata:
title : Chapter 4
Chapter #0:4: start 1976.358000, end 2579.753000
Metadata:
title : Chapter 5
Chapter #0:5: start 2579.753000, end 3149.030000
Metadata:
title : Chapter 6
Chapter #0:6: start 3149.030000, end 3726.941000
Metadata:
title : Chapter 7
Chapter #0:7: start 3726.941000, end 3973.520000
Metadata:
title : Chapter 8
Chapter #0:8: start 3973.520000, end 4504.676000
Metadata:
title : Chapter 9
Chapter #0:9: start 4504.676000, end 4904.409000
Metadata:
title : Chapter 10
Chapter #0:10: start 4904.409000, end 5421.592000
Metadata:
title : Chapter 11
Chapter #0:11: start 5421.592000, end 5998.001000
Metadata:
title : Chapter 12
Chapter #0:12: start 5998.001000, end 6364.075000
Metadata:
title : Chapter 13
Stream #0:0(und): Video: h264 (Constrained Baseline) (avc1 / 0x31637661), yuv420p(tv, smpte170m/smpte170m/bt709), 720x360 [SAR 32:27 DAR 64:27], 519 kb/s, 23.98 fps, 23.98 tbr, 90k tbn, 180k tbc (default)
Metadata:
handler_name : VideoHandler
Stream #0:1(eng): Audio: ac3 (ac-3 / 0x332D6361), 48000 Hz, 5.1(side), fltp, 384 kb/s (default)
Metadata:
handler_name : Surround
Side data:
audio service type: main
Stream #0:2(eng): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 162 kb/s
Metadata:
handler_name : Stereo
Stream #0:3(eng): Data: bin_data (text / 0x74786574)
Metadata:
handler_name : SubtitleHandler
Unsupported codec with id 100359 for input stream 3
What I don't understand is why is the file size different? The resulting file is larger at 854,292,790 bytes. Shouldn't the file sizes be the same since I literally just swapped tracks 0 and 1?
I'm using ffmpeg to create a mosaic of videos using the xstack filter. The input videos may come in varying dimensions, so I'm using the scale filter to scale them beforehand, and I'm using the force_original_aspect_ratio option and then the pad filter to keep the original aspect ratios of each video and add black bars to the sides to make each video have the correct dimensions.
I have a command that's working - however, it's inconsistent. For some dimensions it works, while for others it doesn't.
I'm using the fluent-ffmpeg Node.js module to call ffmpeg from Node.js. To do this, I'm passing an array of strings to the complexFilter() function.
The following strings for the complex filter works:
"[0:v]scale=400:250:force_original_aspect_ratio=decrease,pad=400:250:(ow-iw)/2:(oh-ih)/2 [s0]"
"[1:v]scale=400:250:force_original_aspect_ratio=decrease,pad=400:250:(ow-iw)/2:(oh-ih)/2 [s1]"
"[s0][s1]xstack=inputs=2:fill='black':layout=0_0|w0_0[v]"
"[0:a][1:a]amix=inputs=2[a]"
However, if I change the output dimensions of each video to be 400:225 instead of 400:250 it fails.
"[0:v]scale=400:225:force_original_aspect_ratio=decrease,pad=400:225:(ow-iw)/2:(oh-ih)/2 [s0]"
"[1:v]scale=400:225:force_original_aspect_ratio=decrease,pad=400:225:(ow-iw)/2:(oh-ih)/2 [s1]"
"[s0][s1]xstack=inputs=2:fill='black':layout=0_0|w0_0[v]"
"[0:a][1:a]amix=inputs=2[a]"
The following error is given:
An error occurred: ffmpeg exited with code 1: Error reinitializing filters!
Failed to inject frame into filter network: Invalid argument
Error while processing the decoded data for stream #1:1
Conversion failed!
If it's relevant, the first video has dimensions of 1280x720 while the second video has dimensions of 320x240.
Anyone know why one set of dimensions works while the other doesn't?
EDIT: Here is the full ffmpeg log for when it fails:
ffmpeg version git-2020-05-13-b12b053 Copyright (c) 2000-2020 the FFmpeg developers
built with gcc 9.3.1 (GCC) 20200513
configuration: --enable-gpl --enable-version3 --enable-sdl2 --enable-fontconfig --enable-gnutls --enable-iconv --enable-libass --enable-libdav1d --enable-libbluray --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libsrt --enable-libtheora --enable-libtwolame --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libzimg --enable-lzma --enable-zlib --enable-gmp --enable-libvidstab --enable-libvmaf --enable-libvorbis --enable-libvo-amrwbenc --enable-libmysofa --enable-libspeex --enable-libxvid --enable-libaom --disable-w32threads --enable-libmfx --enable-ffnvcodec --enable-cuda-llvm --enable-cuvid --enable-d3d11va --enable-nvenc --enable-nvdec --enable-dxva2 --enable-avisynth --enable-libopenmpt --enable-amf
libavutil 56. 45.100 / 56. 45.100
libavcodec 58. 84.100 / 58. 84.100
libavformat 58. 43.100 / 58. 43.100
libavdevice 58. 9.103 / 58. 9.103
libavfilter 7. 80.100 / 7. 80.100
libswscale 5. 6.101 / 5. 6.101
libswresample 3. 6.100 / 3. 6.100
libpostproc 55. 6.100 / 55. 6.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'C:/Users/user_name/Desktop/vids/vid1.mp4':
Metadata:
major_brand : mp42
minor_version : 0
compatible_brands: mp41isom
creation_time : 2020-05-21T15:52:20.000000Z
Duration: 00:00:10.76, start: 0.000000, bitrate: 8385 kb/s
Stream #0:0(und): Video: h264 (Main) (avc1 / 0x31637661), yuvj420p(pc), 1280x720 [SAR 1:1 DAR 16:9], 8237 kb/s, 29.99 fps, 30 tbr, 30k tbn, 60 tbc (default)
Metadata:
creation_time : 2020-05-21T15:52:20.000000Z
handler_name : VideoHandler
encoder : AVC Coding
Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 165 kb/s (default)
Metadata:
creation_time : 2020-05-21T15:52:20.000000Z
handler_name : SoundHandler
Input #1, mov,mp4,m4a,3gp,3g2,mj2, from 'C:/Users/user_name/Desktop/vids/vid2.mp4':
Metadata:
major_brand : mp42
minor_version : 0
compatible_brands: mp41isom
creation_time : 2020-05-21T15:54:37.000000Z
Duration: 00:00:11.01, start: 0.000000, bitrate: 836 kb/s
Stream #1:0(und): Video: h264 (Main) (avc1 / 0x31637661), yuvj420p(pc), 320x240 [SAR 1:1 DAR 4:3], 669 kb/s, 29.88 fps, 30 tbr, 30k tbn, 60 tbc (default)
Metadata:
creation_time : 2020-05-21T15:54:37.000000Z
handler_name : VideoHandler
encoder : AVC Coding
Stream #1:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 163 kb/s (default)
Metadata:
creation_time : 2020-05-21T15:54:37.000000Z
handler_name : SoundHandler
Stream mapping:
Stream #0:0 (h264) -> scale
Stream #0:1 (aac) -> amix:input0
Stream #1:0 (h264) -> scale
Stream #1:1 (aac) -> amix:input1
xstack -> Stream #0:0 (libx264)
amix -> Stream #0:1 (aac)
Press [q] to stop, [?] for help
[swscaler # 000001343fefc200] deprecated pixel format used, make sure you did set range correctly
[Parsed_pad_1 # 000001343f8dc3c0] Padded dimensions cannot be smaller than input dimensions.
[Parsed_pad_1 # 000001343f8dc3c0] Failed to configure input pad on Parsed_pad_1
Error reinitializing filters!
Failed to inject frame into filter network: Invalid argument
Error while processing the decoded data for stream #1:1
Conversion failed!
Done in 0.66s.
I found a work-around, if not necessarily a solution.
The following message shows up in the log posted in the question.
Padded dimensions cannot be smaller than input dimensions.
I found that if I decrease each of the dimensions passed to scale by 1 (so that they are always less than the dimensions passed to pad), then I don't seem to get the error anymore.
The following complex filter strings work:
"[0:v]scale=399:224:force_original_aspect_ratio=decrease,pad=400:225:(ow-iw)/2:(oh-ih)/2 [s0]"
"[1:v]scale=399:224:force_original_aspect_ratio=decrease,pad=400:225:(ow-iw)/2:(oh-ih)/2 [s1]"
"[s0][s1]xstack=inputs=2:fill='black':layout=0_0|w0_0[v]"
"[0:a][1:a]amix=inputs=2[a]"
This isn't ideal, and I still don't understand why it wasn't working before. I would guess there's a more graceful way around this, but at least this works.
The duration of the video changes from 7 minutes and 59 seconds to 7 minutes and 55 seconds.
I'm not sure what the issue is. But it's def eating up frames but i'm not sure what the issue is.
My command:
"ffmpeg -loglevel verbose -i '/secrets/secret.mkv' -vf fps=23.976 -qscale:v 3 -vf scale=720:540 '/secrets/lol5/SecretJpgs%05d.png' "
And well that's about it.
I would really appreciate it, if someone was willing to help me out with this.
Would mean a lot!!!
Edit: I Understand there are mistakes with my command, still doesn't explain why the duration is changed. Check the duration: and then check the time of the output, 7 mins and 55 secs. I clearly lost something somewhere. To make sure this wasn't an error i went back and converted the image sequence to video and it was 7 mins and 55 secs, unlike the source. The command was perfectly fine and i even set the fps twice using different commands , but it was something else. Please i would really appreciate it , if any one of you could help me out.
ffmpeg version 3.4.6-0ubuntu0.18.04.1 Copyright (c) 2000-2019 the FFmpeg developers
built with gcc 7 (Ubuntu 7.3.0-16ubuntu3)
configuration: --prefix=/usr --extra-version=0ubuntu0.18.04.1 --toolchain=hardened --libdir=/usr/lib/x86_64-linux-gnu --incdir=/usr/include/x86_64-linux-gnu --enable-gpl --disable-stripping --enable-avresample --enable-avisynth --enable-gnutls --enable-ladspa --enable-libass --enable-libbluray --enable-libbs2b --enable-libcaca --enable-libcdio --enable-libflite --enable-libfontconfig --enable-libfreetype --enable-libfribidi --enable-libgme --enable-libgsm --enable-libmp3lame --enable-libmysofa --enable-libopenjpeg --enable-libopenmpt --enable-libopus --enable-libpulse --enable-librubberband --enable-librsvg --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libspeex --enable-libssh --enable-libtheora --enable-libtwolame --enable-libvorbis --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx265 --enable-libxml2 --enable-libxvid --enable-libzmq --enable-libzvbi --enable-omx --enable-openal --enable-opengl --enable-sdl2 --enable-libdc1394 --enable-libdrm --enable-libiec61883 --enable-chromaprint --enable-frei0r --enable-libopencv --enable-libx264 --enable-shared
libavutil 55. 78.100 / 55. 78.100
libavcodec 57.107.100 / 57.107.100
libavformat 57. 83.100 / 57. 83.100
libavdevice 57. 10.100 / 57. 10.100
libavfilter 6.107.100 / 6.107.100
libavresample 3. 7. 0 / 3. 7. 0
libswscale 4. 8.100 / 4. 8.100
libswresample 2. 9.100 / 2. 9.100
libpostproc 54. 7.100 / 54. 7.100
[h264 # 0x56089f88a500] Reinit context to 1440x1088, pix_fmt: yuv420p
Input #0, matroska,webm, from '/secret/secrets/My secrets/Secret.mkv':
Metadata:
ENCODER : Lavf57.71.100
Duration: 00:07:59.08, start: 3.401000, bitrate: 5257 kb/s
Chapter #0:0: start 0.000000, end 113.594000
Metadata:
title : 00:02:23.643
Chapter #0:1: start 113.594000, end 479.000000
Metadata:
title : 00:09:54.594
Stream #0:0(eng): Video: h264 (High), 1 reference frame, yuv420p(progressive, left), 1440x1080 (1440x1088) [SAR 1:1 DAR 4:3], 23.98 fps, 23.98 tbr, 1k tbn, 47.95 tbc (default)
Metadata:
BPS : 5789491
BPS-eng : 5789491
DURATION-eng : 00:23:37.375000000
NUMBER_OF_FRAMES: 33983
NUMBER_OF_FRAMES-eng: 33983
NUMBER_OF_BYTES : 1025735076
NUMBER_OF_BYTES-eng: 1025735076
_STATISTICS_WRITING_APP: mkvmerge v8.3.0 ('Over the Horizon') 64bit
_STATISTICS_WRITING_APP-eng: mkvmerge v8.3.0 ('Over the Horizon') 64bit
_STATISTICS_WRITING_DATE_UTC: 2017-02-16 22:40:33
_STATISTICS_WRITING_DATE_UTC-eng: 2017-02-16 22:40:33
_STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
_STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
DURATION : 00:07:59.083000000
Stream #0:1(eng): Subtitle: ass (default) (forced)
Metadata:
title : English full
BPS : 35
BPS-eng : 35
DURATION-eng : 00:23:34.413000000
NUMBER_OF_FRAMES: 248
NUMBER_OF_FRAMES-eng: 248
NUMBER_OF_BYTES : 6265
NUMBER_OF_BYTES-eng: 6265
_STATISTICS_WRITING_APP: mkvmerge v8.3.0 ('Over the Horizon') 64bit
_STATISTICS_WRITING_APP-eng: mkvmerge v8.3.0 ('Over the Horizon') 64bit
_STATISTICS_WRITING_DATE_UTC: 2017-02-16 22:40:33
_STATISTICS_WRITING_DATE_UTC-eng: 2017-02-16 22:40:33
_STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
_STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
ENCODER : Lavc57.89.100 ssa
DURATION : 00:07:42.860000000
Stream mapping:
Stream #0:0 -> #0:0 (h264 (native) -> png (native))
Press [q] to stop, [?] for help
[h264 # 0x56089f88cd00] Reinit context to 1440x1088, pix_fmt: yuv420p
[Parsed_scale_0 # 0x56089f843ae0] w:720 h:540 flags:'bicubic' interl:0
[graph 0 input from stream 0:0 # 0x56089f843b80] w:1440 h:1080 pixfmt:yuv420p tb:1/1000 fr:24000/1001 sar:1/1 sws_param:flags=2
[Parsed_scale_0 # 0x56089f843ae0] w:1440 h:1080 fmt:yuv420p sar:1/1 -> w:720 h:540 fmt:rgb24 sar:1/1 flags:0x4
Output #0, image2, to '/secret/lol5/SecretJpgs%05d.png':
Metadata:
encoder : Lavf57.83.100
Chapter #0:0: start 0.000000, end 110.193000
Metadata:
title : 00:02:23.643
Chapter #0:1: start 110.193000, end 475.599000
Metadata:
title : 00:09:54.594
Stream #0:0(eng): Video: png, 1 reference frame, rgb24(left), 720x540 [SAR 1:1 DAR 4:3], q=2-31, 200 kb/s, 23.98 fps, 23.98 tbn, 23.98 tbc (default)
Metadata:
BPS : 5789491
BPS-eng : 5789491
DURATION-eng : 00:23:37.375000000
NUMBER_OF_FRAMES: 33983
NUMBER_OF_FRAMES-eng: 33983
NUMBER_OF_BYTES : 1025735076
NUMBER_OF_BYTES-eng: 1025735076
_STATISTICS_WRITING_APP: mkvmerge v8.3.0 ('Over the Horizon') 64bit
_STATISTICS_WRITING_APP-eng: mkvmerge v8.3.0 ('Over the Horizon') 64bit
_STATISTICS_WRITING_DATE_UTC: 2017-02-16 22:40:33
_STATISTICS_WRITING_DATE_UTC-eng: 2017-02-16 22:40:33
_STATISTICS_TAGS: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
_STATISTICS_TAGS-eng: BPS DURATION NUMBER_OF_FRAMES NUMBER_OF_BYTES
DURATION : 00:07:59.083000000
encoder : Lavc57.107.100 png
No more output streams to write to, finishing.
frame=11405 fps= 20 q=-0.0 Lsize=N/A time=00:07:55.68 bitrate=N/A speed=0.823x
video:4711858kB audio:0kB subtitle:0kB other streams:0kB global headers:0kB muxing overhead: unknown
Input file #0 (/secret/secrets/My secrets/Secret.mkv):
Input stream #0:0 (video): 11405 packets read (314757039 bytes); 11405 frames decoded;
Input stream #0:1 (subtitle): 0 packets read (0 bytes);
Total: 11405 packets (314757039 bytes) demuxed
Output file #0 (/secret/lol5/SecretJpgs%05d.png):
Output stream #0:0 (video): 11405 frames encoded; 11405 packets muxed (4824942145 bytes);
Total: 11405 packets (4824942145 bytes) muxed
No frames have been eaten.
See
Input stream #0:0 (video): 11405 packets read (314757039 bytes); 11405 frames decoded;
...
Output stream #0:0 (video): 11405 frames encoded; 11405 packets muxed (4824942145 bytes);
On the other hand, your command isn't working as intended.
-vf fps=23.976 ... -vf scale=720:540
Only the right hand side is being applied. To apply both filters, in that order, it has to be
-vf fps=24000/1001,scale=720:540
(24000/1001 is the exact representation for 23.976)
But this is not needed, as your video is already 24000/1001 fps. So just remove -vf fps=23.976 from your original command.
We are making 360 video player for VR headsets using Unity. We are trying to achieve spatial audio. The easiest case is when video and audio are in separated files, but now we decided to support also videos with embedded audio. I need to know before i load video if audio is ambisonic or not. I'm looking for an easy way to decide if audio is ambisonic in order to separate it from video and convert to .tbe file, which is currently supported by our app.
I was trying to use ffmpeg:
$./ffmpeg.exe -i ~/Videos/video.mp4
and got:
ffmpeg version 4.1.3 Copyright (c) 2000-2019 the FFmpeg developers
built with gcc 8.3.1 (GCC) 20190414
configuration: --enable-gpl --enable-version3 --enable-sdl2 --enable-fontconfig --enable-gnutls --enable-iconv --enable-libass --enable-libbluray --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-libopus --enable-libshine --enable-libsnappy --enable-libsoxr --enable-libtheora --enable-libtwolame --enable-libvpx --enable-libwavpack --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxml2 --enable-libzimg --enable-lzma --enable-zlib --enable-gmp --enable-libvidstab --enable-libvorbis --enable-libvo-amrwbenc --enable-libmysofa --enable-libspeex --enable-libxvid --enable-libaom --enable-libmfx --enable-amf --enable-ffnvcodec --enable-cuvid --enable-d3d11va --enable-nvenc --enable-nvdec --enable-dxva2 --enable-avisynth
libavutil 56. 22.100 / 56. 22.100
libavcodec 58. 35.100 / 58. 35.100
libavformat 58. 20.100 / 58. 20.100
libavdevice 58. 5.100 / 58. 5.100
libavfilter 7. 40.101 / 7. 40.101
libswscale 5. 3.100 / 5. 3.100
libswresample 3. 3.100 / 3. 3.100
libpostproc 55. 3.100 / 55. 3.100
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'C:/Users/Medion/Videos/video.mp4':
Metadata:
major_brand : isom
minor_version : 512
compatible_brands: isomiso2avc1mp41
encoder : Lavf57.56.101
Duration: 00:11:39.40, start: 0.000000, bitrate: 17290 kb/s
Stream #0:0(eng): Video: h264 (High) (avc1 / 0x31637661), yuv420p(tv, bt709), 3840x2160 [SAR 1:1 DAR 16:9], 16497 kb/s, 29.97 fps, 29.97 tbr, 30k tbn, 59.94 tbc (default)
Metadata:
handler_name : VideoHandler
Side data:
stereo3d: top and bottom
spherical: equirectangular (0.000000/0.000000/0.000000)
Stream #0:1(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, 4.0, fltp, 778 kb/s (default)
Metadata:
handler_name : SoundHandler
Stream #0:2(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, 4.0, fltp, 4 kb/s
Metadata:
handler_name : SoundHandler
Stream #0:3(und): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 2 kb/s
Metadata:
handler_name : SoundHandler
At least one output file must be specified
but I don't see any line that could indicate that audio is ambisonic. I see that there are 4 channels in streams #0:1 and #0:2, but I bet it's not enough.
I've also tried MediaInfo but it's the same thing:
General
CompleteName : C:\Users\Medion\Videos\video.mp4
Format/String : MPEG-4
Format_Profile : Base Media
CodecID/String : isom (isom/iso2/avc1/mp41)
FileSize/String : 1.41 GiB
Duration/String : 11 min 39 s
OverallBitRate_Mode/String : Variable
OverallBitRate/String : 17.3 Mb/s
Encoded_Application/String : Lavf57.56.101
Video
ID/String : 1
Format/String : AVC
Format/Info : Advanced Video Codec
Format_Profile : High#L5.2
Format_Settings : CABAC / 3 Ref Frames
Format_Settings_CABAC/String : Yes
Format_Settings_RefFrames/String : 3 frames
Format_Settings_GOP : M=3, N=29
CodecID : avc1
CodecID/Info : Advanced Video Coding
Duration/String : 11 min 39 s
BitRate_Mode/String : Variable
BitRate/String : 16.5 Mb/s
BitRate_Maximum/String : 20.0 Mb/s
Width/String : 3 840 pixels
Height/String : 2 160 pixels
DisplayAspectRatio/String : 16:9
FrameRate_Mode/String : Constant
FrameRate/String : 29.970 (30000/1001) FPS
Standard : NTSC
ColorSpace : YUV
ChromaSubsampling/String : 4:2:0
BitDepth/String : 8 bits
ScanType/String : Progressive
Bits-(Pixel*Frame) : 0.066
StreamSize/String : 1.34 GiB (95%)
Language/String : English
Tagged_Date : UTC 2017-06-13 17:37:51
colour_range : Limited
colour_primaries : BT.709
transfer_characteristics : BT.709
matrix_coefficients : BT.709
Codec configuration box : avcC
Audio #1
ID/String : 2
Format/String : AAC LC
Format/Info : Advanced Audio Codec Low Complexity
CodecID : mp4a-40-2
Duration/String : 11 min 39 s
Source_Duration/String : 11 min 39 s
BitRate_Mode/String : Constant
BitRate/String : 779 kb/s
Channel(s)/String : 4 channels
ChannelLayout : C L R Cb
SamplingRate/String : 48.0 kHz
FrameRate/String : 46.875 FPS (1024 SPF)
Compression_Mode/String : Lossy
StreamSize/String : 64.9 MiB (5%)
Source_StreamSize/String : 64.9 MiB (5%)
Default/String : Yes
AlternateGroup/String : 1
Tagged_Date : UTC 2017-06-13 17:37:51
Audio #2
ID/String : 3
Format/String : AAC LC
Format/Info : Advanced Audio Codec Low Complexity
CodecID : mp4a-40-2
Duration/String : 11 min 39 s
Source_Duration/String : 11 min 39 s
BitRate_Mode/String : Variable
BitRate/String : 4 900 b/s
BitRate_Maximum/String : 266 kb/s
Channel(s)/String : 4 channels
ChannelLayout : C L R Cb
SamplingRate/String : 48.0 kHz
FrameRate/String : 46.875 FPS (1024 SPF)
Compression_Mode/String : Lossy
StreamSize/String : 418 KiB (0%)
Source_StreamSize/String : 418 KiB (0%)
Default/String : No
AlternateGroup/String : 1
Tagged_Date : UTC 2017-06-13 17:37:51
Audio #3
ID/String : 4
Format/String : AAC LC
Format/Info : Advanced Audio Codec Low Complexity
CodecID : mp4a-40-2
Duration/String : 11 min 39 s
Source_Duration/String : 11 min 39 s
BitRate_Mode/String : Variable
BitRate/String : 2 275 b/s
BitRate_Maximum/String : 128 kb/s
Channel(s)/String : 2 channels
ChannelLayout : L R
SamplingRate/String : 48.0 kHz
FrameRate/String : 46.875 FPS (1024 SPF)
Compression_Mode/String : Lossy
StreamSize/String : 194 KiB (0%)
Source_StreamSize/String : 194 KiB (0%)
Default/String : No
AlternateGroup/String : 1
Tagged_Date : UTC 2017-06-13 17:37:51
I assume that I don't know what to look for in those outputs.
Thanks in advance.
MediaInfo development snapshots (mini 2190520-2) have now support of Spatial Audio RFC (draft) metadata (such metadata is in the file you provided as an example), and display information this way:
Channel layout : Ambisonics (W X Y Z)
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 8 years ago.
Improve this question
I have a pro-res file which has 6 mono audio channels.
here's the ffmpeg console:
:\test-remapping>ffmpeg -i MelleParadis_PART1_CONSTANTE.mov
ffmpeg version N-60106-ge6d1c66 Copyright (c) 2000-2014 the FFmpeg developers
built on Jan 22 2014 22:01:26 with gcc 4.8.2 (GCC)
configuration: --enable-gpl --enable-version3 --disable-w32threads --enable-av
isynth --enable-bzlib --enable-fontconfig --enable-frei0r --enable-gnutls --enab
le-iconv --enable-libass --enable-libbluray --enable-libcaca --enable-libfreetyp
e --enable-libgsm --enable-libilbc --enable-libmodplug --enable-libmp3lame --ena
ble-libopencore-amrnb --enable-libopencore-amrwb --enable-libopenjpeg --enable-l
ibopus --enable-librtmp --enable-libschroedinger --enable-libsoxr --enable-libsp
eex --enable-libtheora --enable-libtwolame --enable-libvidstab --enable-libvo-aa
cenc --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libwavp
ack --enable-libx264 --enable-libxavs --enable-libxvid --enable-zlib
libavutil 52. 63.100 / 52. 63.100
libavcodec 55. 49.100 / 55. 49.100
libavformat 55. 25.101 / 55. 25.101
libavdevice 55. 5.102 / 55. 5.102
libavfilter 4. 1.100 / 4. 1.100
libswscale 2. 5.101 / 2. 5.101
libswresample 0. 17.104 / 0. 17.104
libpostproc 52. 3.100 / 52. 3.100
Guessed Channel Layout for Input Stream #0.1 : mono
Guessed Channel Layout for Input Stream #0.2 : mono
Guessed Channel Layout for Input Stream #0.3 : mono
Guessed Channel Layout for Input Stream #0.4 : mono
Guessed Channel Layout for Input Stream #0.5 : mono
Guessed Channel Layout for Input Stream #0.6 : mono
Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'MelleParadis_PART1_CONSTANTE.mov':
Metadata:
major_brand : qt
minor_version : 537199360
compatible_brands: qt
creation_time : 2013-11-27 18:58:26
Duration: 00:07:34.32, start: 0.000000, bitrate: 117742 kb/s
Stream #0:0(eng): Video: prores (apcn / 0x6E637061), yuv422p10le, 1920x1080,
113098 kb/s, SAR 1:1 DAR 16:9, 25 fps, 25 tbr, 25 tbn, 25 tbc (default)
Metadata:
creation_time : 2013-11-27 18:58:26
handler_name : Gestionnaire dıalias Apple
timecode : 01:00:00:00
Stream #0:1(eng): Audio: pcm_s16le (sowt / 0x74776F73), 48000 Hz, mono, s16,
768 kb/s (default)
Metadata:
creation_time : 2013-11-27 18:58:26
handler_name : Gestionnaire dıalias Apple
Stream #0:2(eng): Audio: pcm_s16le (sowt / 0x74776F73), 48000 Hz, mono, s16,
768 kb/s (default)
Metadata:
creation_time : 2013-11-27 18:58:26
handler_name : Gestionnaire dıalias Apple
Stream #0:3(eng): Audio: pcm_s16le (sowt / 0x74776F73), 48000 Hz, mono, s16,
768 kb/s (default)
Metadata:
creation_time : 2013-11-27 18:58:26
handler_name : Gestionnaire dıalias Apple
Stream #0:4(eng): Audio: pcm_s16le (sowt / 0x74776F73), 48000 Hz, mono, s16,
768 kb/s (default)
Metadata:
creation_time : 2013-11-27 18:58:26
handler_name : Gestionnaire dıalias Apple
Stream #0:5(eng): Audio: pcm_s16le (sowt / 0x74776F73), 48000 Hz, mono, s16,
768 kb/s (default)
Metadata:
creation_time : 2013-11-27 18:58:26
handler_name : Gestionnaire dıalias Apple
Stream #0:6(eng): Audio: pcm_s16le (sowt / 0x74776F73), 48000 Hz, mono, s16,
768 kb/s (default)
Metadata:
creation_time : 2013-11-27 18:58:26
handler_name : Gestionnaire dıalias Apple
Stream #0:7(eng): Data: none (tmcd / 0x64636D74) (default)
Metadata:
creation_time : 2013-11-27 19:03:46
handler_name : Gestionnaire dıalias Apple
timecode : 01:00:00:00``
I would like to transform them into one 5.1 audio channel
I try this line of code:
D:\test-remapping>ffmpeg -i "MelleParadis_PART1_CONSTANTE.mov" -c copy -c:a ac3 -map 0 mlle5.1.mov
the console replies "NOT ENOUGH SPACE" and stop...
of course there's still some space in my hard drive...
How could I map all the 6 mono streams into 5.1 ?
thanks in advance.
pauline
from https://trac.ffmpeg.org/wiki/AudioChannelManipulation
ffmpeg -i front_left.wav -i front_right.wav -i front_center.wav -i lfe.wav -i back_left.wav -i back_right.wav \
-filter_complex "[0:a][1:a][2:a][3:a][4:a][5:a] amerge=inputs=6" output.wav