VideoHelp Forum
+ Reply to Thread
Results 1 to 9 of 9
Thread
  1. Member
    Join Date
    Sep 2008
    Location
    United States
    Search Comp PM
    I'm converting a DVD episode to an AVI. The audio in the resulting AVI is out of sync (starting over a second late), yet the audio file name generated by DgIndex indicates a delay of 0ms. I know how to approximate and fix the delay by ear using Avidemux, but how do I calculate the exact delay?

    Here's a list of the software I'm currently using:
    DVDFab HD Decrypter
    DgIndex
    VirtualDub
    AviSynth
    Avidemux
    Quote Quote  
  2. Originally Posted by lomaidala View Post
    but how do I calculate the exact delay?
    I think better would be to prepare the DVD properly for encoding.

    Try one of these suggestions:

    Open the IFO in PGCDemux, tick 'Single Cell' and check the drop down box for some tiny cells before getting to the 'real' cell for the beginning of the video. What I'm thinking is that there are some tiny cells consisting of black blank video and no audio (and hence no delay) which play before the 'real' video begins. It plays in synch as a DVD but not after being converted to AVI. If you do find some tiny cells that might total to a second or so, then you might try running the decrypted video through FixVTS, or maybe reauthoring what you want in DVDShrink, taking care to remove the black frames.

    Or maybe checking in PGCDemux 'By VOB ID' to see if it also has those little cells and, if so, demux what you want by VOB ID before running the M2V or VOB file through DGIndex.

    Or move into the video a bit in DGIndex using the '[' button so that the tiny cells aren't included in the D2V you make and you get a real delay in the audio.
    Quote Quote  
  3. Member
    Join Date
    Sep 2008
    Location
    United States
    Search Comp PM
    Thanks! The IFO does indeed show tiny cells in PGCDemux, even for just this one episode:
    00:00:00.15
    00:00:00.15
    00:00:00.15
    00:01:30.05
    00:11:41.02
    00:08:47.20
    00:01:34.16

    I tried using FixVTS, but the resulting AVI still has audio that is out of sync.

    When I move into the video in DGIndex using the '[' button, I get varying audio delays depending on how far into the video I move. For example:
    -84ms near the beginning.
    -147ms near the middle.
    -110ms near the end.
    Why are they different? Also, all of these numbers are too low. The delay should be further into the negatives than -1000ms.

    In PGCDemux, I used 'by VOB ID' to demux the one VOB ID that isn't tiny before running the M2V or VOB file through DGIndex. It looks like that did the trick!

    Compared to going straight from DVDFab HD Decrypter to DgIndex, does this intermediary step with PGCDemux do any processing or re-compression? I noticed it results in smaller file sizes for the M2V, AC3, and D2V. I just want to make sure I'm not losing any video or audio quality by doing this extra step.

    And is there a difference between choosing to 'Create a PGC VOB' and choosing to create an M2V? If so, should I be turning on 'One file per VID'? And should I be using any settings under 'Customize file'?
    Quote Quote  
  4. Those tiny audioless cells are what are called 'unreferenced cells'. The DVD has instructions to skip over them and begin at the 'real' cell, but when you include them in your reencode the whole thing is thrown out of synch. I'm a bit surprised the audio was still out of synch after they were removed, especially so since you said doing it by VOB ID worked. Did you check for a delay in PGCDemux after running the DVD through FixVTS? Or the audio file name from DGIndex didn't have a delay in the title?

    Why are they different?
    I neither know nor care why they're out of synch and by how much. But whenever you cut a VOB there's a delay to be taken into account. The DVD takes it into account and that's why DGIndex puts the amount of the delay in the title of the demuxed audio.

    Also, all of these numbers are too low. The delay should be further into the negatives than -1000ms.
    How do you know that? Did you remux with Muxman or ImagoMPEG-Muxer, taking the delay into account or removing it entirely with DelayCut? Or you did take the delay into account when making an AVI and the result was still audio badly out of synch?
    ...does this intermediary step with PGCDemux do any processing or re-compression?
    No, it only demuxes. No compressing or transcoding or changing of the audio/video/chapters/subs in any way.
    And is there a difference between choosing to 'Create a PGC VOB' and choosing to create an M2V?
    I sometimes create the VOB from which to work. If the next step is to use DGIndex on it, then if getting the M2V and audio separately, you'd best find out if there's a delay. PGCDemux has a box for that, 'Check A/V Delay'. It doesn't put the amount of the delay in the audio name the way DGIndex does and you can't just assume there is no delay because there sometimes is. Otherwise make a VOB and get the amount of the delay from the DGIndex audio file.
    Last edited by manono; 28th Jul 2015 at 20:48.
    Quote Quote  
  5. Member
    Join Date
    Sep 2008
    Location
    United States
    Search Comp PM
    Originally Posted by manono View Post
    I'm a bit surprised the audio was still out of synch after they were removed, especially so since you said doing it by VOB ID worked. Did you check for a delay in PGCDemux after running the DVD through FixVTS? Or the audio file name from DGIndex didn't have a delay in the title?
    I used DGIndex after FixVTS, and no audio delay was indicated in the file name. But just now I used DGIndex to 'Check A/V delay' and it came up with this:
    Audio_1: None.
    Audio_2: None.
    Audio_3: None.
    Audio_4: 0x83 --> 0 msecs.
    Audio_5: None.
    Audio_6: None.
    Audio_7: None.
    Audio_8: None.

    Originally Posted by manono View Post
    Also, all of these numbers are too low. The delay should be further into the negatives than -1000ms.
    How do you know that? Did you remux with Muxman or ImagoMPEG-Muxer, taking the delay into account or removing it entirely with DelayCut? Or you did take the delay into account when making an AVI and the result was still audio badly out of synch?
    I didn't do anything with Muxman, ImagoMPEG-Muxer, or DelayCut. Should I be? What I did was use Avidemux to manually input a delay by ear. I had to go beyond -1000ms before the audio began to match up with the video. Things looked and sounded about right at -1420ms.

    Originally Posted by manono View Post
    I sometimes create the VOB from which to work. If the next step is to use DGIndex on it, then if getting the M2V and audio separately, you'd best find out if there's a delay. PGCDemux has a box for that, 'Check A/V Delay'. It doesn't put the amount of the delay in the audio name the way DGIndex does and you can't just assume there is no delay because there sometimes is. Otherwise make a VOB and get the amount of the delay from the DGIndex audio file.
    So for the PGCDemux stage, I should be checking 'Create a PGC VOB', right? Do any of its sub-settings matter? I assume the default settings are best.

    After using DGIndex, I end up with an m2v titled 'VideoFile.demuxed.m2v', but my d2v points to 'VideoFile.m2v', which existed before using DGIndex. In this case, is there a point to VideoFile.demuxed.m2v? Or should I be selecting 'Save Project' rather than 'Save Project and Demux Video'?
    Quote Quote  
  6. You only need one video, whether in the VOB or the demuxed M2V. So I don't think there's a need for Save Project and Demux Video. Save Project should be enough.

    I've never used AviDemux in my life so I can't comment on what may or may not be happening there.
    Quote Quote  
  7. Member
    Join Date
    Sep 2008
    Location
    United States
    Search Comp PM
    Okay, thanks!
    Quote Quote  
  8. I had similar problem where video was not in sync with audio (when imported in avidemux), I just discovered that you can detect the exact delay by using XviD4PSP

    Just drop your video file onto it, and go to "filters" tab, you will see "Delay:" 895 ms

    Add this number in avidemux shift and your audio will be fixed.

    Quote Quote  
  9. Member Budman1's Avatar
    Join Date
    Jul 2012
    Location
    NORTHWEST ILLINOIS, USA
    Search Comp PM
    Many times you can use FFMpeg to create a video representation of the audio and then play the original video and the sound, stacked and frame advanced, displaying the frame time and listening to the sound:

    Click image for larger version

Name:	Timing.jpg
Views:	298
Size:	126.8 KB
ID:	36381
    Quote Quote  



Similar Threads

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