Audio out of sync?

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Hefty
    Junior Member
    Junior Member
    • Nov 2003
    • 3

    Audio out of sync?

    Hi everybody.
    This is my first post here so I hope y'all be nice to me.
    How come there is a syncproblem with the playback of XviD movies?
    Yes... I know... It is easily solved by installing ffdshow, but does anybody know why the audio lags?
  • Enchanter
    Old member
    • Feb 2002
    • 5417

    #2
    "but does anybody know why the audio lags?"


    A few possibilities for that, I am afraid:

    1) Your CPU is underpowered for the decoding task at hand and hence decoding of the video and audio goes out of synch. (gradually).

    2) The framerate of the video and audio do not quite match, resulting in audio gradually going off-synch.

    3) Wrong audio off-set. The audio is constantly off-synch from beginning to end of video, by a constant amount of time too.

    4) A combination of two or more of the above factors.


    The first problem is easily solved by upgrading to a faster CPU or even by freeing up system resources (so that the CPU can dedicate itself to decoding the movie and, hopefully, be able to keep the audio synched with the video).

    The second problem can be solved by changing the framerate of the video so that it matches that of the audio. It might be hard to tell what framerate to use, so it is a hit-or-miss affair in this case. A good start would be to use Virtualdub and change the framerate "so video and audio durations match". If that does not do the trick, it is down to manually guessing the framerate, I am afraid.

    The third problem is much more easily solved by listening to the audio and estimating by how much the audio is off-synch from the video. Virtualdub can be used to correct the audio offset.

    Hope that helps a bit. Cheers.

    Comment

    • Hefty
      Junior Member
      Junior Member
      • Nov 2003
      • 3

      #3
      Hmmm.
      I doubt that the hardware is to weak since I run a Athlon 2800+ with 1024MB RAM...
      The problem is solved when using ffdshow so there must be something lacking in the decodingsoftware in XviD? This is a reocurring problem that I have seen firsthand on many different systems.
      Ok, XviD is a video codec so one could argue that the problem is elsewhere but to function with a movie the audio has to sync to the video.
      The only alternative that I can see as possible out of the four given is the #2 option. Different framerates...
      Many movies are codec using 23,976fps with an mp3 soundtrack @ 48kHz samplerate. Looking at these figures I emediately see that 2*23,976=47,952 and 47,952 is not 48. Thus there might be a discreppancy there?
      If that is the case? Does ffdshow compensate for the differences? Why isn't the XviD decoder compensating?
      Back to square #1 how do I configure the XviD decoder, not using ffdshow?

      Comment

      • Enchanter
        Old member
        • Feb 2002
        • 5417

        #4
        "2*23,976=47,952 and 47,952 is not 48"

        Sampling rate of the audio is not the same as the framerate; at least not in this sense of application.

        In your case, I would say it's whatever decoder that XviD codec is using (whose build are you using?). Since FFDShow is working for you, why don't you just continue using it?

        Cheers.

        Comment

        Working...