PDA

View Full Version : Easy way to fix out of synch audio?


Dr.Khron
20th November 2006, 17:09
Ok, so when I manually recreated a new .d2v project file for this rip, I forgot to re-mux the audio. Since I snipped a piece off the begining of the movie, and then used the audio track muxed from the full-length .d2v, the audio track is about 10 seconds out of synch with the finished movie.

Yes, I know the best answer is to start over and do it right, but it took 8 hours to encode the video, so I'd rather work the files that I have:

Movie_Movie.avi (the main video with no sound)
Movie_Credits.avi (the credits from the movie, no sound)
Movie_sound.mp3 (the sound track, which is a VBR from BeSweet)

Is there an easy way to just remix these all together with a different delay time?

I tried opening it directly with VirtualDub, but I couldn't figure out how to re-process the finsished AVI without recoding any of the video.

According to the GK log, this process only took GK 1 min and 58 seconds, so there must be a fast way to do it:

12:04:07 AM: Started Appending Credits and Muxing Audio.: D:\DVD Ripping temp\Movie\Movie_Movie.avi
12:06:05 AM: Finished Appending Credits and Muxing Audio.: Duration: 1 minute, 58 seconds.

12:06:05 AM: Done.
12:06:05 AM: Movie = D:\DVD Ripping temp\Movie\Movie.avi
Total Encoding Time: 8 hours, 55 minutes, 3 seconds.

Advice, please?

dwm4444
20th November 2006, 18:33
I switched from Virtualdub to Virtualdubmod a couple of years ago, one reason being it supposedly handles vbr mp3 in AVI better (vbr not being part of the AVI spec). Anyway, here's what I'd do in Vdubmod:

Open the video file. (This next bit assumes video and audio are still separate files). Click on "Streams"..."Stream list". In the resulting "Available Streams" window, click on the "Add" box and point it to your audio file. Then after the box for the audio file comes up in the window, right-click it and select "Interleaving..." from the pop-up. In the "Audio Skew Correction" section, in the box marked "Delay audio track by" put in 10000 (for 10 seconds, adjust to taste). At the bottom, "Cut off audio when video stream ends" should already be checked.

Click "OK" on this box and the "Available streams" box to back up to the main window. Now, to keep from re-encoding the video, click on "Video" then "Direct stream copy". A black circle will show up next to it. Now just save the video and you should be good to go.

I'm not sure if your video has the sound already muxed in it or not; if so, it will already be in the "available streams" box so disregard adding it and just change the delay. If Vdubmod asks if you want it to re-write the header when you open the file tell it no. It does that when it sees a file with vbr. Don't worry about it.

Media Player Classic is good for fine-tuning your delay if you need to (and you probably will). Right click your newly muxed video, click "audio", "options", "audio switcher", then try delay settings in the "delay audio by" box until your lip sync matches up. You have to stop play, adjust, click apply, then re-start play to see the changes. When you get it right, go back to Vdubmod and apply that same delay in the interleave section and re-save your video. Direct stream copy on the video again, of course.

Good luck.

Dr.Khron
20th November 2006, 18:56
Good answer, thank you very much!

I was able to figure most of that by fiddeling around with VirtualDubMod, but I was missing a few key points, including where to set the new "interleave"... and I looked all over for that damn function!

Will give it a shot, thanks again.

Dr.Khron
20th November 2006, 19:19
Ah, that worked perfectly!

Thanks for the tip about windows media player classic... I didn't know how I was going to get the offset right. But I came up with a different workaround: I remuxed the track with the updated .d2v file, and the name of the resulting AC3 file had the exact offset I needed! (-337)

Therfore, I was able to run it through VirtualDubMod without any guesswork, and it works great!