View Full Version : Out of sync audio from AC3
spyder
24th July 2002, 00:37
I have demuxed the AC3 track from Kate and Leopold with DVD2AVI and decoded it with Headac3he(different versions so not a specific bug in that) with DPL 1&2 downmixing to both 48kHz and 44.1kHz files. The audio is badly out of sync when I try to use it in Nandub to mux into an AVI. I played with the offset for one scene and got it in sync but then i seek to the end of the file and it's all screwed again. This happens with both MP3 and PCM files. I have done this many times before with VBR MP3 and no problem. The audio seems to be skewed somehow. Anyone else ever encountered this problem? I have seen it once before and the only solution I found was to mux in the original AC3. But in this case I don't really want to mux a 300MB AC3 with the 1200MB video. Any help would be greatly appreciated.
Spyder
ookzDVD
24th July 2002, 09:16
@spyder,
Why not to downsample the AC3 bitrate so you can have ~200MB AC3
and mux it with 1200MB video to get the ~1400MB AVI-AC3 ?
I think BeSweet with AC3Machine GUI can do it for you ;)
DJ Bobo
24th July 2002, 11:22
look here: http://forum.doom9.org/showthread.php?s=&threadid=29698
Vormulac
24th July 2002, 11:36
I got the same problem with Zardoz and Kiss of the Dragon and even using the ac3 doesn't fix it ! i use the same progs as DJ Bobo wrote.
And another strange thing ,once in a while when i transfer movies through my network the audio gets out of sync !
milctoast
24th July 2002, 12:56
Are you people ripping the movie in 23.99fps and the audio in 29.99fps or vice versa?
DJ Bobo
24th July 2002, 16:15
I'm always wondering why you people are getting asynch movies all the time!
I mean I ripped so many.. so many DVDs, I rip DVDs like hell, and not a single one got asynch!
spyder
24th July 2002, 18:16
I rip at 23.976fps using either IVTC or Force Film depending on the source. In this case I used IVTC and when that one was asynch, I tried Force Film and it was asynch as well. I am not transferring them through a network or anything like that. I will try AC3 machine and see but I really have a feeling it won't help since it seems to be a problem with the decoded audio. I will also check again to see if the original AC3 muxed in will work. I talked with everwicked and he suggested that it was Nandub screwing the muxing so I tried a PCM WAV and got the same results. The audio gets further off as the file goes on so a simple offset won't work. I am also trying it without DS2 now to see if it is actually a bug in Headac3he's downmixing routines. I have stayed away from DS2 since it screwed a VCD of mine but it always had worked for 48kHz MP3.
BTW: DJ Bobo, I use almost the exact same method as you for ripping, except I use Headac3he for the audio.
spyder
24th July 2002, 18:45
I think I may have found the problem but I am not sure how to fix it. The AC3 is missing the last frame according to Headac3he. That's why the audio duration is slightly shorter(~1 sec) than the video duration. Anyone know how I can fix this? Is the best way to take the decoded WAV and add silence to the end to match or what?
DJ Bobo
24th July 2002, 19:32
so take the AC3, that DVD2AVI demuxed for you, chase it through AZID that way:
azid -c normal -a filename.ac3 filename.wav
Or this way if you wanna better quality:
azid -c normal -a -F wav24 filename.ac3 filename.wav
Then use RazorLame to encode it to MP3.
Then mux it in NanDub, with the AVI that was done in VD. I don't see any reason why it shouldn't be synch. I always make it this way, and I never got any asynch movies or episodes.
spyder
24th July 2002, 19:46
I am trying BeSweet now (first time). I don't think there will be any difference in using Headac3he or BeSweet rather than Azid since they both use the Azid DLL for decoding. Maybe a bug in the internal routines but not in the decoding. Surely if it's a bug in Headac3he then it will work fine in BeSweet.
Trahald
24th July 2002, 20:02
ive only had async problems 2 times.. problem was wb titles encode to 23.975 (checked with vdub) which resulted in a gradual loss of sync .. so i just adjusted the frame rate to 23.976 (with vdub.. direct stream copy - change frame rate) only took a minute
DSPguru
24th July 2002, 21:26
don't forget that BeSweet can also append silence at end of track, if ever needed..
pacohaas
24th July 2002, 22:11
DJ Bobo: maybe your sync luck is because you are in a region where all dvd's are 25fps?
DJ Bobo
24th July 2002, 22:27
@ pacohaas
1) nice try! :p
2) Most DVDs I have are in NTSC format
3) synch has nothing to do with a DVD being PAL or NTSC, if it's synch on the DVD, then it will be synch after ripping
4) In such matters there is no luck! it's all a matter of methodic work, and my method doesn't allow "luck" to play a role, because I control every ripping step!
spyder
27th July 2002, 18:20
I also control every ripping step but in this case control is not possible. It seems that the AC3 is badly encoded as it gives a warning in Headac3he that the last frame is missing or the stream is corrupt. I tried AC3Fix but it only told me there were no errors in the stream and had rewritten the file(strangely the file sizes differed by ~300 bytes). I tried Besweet, no warning, but the produced audio was still time compressed. I have not tried expanding the audio to match the video duration yet but I will as soon as I have enough HD space for SoundForge to do it.
@DJ Bobo: I don't know why you are so determined that your method is flawless but since you think it is, please inform the rest of us as I have been speaking with a few mods from this board and everwicked himself and no one can figure out what is going on and they all agree that there is no flawless method.
Trahald
28th July 2002, 06:03
well.. 2 things.. hopefully one of them helps ;)
i dont think the error at the end of the stream is all that uncommon
headache has complained to me before.. but it came out ok
second thing... i had an ac3 that was sorta on the loud side for an ac3.. anyways.. when i tried to ac3->mp3 it, i would throw some gain in.. what i realized is when it got to where it should clip it would discard the data instead of using the highest number(clip).. so basically it caused the file to slowly desync at the 'clipped' spots.. happened with headache and besweet (they use the same or similar dlls so not surprising) so i lowered the gain and worked fine.
it occured ac3->mp3 and ac3->pcm
raphos
19th July 2004, 19:19
hmmm ... got exactly the same problem ! ac3 seems corrupted and ac3fix and besplit dont resolve the issue ...
how did you "lower the gain" ?
thank you very much
vBulletin® v3.8.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.