VideoHelp Forum
+ Reply to Thread
Page 1 of 2
1 2 LastLast
Results 1 to 30 of 33
Thread
  1. A common topic in the forums, here and elsewhere, are people complaining that their avi/DivX conversion to mpeg1/2 will have 'drifting audio'... the audio starts out in-sync and over the course of the movie, it gradually drifts out of sync. Several guides have been posted in the past for dealing with this problem by doing post-processing in Sound Forge or Video Vegas and the like, but hopefully this method provides an alternative that guarantees results before encoding.

    If this method is tedious, I point you to the 'NOTE' at the end of this guide. It seems to give 'close to perfect' results with less time taken to process the audio first, but for those that like their sync "exact", I recommend this lengthier process.

    Because these tools are commonly used, and are explained in great depth in other guides available on this site, I haven't included screenshots here.

    Step-by-step guide:

    1. Scan the .avi for bad frames and correct a/v sync in VirtualDub first. If it is wrong to begin with, this method probably won't help.

    2. Extract the audio from the video in VirtualDub. You may be able to go to .WAV directly, but if the audio is AC3 format, you will need to take additional steps to get an uncompressed .WAV file. Use the guides here on vcdhelp or doom9.org. Get an uncompressed .WAV by whatever means necessary. You can downsample to 44.1KHz at this point, or let TMPGEnc do it (via SSRC) in a later step.

    3. Load the .avi in VirutalDub. Select Audio->WAV Audio and load the uncompressed .WAV file you created in step 2. Ensure that Audio->Direct Stream Copy is selected.

    4. Ensure Video->Direct Stream Copy is enabled. Select Video->Frame Rate and select the option "Change so video and audio durations match".

    5. Select File->Save as AVI... You will end up with a very large .avi file (the original video and the uncompressed .WAV file interleaved together with matching durations). NOTE: If you play this .avi, you will probably notice that a/v has gone _out_ of sync! Don't panic.

    6. Load up this .AVI in TMPGEnc. (You can also prepare a AVISynth script if you need to do resizing and/or TemporalSmoothing.. if you do this, load the .avs script in the 'video' box, and load the AVI created in step 5 for the audio).

    7. Set your parameters in TMPGEnc as you prefer. Explaining TMPGEnc options is beyond the scope of this mini-guide.

    8. While setting your TMPGEnc paramters, you MUST turn on the "Do not frame rate conversion [sic]" option in the Advanced tab. Ever wonder what this option was for? Notice how many TMPGEnc guides say "Gee, we have no idea why this is here so ignore it and never use it" . THIS is what it is for! In step 6, you created an avi that might not be perfect 23.976 or 29.976 FPS. TMPGEnc sees this and tries to correct for it - causing audio drift even though you supposedly lined things up in VDub.

    9. Encode away. The result should be a perfectly aligned a/v MPG. Finally!

    Caveat: This process hinges on the fact that we are no longer dealing with perfect frame rates. I've been lucky, and this hasn't seemed to affect playback on my standalone player. This may, however, be out of spec, and some standalone players may not be able to cope.

    Caveat #2: In TMPGEnc, I use SSRC for sample rate conversion, and tooLAME for conversion from .wav to .mp2 (Via "External Tools" in TMPGEnc). This is the preferred way to handle audio in TMPGEnc, and I'm not sure if using TMPGEnc internal downsampling and conversion routines would guarantee the same results.

    NOTE: It is possible to do steps 1 and 2, then jump clear to 6 and achieve very close to the same results. It seemed just as accurate in WinDVD, but on my standalone player there was still an 'ever-so-slight' desync going on. A FAR cry better than before, but not as accurate as the lengthier mentioned above. This may be source or hardware dependent... try both if you have the time to burn

    Good luck, and I hope this clears up sync issues for everyone. It is an amazingly common topic, and hopefully this serves as a solution.
    Quote Quote  
  2. Hey Daagar thanks for the guide, I gave it a shot last night on Kate and Leopold. This movie gets out of sync by the end when I encode it with TMPGEnc. in mpeg2. I followed your instruction to the T, and it did not work the audio is still very out of sync. The only thing I did different from what was stated in your guide was to cut up the movie to fit on CDs. Will try doing the whole movie without cutting it up tonight.
    D
    Quote Quote  
  3. What program did you use to do the cutting? I've heard of this problem before, but don't know of a fix for sync problems after cutting. I suggest using a different tool to split the files if it is giving you grief.
    Quote Quote  
  4. What I used was the merge and cut in TMPGEnc.Plus. it usually works very well for me. So what you are saying is that your guide should have still worked, even if I did cut the file?
    D
    Quote Quote  
  5. no I didnt use merge and cut, I used the source range in TMPEgnc Plus. sorry
    Quote Quote  
  6. well this is weird...I encoded the whole movie without cutting it this time and now theres only the back ground music and any other noise that might be going on in the movie that is all in sync, but no voice's at all.
    What does this mean?
    Quote Quote  
  7. this don't work, haven't tried it becasue i've done this type of thing before and if your frame rate isn't pal/ntsc standered you cant even load it into dvdit or ulead movie factory. if you would like to tell me how to get around this that would be good.
    Quote Quote  
  8. I had the same problem with Kate & Leopold. I tried everything I could think of and could not get it to work. If you view the VOB's they appear to always be in sync. What I ended up doing was encoding each one of the VOB's seperately. I skipped #7 because it was only credits so I had 6 MPEG2 files on the hard drive. I then used Ulead DVD Movie Factory to burn VOB's 1&2 to a disc, 3&4 to a disc and 5&6 to a disc. Other than the last 45 seconds of disc 2 the movie stays in sync. By pressing the pause key and restarting the movie during this 45sec will correct the out of sync problem. The other thing I did notice is when the movie switches between the 2 VOB's on the disc there can be a stutter. Does not affect the audio sync and could also be my player too though I have never seen this happen on another video before. I use smart ripper, DVD2AVI and TMPgenc to make my videos. Did try encoding with Ulead Media Studio Pro instead of TNPgenc and it yielded the sync problems. I would be curious if anyone knows why this one movie acts like this.

    Steve
    Quote Quote  
  9. this don't work, haven't tried it becasue i've done this type of thing before and if your frame rate isn't pal/ntsc standered you cant even load it into dvdit or ulead movie factory. if you would like to tell me how to get around this that would be good.
    Well, it does work, and I _have_ tried it. But this guide assumes you are doing it the way I laid out... using VirtualDub and TMPGEnc. As I mentioned in the Caveats, this process hinges on non-standard framerates. As you noticed, some programs are apparently very picky about that. TMPGEnc is not, and is why this solution works. I'm sorry, but I don't have a solution if you need to use DVDit or ULead.
    Quote Quote  
  10. Hi All
    I've had some weird probs but this is all my fault....I've not got the frame tool or audio tool yet and will try again when I do. However when I extract the audio the playback lenght can sometimes be quite diff to the playback length of the avi, will it still resync? with the right tools loaded into TMPGEnc? & where can I get then ...the lame one is off line atm

    Chuckey
    Quote Quote  
  11. nope ...well I loaded up all the software and followed exact...the avi was out of sync as mentioned and so is the mpeg. as I mentioned b4 the audio is diff in lenth to the vid also so this could be it...I'll try the process with the same duration on both files

    Chuckey
    Quote Quote  
  12. Just tried the new method which resulted in worse audio sync than my old way. Sorry I'm a non-believer.

    Mark
    Quote Quote  
  13. Sorry to add a damper on this, because it seamed to be the solution to all my problems - up to the point where I tried it!

    The symptom of the movie being in sync at the beginning and slowly drifting out of sync remained - I eventually had to cut the movie up into 15 minute peices and correct each peice seperately and then rejoin them into a whole!

    A tedious business, but it worked in the end! (used TMPGenc to cut and join and resync!)
    Quote Quote  
  14. I have just one question. When i load the avi in TMPGenc after running it through Virtualdub,should i load one of the templates for pal or ntsc? or should i set the parameters manually?
    Quote Quote  
  15. Thanks for the guide. I have had gradually worsening audio sync with analog captured AVIs, but all I have had to do is load into Virtualdub and save as a new AVI and it fixes it. I use stream copy and no additional changes are needed.

    Otherwise, it doesn't sync on TMPGE in MEG 1 or 2. DV AVIs don't need this though.
    Quote Quote  
  16. Here is what I do ..and it works every time

    1) Load avi into Vdub and extract audio as a wav file
    2) Load avi into avifrate (find it using google)
    3) Change fps to desired fps
    4) Note the new length of the video in seconds exactly and apply the fps change to the avi
    5) Load wav file into cooledit
    6) Stretch wav to exact length as found in (4) - be sure to tick keep pitch option
    7) Save stretched wav
    8) Encode in TMPGenc using avi (which has had fps changed by avifrate) as video source and stretched wav as audio source

    I also use external audio tools - toolame and ssrc

    Perfect NTSC to PAL results without choppy playback or audio issues :P

    Mail me if you want a text guide that is more detailed

    Olli
    Quote Quote  
  17. Member
    Join Date
    Jul 2002
    Location
    Fairfield
    Search Comp PM
    Ok, so when you save the avi in virtualdub how big a file are we talking about? I have limited space on my 18.6 gig hard drive and want to know how much space I need in order to save an avi which is about 21 minutes long.
    Quote Quote  
  18. Hi All
    I've tried this guide with varying results as u know, however I can can that it does work !
    Providing the extracted audio and video file playback durations are the same. ie Collatral Damage the audio is 7 seconds less than the video and it does actually start 7 secs after the vidio is playing the WB title. So if u follow the guide with this sort of dif of course it will be well out of sync actions will not marry up with audio as it will alwas be 7 secs out coz u'ved streached it to match.
    I hav also found that when playing back on the DVD player standalone if it does drift at all if i press pause and then resume play it's all back in sync again. This could be due to the template I use, the fantastic from Sefy vcd templats, and my player but np for me.
    Therefore what I would really like to know is how to set vDub to start the audio 7 secs or whatever later than the video when creating the final interleaved file (avi) or any thing more precise for the matching????


    The guide needs to mention duration of audio & video other wise the results WILL be poor
    att Bartender: when u extract the audio file for 1:49 mins u could be looking at upto 1.1gb audio file at 44100 2 chan stereo and larger if converted at 48000 stereo.
    Quote Quote  
  19. I virtualdub,under the audio menu,there is a tab called "interleaving" there you just put in the milliseconds you would like the audio to be delayed or -milliseconds if you want the audio to start before the video
    Quote Quote  
  20. Thanks
    I know is 7 secs out but is there any way of finding the millisecs to be more exact?
    Quote Quote  
  21. i believe that 7 seconds is the same as 7000ms.This ofcourse only works if the audio is out of synch for the same duration throughout the movie.If you have an app. sec the audio is out,try delaying that in ms,continue to raise the ms till the audio is in synch
    Quote Quote  
  22. Yes 7000ms is 7 secs but i only know its 7 secs from playback in medi player etc however it may be 7sec & xxms or 6 secs & xxms or 6099ms...a lot of messing around increasing decracing ms. is there any prog i can play back or open the two files in that will show durtion in ms etc?

    Chuckey
    Quote Quote  
  23. That i donīt know,i usually just time the audio drift,using an ordinary stop watch in seconds,and then try to enter it in ms,i always get it to work,it does seem to be a hassle,but it really is no deal once you got it down..You donīt have to be exact,just ballpark figure,then make a sample see if it is ok,if not decrease/increase value..
    Quote Quote  
  24. ok nc1 Thanks :P
    Quote Quote  
  25. As the guide mentions at the start, it assumes you have a file that starts in-sync and then gradually drifts. If your audio starts 7 sec before or after the movie, then you aren't starting in-sync.
    Quote Quote  
  26. Which is what I said anyway. my 7 sec out sync was just used as an example to others who my be trying and getting worse results and as a question (which has nw been resoved thanks to DK) on how to delay the start of audio.

    Chuckey
    Quote Quote  
  27. I'm a MEGA Super Moderator Baldrick's Avatar
    Join Date
    Aug 2000
    Location
    Sweden
    Search Comp PM
    test
    Quote Quote  
  28. Regarding Daagar's guide.
    I fail to see how this could work. Lets say we are starting off with a movie which is say 23.976 fps which has a gradual audio sync. We then choose the option in Virtualdub to change so that the audio and video durations match. This just simply changes the framerate of the video thus changing it's length to match that of the audio. The audio length stays the same.

    When this file is then loaded into TMPG with the modified framerate and you choose 'do not framerate conversion' while choosing the correct 23.976 framerate, all this is then doing is returning the movie back to it's original framerate and thus it's original length, hence putting you back to square one with the original sync problem.

    ASHY
    Quote Quote  
  29. Member
    Join Date
    Jul 2002
    Location
    United States
    Search Comp PM
    Thanks Daagar! I used your method on three divx movies that had vbr audio per virtualdub. Two of the movies I had downloaded as two parts and came out perfect.

    Quote Quote  
  30. Member
    Join Date
    Apr 2002
    Location
    United States
    Search Comp PM
    Many thanks for the guide, tried it on two moives but only had success with one, none the less it is worth sticking with.
    You're just a tube full of gas and a box full of tin, you show me your charms and I want to come in.
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!