Synchronizing audio and video

Microsoft Windows specific usage questions
Forum rules
Please post only Windows specific questions in this forum category. If you don't know where to post, please read the different forums' rules. Thanks.
radar
Blank Cone
Blank Cone
Posts: 10
Joined: 27 Jun 2011 15:11

Synchronizing audio and video

Postby radar » 29 Aug 2012 18:32

I have an .mp4 video file I created by using camtasia to screen capture a webinar. The problem I have is that the audio and video are not in sync. The audio seems to be, maybe, 60 sec or so ahead of the video. How can I correct this? I've tried entering -55 sec in the Synchronization tab of the Adjustments and Effects tool, but this did not seem to have any affect on the audio stream..

thanks

Arite
Big Cone-huna
Big Cone-huna
Posts: 2478
Joined: 26 Jun 2007 20:40
VLC version: 3.0.20
Operating System: Debian Testing|Win10

Re: Synchronizing audio and video

Postby Arite » 29 Aug 2012 19:15

If the audio is 60 seconds ahead of the video then you'll want to delay it by 60 seconds (so +60 seconds).

You might need to increase the file caching value to something bigger as well as the default of 300ms doesn't seem to be enough. I tried 20000ms (20 seconds).

To change the file caching value go to:
Tools >> Preferences >> (Select "All" for "show settings) >> Input / Codecs

And find the "File caching" value in the "Advanced" section.

Then instead of using the Adjustment and Effects dialog to change it, use the hotkeys. Hold "K" down to increase ("J" to decrease) the value by something lower than the caching value. Say 10/15 seconds (10s = 10000ms) if you went for 20000ms for caching. Let go and wait for VLC to catch up. Then do that again several times until you reach your desired delay of e.g. 55000ms.

Maybe the caching value doesn't make much difference, however too big a step doesn't seem to work, so vary it using the hotkeys by 10/15 seconds at a time.

However you may instead want to edit the file using something like Avidemux though as 60 seconds is a big delay.

Arite.
Don't use PMs for support questions.

radar
Blank Cone
Blank Cone
Posts: 10
Joined: 27 Jun 2011 15:11

Re: Synchronizing audio and video

Postby radar » 02 Sep 2012 04:12

thanks for the suggestions. As you suspected, increasing the file caching did not help. Can you please explain what I should do to edit the file using Avidemux?

Thanks
radar

Arite
Big Cone-huna
Big Cone-huna
Posts: 2478
Joined: 26 Jun 2007 20:40
VLC version: 3.0.20
Operating System: Debian Testing|Win10

Re: Synchronizing audio and video

Postby Arite » 02 Sep 2012 04:37

So slowly increasing the delay by several seconds at a time using the "K" hotkey didn't work?

To do it using Avidemux you import the video and change the audio from "Copy" to a codec you desire (the codec it's currently in is probably best). Then you can click on "Filters" and enter in a time shift (in ms). For example +60 seconds (so "60000") will play the first 60 seconds with the original out-of-sync sound, and then after that audio will start again/skip back to the beginning, hence being time shifted/delayed by 60 seconds.

Pick your ouput format of choice (again the same as the input is probably best), and go to "File >> Save >> Save Video..." etc. and call it what you want (with the file extension). When finished it should play in VLC OK. As it's might possibly still be a bit out of sync, you can use "K" ans "J" in VLC to adjust the audio delay it by a few seconds/milliseconds when playing it.

Cheers, Arite.
Don't use PMs for support questions.

userbg
Blank Cone
Blank Cone
Posts: 25
Joined: 16 Aug 2012 13:14

Re: Synchronizing audio and video

Postby userbg » 02 Sep 2012 12:53

Look. I was try recording [url=rtsp://31.13.218.243:1935/rtplive/nova_1000kbps.stream]This RTSP[/url] from any computer. The output file is MP4. I noticed that on every one computer VLC play MP4 video stream too much slow. While audio stream is playing normal (original). You can try some recording and will notice that MP4 is corrupt or maybe unplayable, because of VLC reason.

userbg
Blank Cone
Blank Cone
Posts: 25
Joined: 16 Aug 2012 13:14

Re: Synchronizing audio and video

Postby userbg » 03 Sep 2012 19:01

Look. I was try recording [url=rtsp://31.13.218.243:1935/rtplive/nova_1000kbps.stream]This RTSP[/url] from any computer. The output file is MP4. I noticed that on every one computer VLC play MP4 video stream too much slow. While audio stream is playing normal (original). You can try some recording and will notice that MP4 is corrupt or maybe unplayable, because of VLC reason.
Is there solution for this?

Arite
Big Cone-huna
Big Cone-huna
Posts: 2478
Joined: 26 Jun 2007 20:40
VLC version: 3.0.20
Operating System: Debian Testing|Win10

Re: Synchronizing audio and video

Postby Arite » 05 Sep 2012 02:57

Look. I was try recording [url=rtsp://31.13.218.243:1935/rtplive/nova_1000kbps.stream]This RTSP[/url] from any computer. The output file is MP4. I noticed that on every one computer VLC play MP4 video stream too much slow. While audio stream is playing normal (original). You can try some recording and will notice that MP4 is corrupt or maybe unplayable, because of VLC reason.
This really belongs in a different topic as it's about a completely different issue (albeit the title being suitable).

However, your issue should be fixed by disabling clock synchronisation. To do this go to:
Tools >> Preferences >> (Select "All" for "Show settings") >> Input / Codecs

Then scroll down to the "Advanced" section and change the "Clock synchronisation" to "Disable". Click "Save" and try the stream again.

It may not be perfect as the audio may get out of sync with the video and it might need to rebuffer a few times - however the regular sync issue should go away.

Cheers, Arite.
Don't use PMs for support questions.


Return to “VLC media player for Windows Troubleshooting”

Who is online

Users browsing this forum: No registered users and 36 guests