View Full Version : Audio is all out of sync.
Jeremy Duncan
22nd April 2009, 20:12
Here is my sample taken from the vob from the movie ultraviolet, ntsc, sd dvd.
http://www.mediafire.com/?rj0fyamrdjc
I use the steps in this guide I will ink too:
http://forum.doom9.org/showthread.php?p=873699#post873699
When I play the mpg with the frame doubler the audio is out of sync and I read online that this may be due to the video and audio using different frame rates.
And this means that dgindex may have something to do with this.
I do not know if forcing film to 23.976 also changes the audio to 23.976.
imago muxer calls the m2v hc rnc makes 24 fps. I looked for a muxer that muxes 23.976 video and audio and found nothing. I tried ts muxer and besweet.
I have no idea how to get besweet to go.
I remember the guide I linked to working in xp pro. It's been a while since I used xp pro. There was no audio funniness then.
I'm using vista 32 bit right now.
I don't know what else to do so I post here in doom9 and I don't even know if this is the right forum to post this in. :)
TheRyuu
22nd April 2009, 20:42
It's in sync for me.
http://www.mediafire.com/?ndjiiyz3ykn
Setting your audio delay right?
I do not know if forcing film to 23.976 also changes the audio to 23.976.
...What?
They're independent of each other, framerate shouldn't matter.
LoadPlugin("E:\plugins\MPEG2Dec3.dll")
LoadPlugin("E:\plugins\TIVTC.dll")
MPEG2Dec3_MPEG2Source("C:\Anime\Stuff\Ultraviolet\ultraviolet.d2v")
SetPlanarLegacyAlignment(true)
tfm(slow=2).tdecimate(cycle=5)
Crop(4, 8, -4, -14)
Spline36Resize(704,480)
Encoded to h264, crf18 then just muxed in the original audio setting the delay in mmg. I had no problems. Also forcing film = tfm().tdecimate() here, so either works for this since it's 100% film.
Jeremy Duncan
22nd April 2009, 21:16
It doesn't help me though if it works for you since I'm using different sw and am doubling the framerate in ffdshow.
Neuron2 said using force film is the better way to get 23.976 fps compared to decomb in ffdshow.
So i don't use tdecimate I use force film.
Can you suggest a script I can use if I use dginde force film?
I want to use hc enc to encode 23.976 with no pulldown and have the audio in sync when I mux it with the m2v with imago.
I don't know how to set audio delay so the audio is in sync.
Socio
22nd April 2009, 21:38
It doesn't help me though if it works for you since I'm using different sw and am doubling the framerate in ffdshow.
Neuron2 said using force film is the better way to get 23.976 fps compared to decomb in ffdshow.
So i don't use tdecimate I use force film.
Can you suggest a script I can use if I use dginde force film?
I want to use hc enc to encode 23.976 with no pulldown and have the audio in sync when I mux it with the m2v with imago.
I don't know how to set audio delay so the audio is in sync.
Just enable "force film" in DGIndex when you create your d2v then to process/filter it use this to load it.
LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\DGDecode.dll")
LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\Decomb.dll")
MPEG2Source("C:\"d2v folder location" \VTS_01_1.d2v")
If you try and process\filter the demuxed m2v you will get petty bad audio sync.
Jeremy Duncan
23rd April 2009, 01:53
I made a d2v from the sample. I made the sample a .vob first by adding .vob to the filename so dgindex could open it.
I used force fim in dgindex.
Then I made this script and encoded with hc enc as shown the the guide I linked too.
LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\DGDecode.dll")
LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\decomb.dll")
mpeg2Source("C:\Users\plastic\Desktop\1.d2v")
LanczosResize(848,480)
converttoyv12()
I tried this code as well
LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\DGDecode.dll")
LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\decomb.dll")
mpeg2Source("C:\Users\plastic\Desktop\1.d2v")
AssumeTFF()
Telecide()
Decimate(cycle=5)
LanczosResize(848,480)
converttoyv12()
The second code made 19fps and so I didn't use it.
The first code after making the m2v I muxed the audio with imago. I tried encoding the m2v with pulldown and without it.
And the audio was all out of sync. :)
TheRyuu
23rd April 2009, 01:57
Neuron2 said using force film is the better way to get 23.976 fps compared to decomb in ffdshow.
So i don't use tdecimate I use force film.
Lets re-read what I said.
Also forcing film = tfm().tdecimate() here, so either works for this since it's 100% film.
But that's pretty irrelevant and doesn't really concern your question. Second, out of curiosity, where am I using decomb/ffdshow?
1.) Decomb ******* by itself. Use tritical's TIVTC.
2.) ffdshow?
Socio's script would be equivalent to mine if using force film. Forgetting everything above, you end up with 23.976fps progressive material. Just throw this through the encoder of your choice, and you can set your -353ms delay (that's what I got processing your sample) at muxing time. Alternatively if you are going to re-encode your audio you can set it in an avisynth script using:
DelayAudio(-0.353)
Edit:
The second code made 19fps and so I didn't use it.
That's because you saved the d2v using force film. Resave it using ignore pulldown flags.
Edit2:
If setting the delay correctly doesn't work (can someone even see a -353ms delay?) I honestly have no idea what you're doing wrong.
Jeremy Duncan
23rd April 2009, 02:09
I tried setting the audio delay like this in my avs file:
LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\DGDecode.dll")
LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\nicaudio.dll")
video=mpeg2Source("C:\Users\plastic\Desktop\1.d2v")
audio=NicAC3Source("C:\Users\plastic\Desktop\1 T80 3_2ch 448Kbps DELAY -287ms.ac3")
AudioDub(video,audio)
DelayAudio(-0.287)
LanczosResize(848,480)
converttoyv12()
Then making the m2v, the muxing the audio using imago.
The audio was still out of sync.
I'm wondering what ac3 to m2v muxer you recommend so I can set the delay in there? :)
TheRyuu
23rd April 2009, 02:23
I'm wondering what ac3 to m2v muxer you recommend so I can set the delay in there? :)
I don't encode to mpeg2 (I don't see the point of encoding to mpeg2 really but whatever).
Jeremy Duncan
23rd April 2009, 02:33
I made a new d2v with ignore pulldown and used tivtc code you showed.
Then I made the m2v with hc enc as shown in the guide I linked too and muxed the audio with tsmuxer setting the delay in audio.
The audio was still out of sync.
Here is the avs file I used to make the m2v:
LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\DGDecode.dll")
LoadPlugin("C:\Program Files\AviSynth 2.5\plugins\tivtc.dll")
mpeg2Source("C:\Users\plastic\Desktop\1.d2v")
SetPlanarLegacyAlignment(true)
tfm(slow=2).tdecimate(cycle=5)
LanczosResize(848,480)
converttoyv12()
http://img378.imageshack.us/img378/4306/mux.jpg (http://img378.imageshack.us/my.php?image=mux.jpg)
TheRyuu
23rd April 2009, 05:29
Maybe your source is just out a sync. Play with the delay till it's in sync? Dunno.
Also you don't need SetPlanerLegacyAlignment(true) if you're using dgdecode. That's just for mpeg2dec3 (don't use it).
Edit: Delay is -287 fyi.
manono
23rd April 2009, 06:56
Edit: Delay is -287 fyi.
You reckon that makes a difference? :)
I don't get it. If the delay is a fixed amount (the same all the way through), it's the easiest thing in the world to first, figure it out and second, to fix it. No need for a big thread.
imago muxer calls the m2v hc rnc makes 24 fps.
If it were really setting the framerate to 24fps (which it isn't), the audio would get progressively more out of synch, which doesn't seem to be the case here.
I looked for a muxer that muxes 23.976 video and audio and found nothing.
Imago. It just says 24.0fps. It's really 23.976fps if that's the framerate you set in the encoder. Your "problem" has nothing to do with Imago.
TheRyuu
23rd April 2009, 21:08
You reckon that makes a difference? :)
I was just saying, he set it to 287 and not -287.
neuron2
23rd April 2009, 23:11
manono knows. He was being sarcastic/funny.
Jeremy Duncan
23rd April 2009, 23:48
I was just saying, he set it to 287 and not -287.
That did it. Now the audio is in sync. :)
vBulletin® v3.8.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.