Hi, and however ...
I have this source
https://www.dropbox.com/s/xpf07u7uc0kctwr/example.mp4?dl=0
need to generate a .wav file from this source using:
so I get this .wav fileCode:ffmpeg.exe -y -i example.mp4 -c:a pcm_s16le test.wav
https://www.dropbox.com/s/z7em0o1318qvi36/test.wav?dl=0
I try to put in timeline using edius and premiere the source file example.mp4 and in the audio track the result of ffmpeg test.wav
[Attachment 66279 - Click to enlarge]
[Attachment 66280 - Click to enlarge]
The source is a italian speeck however there is a litte non-sync audio between the source and the .wav? Why? thanks
+ Reply to Thread
Results 1 to 14 of 14
-
-
I have do:
Code:ffmpeg - i example.mp4
Code:[NULL @ 000002074030de40] Unable to find a suitable output format for 'pipe:' pipe:: Invalid argument
-
Code:
C:\>ffmpeg -i example.mp4 ffmpeg version 5.0.1-full_build-www.gyan.dev Copyright (c) 2000-2022 the FFmpeg developers built with gcc 11.2.0 (Rev7, Built by MSYS2 project) configuration: --enable-gpl --enable-version3 --enable-static --disable-w32threads --disable-autodetect --enable-fontconfig --enable-iconv --enable-gnutls --enable-libxml2 --enable-gmp --enable-bzlib --enable-lzma --enable-libsnappy --enable-zlib --enable-librist --enable-libsrt --enable-libssh --enable-libzmq --enable-avisynth --enable-libbluray --enable-libcaca --enable-sdl2 --enable-libdav1d --enable-libdavs2 --enable-libuavs3d --enable-libzvbi --enable-librav1e --enable-libsvtav1 --enable-libwebp --enable-libx264 --enable-libx265 --enable-libxavs2 --enable-libxvid --enable-libaom --enable-libopenjpeg --enable-libvpx --enable-mediafoundation --enable-libass --enable-frei0r --enable-libfreetype --enable-libfribidi --enable-liblensfun --enable-libvidstab --enable-libvmaf --enable-libzimg --enable-amf --enable-cuda-llvm --enable-cuvid --enable-ffnvcodec --enable-nvdec --enable-nvenc --enable-d3d11va --enable-dxva2 --enable-libmfx --enable-libshaderc --enable-vulkan --enable-libplacebo --enable-opencl --enable-libcdio --enable-libgme --enable-libmodplug --enable-libopenmpt --enable-libopencore-amrwb --enable-libmp3lame --enable-libshine --enable-libtheora --enable-libtwolame --enable-libvo-amrwbenc --enable-libilbc --enable-libgsm --enable-libopencore-amrnb --enable-libopus --enable-libspeex --enable-libvorbis --enable-ladspa --enable-libbs2b --enable-libflite --enable-libmysofa --enable-librubberband --enable-libsoxr --enable-chromaprint libavutil 57. 17.100 / 57. 17.100 libavcodec 59. 18.100 / 59. 18.100 libavformat 59. 16.100 / 59. 16.100 libavdevice 59. 4.100 / 59. 4.100 libavfilter 8. 24.100 / 8. 24.100 libswscale 6. 4.100 / 6. 4.100 libswresample 4. 3.100 / 4. 3.100 libpostproc 56. 3.100 / 56. 3.100 Input #0, mov,mp4,m4a,3gp,3g2,mj2, from 'example.mp4': Metadata: major_brand : mp42 minor_version : 0 compatible_brands: mp42mp41 creation_time : 2021-11-10T09:29:26.000000Z Duration: 00:01:09.35, start: 0.000000, bitrate: 10531 kb/s Stream #0:0[0x1](eng): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 125 kb/s (default) Metadata: creation_time : 2021-11-10T09:29:26.000000Z handler_name : #Mainconcept MP4 Sound Media Handler vendor_id : [0][0][0][0] Stream #0:1[0x2](eng): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 125 kb/s (default) Metadata: creation_time : 2021-11-10T09:29:26.000000Z handler_name : #Mainconcept MP4 Sound Media Handler vendor_id : [0][0][0][0] Stream #0:2[0x3](eng): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 125 kb/s (default) Metadata: creation_time : 2021-11-10T09:29:26.000000Z handler_name : #Mainconcept MP4 Sound Media Handler vendor_id : [0][0][0][0] Stream #0:3[0x4](eng): Audio: aac (LC) (mp4a / 0x6134706D), 48000 Hz, stereo, fltp, 125 kb/s (default) Metadata: creation_time : 2021-11-10T09:29:26.000000Z handler_name : #Mainconcept MP4 Sound Media Handler vendor_id : [0][0][0][0] Stream #0:4[0x5](eng): Video: h264 (High) (avc1 / 0x31637661), yuv420p(tv, bt709), 1920x1080 [SAR 1:1 DAR 16:9], 10025 kb/s, 25 fps, 25 tbr, 25k tbn (default) Metadata: creation_time : 2021-11-10T09:29:27.000000Z handler_name : ?Mainconcept Video Media Handler vendor_id : [0][0][0][0] encoder : AVC Coding At least one output file must be specified C:\>
-
Is your audiostream an aac?
If so, load your video into clever Ffmpeg-GUI, click convert audiostream, select your audiostream, click go to the encoder, select pcm as encoder and click convert.
The resulting wav file should be in synch. -
I downloaded & looked at both files.
MediaInfo shows no delay in either file.
You have 4 audio tracks in the example.mp4 file.
All 4 are .acc .
I believe you need to add a map command to your ffmpeg code.
I'm new to Clever but I would give it a try first.
Try using this code first:
Code:ffmpeg -i input(00).mp4 -map 0:a:0 output(00).m4a
Code:ffmpeg -i input(00).m4a output(00).wav
Last edited by cholla; 13th Aug 2022 at 16:03.
-
I have the same problem.
And I found this:
https://trac.ffmpeg.org/ticket/2325
Unfortunately, this looks like a bug in ffmpeg. -
I have try
Code:ffmpeg -i example.mp4 -map 0:a:0 output(00).m4a
Code:ffmpeg -i output(00).m4a output(00).wav
[Attachment 66311 - Click to enlarge] -
@ marcorocchini ,
I don't have a software that shows the timeline type graphs edius and premiere do.
I also don't speak Italian but I found a part of the video where a man was talking & the lipsync looked OK to me.
The video I created with the video extracted from your original video & the .wav file I created form the extracted .m4a.
There is a 00:00:00.013 difference in the video & audio.
HTML Code:Duration: 00:01:09.33, start: 0.000000, bitrate: 11564 kb/s Stream #0:0(eng): Video: h264 (High), yuv420p(tv, bt709), 1920x1080 [SAR 1:1 DAR 16:9], 25 fps, 25 tbr, 1k tbn, 50 tbc (default) Metadata: HANDLER_NAME : ?Mainconcept Video Media Handler DURATION : 00:01:09.320000000 Stream #0:1: Audio: pcm_s16le, 48000 Hz, 2 channels, s16, 1536 kb/s (default) Metadata: DURATION : 00:01:09.333000000
Try it in edius and premiere to see what the graphs show.
I did use -vsync -1 in the code to maybe make the sync be better.
I also took a look at the example.mp4 with AVStoDVD.
Its' Title Info(detailed shows this:
For the video: Time: 00:01:09.320
For the Audio: Time: 00:01:09.355
This means the origin is not in sync.Last edited by cholla; 14th Aug 2022 at 11:02.
-
00:00:00.013 is nothing to get bent out of shape about.
The framerate of the video is 25FPS, so the duration of each frame is 1/25th of a second or 0.040. The maximum amount of delay that can happen and yet still have the audio fall alongside the same frame of video is 1/2 (50%) of that or 0.020. Your delay isn't even that bad, so it hasn't even slipped a single frame (assuming your measurements are correct).
It's not like you are trying to sync 1 audio with another similar audio and worrying about phasing/flanging. A/V sync lowest common denominator is video framerate which is crude in comparison to audio samplerate resolution.
Scott -
@ Scott,
I agree with you on the very small amount of time.
It was the OP that had a problem with the sync.
I didn't find the original AV file much longer that the audio tracks.
I would have been OK with the original myself.
The thread started with just wanting to extract a .wav from the av.
I just decided to play with it & see what I could do.
Similar Threads
-
FFmpeg - video with a PNG and a WAV as long as the WAV
By frenksisco in forum EditingReplies: 6Last Post: 8th Apr 2022, 13:07 -
Can't get FFMPEG Script to Remux to MP4 with Wav, It instead remuxes to MKV
By VideoFanatic in forum Video ConversionReplies: 3Last Post: 1st Aug 2021, 02:32 -
Audio out of sync when using ffmpeg, adelay, and amix
By AspiringVideoProcessor in forum Video ConversionReplies: 7Last Post: 1st Feb 2021, 07:40 -
Muxing wav&mpeg2 to ts using ffmpeg, losing audio :/
By Selur in forum Newbie / General discussionsReplies: 1Last Post: 22nd Sep 2019, 16:18 -
FFMPEG how to merge 2 stereo .wav audio files into one of 4 channels?
By marcorocchini in forum Newbie / General discussionsReplies: 4Last Post: 24th Jun 2018, 07:25