View Full Version : x264 23.976 -> 25 without sound desync, how ?
lutinor
14th April 2011, 08:23
I have an issue, i have an mkv progressive in 23.976 and i need to encode it in 25fps. everything is fine during the codage session but when i mux audio/video i get a sound desync. :confused:
Here's my line :
x264 --bitrate 1100 --fake-interlaced --bluray-compat --vf resize:width=720,height=576,method=spline --preset superfast --tune animation --fps 25/1 --force-cfr --weightp 1 --bframes 3 --nal-hrd vbr --vbv-maxrate 40000 --vbv-bufsize 30000 --level 4.1 --keyint 25 --b-pyramid strict --slices 4 --ref 6 --aud --colorprim "bt470bg" --transfer "bt470bg" --colormatrix "bt470bg" --sar 16:11 -o out.264 ep1.mkv
J_Darnley
14th April 2011, 09:21
Did you get a PAL audio source from somewhere? If not, it isn't very surprising that the video races ahead of the audio.
lutinor
14th April 2011, 13:34
I'm having a strange thing :
I have an mkv h264 movie fps 23.976 progressive and perfectly syncro sound/video. His resolution is 720x544.
I must make a 720x576 at 25fps.
If i convert with this line :
x264 --bitrate 1100 --fake-interlaced --bluray-compat --vf resize:width=720,height=576,method=spline --preset superfast --tune animation --fps 25/1 --force-cfr --weightp 1 --bframes 3 --nal-hrd vbr --vbv-maxrate 40000 --vbv-bufsize 30000 --level 4.1 --keyint 25 --b-pyramid strict --slices 4 --ref 6 --aud --colorprim "bt470bg" --transfer "bt470bg" --colormatrix "bt470bg" --sar 16:11 -o out.264 ep1.mkv
I get my h264 file but when i mux it with the original sound u have a sound desyncro.
I found a way to make the resolution/fps mod with Pegasys encoder. With this tool i have a good 25 fps movie ready to be converted in x264 but it force me to make a lossless video in Tmpg and it's long :( Is there a way to outpast this in x264 command line ? :confused::confused::confused:
sneaker_ger
14th April 2011, 13:43
I already told you that it's not strange and not a bug at all in the other thread.
Also what you have done here (unknowingly) is actually the most accepted way to do 23.976 > 25.
You also have to convert the audio now, for example with eac3to (http://forum.doom9.org/showthread.php?t=125966):
eac3to input.ac3 output.ac3 -23.976 -speedup
lutinor
14th April 2011, 13:55
I already told you that it's not strange and not a bug at all in the other thread.
Also what you have done here (unknowingly) is actually the most accepted way to do 23.976 > 25.
You also have to convert the audio now, for example with eac3to (http://forum.doom9.org/showthread.php?t=125966):
eac3to input.ac3 output.ac3 -23.976 -speedup
Thx for your tip but there is a thing that i can't understand:
I use Tmpg to change the movie, and i get a 25fps. I extract the 2 audio from the mkv without speed up. I mux the video from tmpg + the 2 extracted audio and all is syncro, how is it possible?
sneaker_ger
14th April 2011, 14:00
I use Tmpg to change the movie, and i get a 25fps. I extract the 2 audio from the mkv without speed up. I mux the video from tmpg + the 2 extracted audio and all is syncro, how is it possible?
Tmpg will most likely duplicate frames to change the framerate, the total number of frames increases. x264 on the other hand will only change the duration of each frame from 41,7 ms to 40 ms, the total number of frames doesn't change. The method used by x264 is known as "pal speedup" and is the most common way to convert between the two formats.
lutinor
14th April 2011, 14:15
Tmpg will most likely duplicate frames to change the framerate, the total number of frames increases. x264 on the other hand will only change the duration of each frame from 41,7 ms to 40 ms, the total number of frames doesn't change. The method used by x264 is known as "pal speedup" and is the most common way to convert between the two formats.
Ok but in pal speed up, if i use your ac3 tool i can 'outpass' the tmpg part ?
sneaker_ger
14th April 2011, 14:23
Ok but in pal speed up, if i use your ac3 tool i can 'outpass' the tmpg part ?
"outpass"? You mean you first used tmpg and then x264 in a chain?
Then yes, you can skip the tmpg part completely.
lutinor
14th April 2011, 15:05
"outpass"? You mean you first used tmpg and then x264 in a chain?
Then yes, you can skip the tmpg part completely.
x264 + ac3 speed boost = ok ? i will test it tonight, i hope i won't get other strange issue lol
vBulletin® v3.8.11, Copyright ©2000-2026, vBulletin Solutions Inc.