Audio out of Syn with one video and not the other.

For help and support with PS3 Media Server in general
Forum rules
Please make sure you follow the Problem Reporting Guidelines before posting if you want a reply.

Audio out of Syn with one video and not the other.

Postby kanti123 » Sun Jan 20, 2013 4:40 am

I watch a lot of anime, I download one of the weekly release today and seem like this one doens't sync right. Below is the MKV info. The only different between the 2 is one is 29.970 fps (which i'm having problem with) and one is 23.976 fps. could this be the cause of the video/ audio out of sync?

Code: Select all
General
Unique ID :    186086179000194257957557222713257784524 (0x8BFEE4F9D7E90A93949DE632FDF674CC)
Complete name :    D:\Anime\[HorribleSubs] Maoyuu Maou Yuusha - 03 [1080p].mkv
Format :    Matroska
Format version :    Version 2
File size :    539 MiB
Duration :    23mn 40s
Overall bit rate :    3 183 Kbps
Encoded date :    UTC 2013-01-18 18:08:05
Writing application :    mkvmerge v5.2.0 ('I can't explain') built on Dec 18 2011 18:12:03
Writing library :    libebml v1.2.3 + libmatroska v1.3.0
Attachment :    Yes

Video
ID :    1
Format :    AVC
Format/Info :    Advanced Video Codec
Format profile :    High@L4.0
Format settings, CABAC :    Yes
Format settings, ReFrames :    4 frames
Codec ID :    V_MPEG4/ISO/AVC
Duration :    23mn 40s
Nominal bit rate :    3 072 Kbps
Width :    1 920 pixels
Height :    1 080 pixels
Display aspect ratio :    16:9
Frame rate mode :    Constant
Frame rate :    29.970 fps
Color space :    YUV
Chroma subsampling :    4:2:0
Bit depth :    8 bits
Scan type :    Progressive
Bits/(Pixel*Frame) :    0.049
Writing library :    x264 core 120 r2120 0c7dab9
Encoding settings :    cabac=1 / ref=4 / deblock=1:1:1 / analyse=0x3:0x113 / me=umh / subme=8 / psy=1 / psy_rd=0.40:0.00 / mixed_ref=1 / me_range=16 / chroma_me=1 / trellis=1 / 8x8dct=1 / cqm=0 / deadzone=21,11 / fast_pskip=1 / chroma_qp_offset=-2 / threads=8 / sliced_threads=0 / nr=0 / decimate=1 / interlaced=0 / bluray_compat=0 / constrained_intra=0 / bframes=3 / b_pyramid=2 / b_adapt=2 / b_bias=0 / direct=3 / weightb=1 / open_gop=0 / weightp=2 / keyint=250 / keyint_min=25 / scenecut=40 / intra_refresh=0 / rc_lookahead=50 / rc=2pass / mbtree=1 / bitrate=3072 / ratetol=1.0 / qcomp=0.60 / qpmin=0 / qpmax=69 / qpstep=4 / cplxblur=20.0 / qblur=0.5 / vbv_maxrate=6144 / vbv_bufsize=15360 / nal_hrd=none / ip_ratio=1.40 / aq=1:0.60
Default :    Yes
Forced :    Yes

Audio
ID :    2
Format :    AAC
Format/Info :    Advanced Audio Codec
Format profile :    LC
Codec ID :    A_AAC
Duration :    23mn 40s
Channel(s) :    2 channels
Channel positions :    Front: L R
Sampling rate :    44.1 KHz
Compression mode :    Lossy
Default :    Yes
Forced :    Yes

Text
ID :    3
Format :    ASS
Codec ID :    S_TEXT/ASS
Codec ID/Info :    Advanced Sub Station Alpha
Compression mode :    Lossless
Default :    Yes
Forced :    Yes


Code: Select all
General
Unique ID :    253633655046345960404746566566915330655 (0xBED010AB6E13C539A3748FF0B8FBD25F)
Complete name :    D:\Anime\[HorribleSubs] Zetsuen no Tempest - 01 [1080p].mkv
Format :    Matroska
Format version :    Version 2
File size :    560 MiB
Duration :    24mn 26s
Overall bit rate :    3 200 Kbps
Encoded date :    UTC 2012-10-04 19:08:04
Writing application :    mkvmerge v5.2.0 ('I can't explain') built on Dec 18 2011 18:12:03
Writing library :    libebml v1.2.3 + libmatroska v1.3.0
Attachment :    Yes

Video
ID :    1
Format :    AVC
Format/Info :    Advanced Video Codec
Format profile :    High@L4.0
Format settings, CABAC :    Yes
Format settings, ReFrames :    4 frames
Codec ID :    V_MPEG4/ISO/AVC
Duration :    24mn 26s
Nominal bit rate :    3 072 Kbps
Width :    1 920 pixels
Height :    1 080 pixels
Display aspect ratio :    16:9
Frame rate mode :    Constant
Frame rate :    23.976 fps
Color space :    YUV
Chroma subsampling :    4:2:0
Bit depth :    8 bits
Scan type :    Progressive
Bits/(Pixel*Frame) :    0.062
Writing library :    x264 core 120 r2120 0c7dab9
Encoding settings :    cabac=1 / ref=4 / deblock=1:1:1 / analyse=0x3:0x113 / me=umh / subme=8 / psy=1 / psy_rd=0.40:0.00 / mixed_ref=1 / me_range=16 / chroma_me=1 / trellis=1 / 8x8dct=1 / cqm=0 / deadzone=21,11 / fast_pskip=1 / chroma_qp_offset=-2 / threads=8 / sliced_threads=0 / nr=0 / decimate=1 / interlaced=0 / bluray_compat=0 / constrained_intra=0 / bframes=3 / b_pyramid=2 / b_adapt=2 / b_bias=0 / direct=3 / weightb=1 / open_gop=0 / weightp=2 / keyint=250 / keyint_min=23 / scenecut=40 / intra_refresh=0 / rc_lookahead=50 / rc=2pass / mbtree=1 / bitrate=3072 / ratetol=1.0 / qcomp=0.60 / qpmin=0 / qpmax=69 / qpstep=4 / cplxblur=20.0 / qblur=0.5 / vbv_maxrate=6144 / vbv_bufsize=15360 / nal_hrd=none / ip_ratio=1.40 / aq=1:0.60
Default :    Yes
Forced :    Yes

Audio
ID :    2
Format :    AAC
Format/Info :    Advanced Audio Codec
Format profile :    LC
Codec ID :    A_AAC
Duration :    24mn 26s
Channel(s) :    2 channels
Channel positions :    Front: L R
Sampling rate :    44.1 KHz
Compression mode :    Lossy
Default :    Yes
Forced :    Yes

Text
ID :    3
Format :    ASS
Codec ID :    S_TEXT/ASS
Codec ID/Info :    Advanced Sub Station Alpha
Compression mode :    Lossless
Default :    Yes
Forced :    Yes
My Setup
Computer
Asus G73Jw
16Gig of ram
2x 512Gig of HDD
1 Gigabit LAN line
Geforce GTX460M

Output Setup
PS3 Slim
1000 base full band
HDMI to Denon AVR-4311CI to Samung un55ES7100 (Calibrated with X-Rite i1Pro Enhanced from Spectracal)
kanti123
 
Posts: 41
Joined: Fri Nov 25, 2011 6:02 pm

Re: Audio out of Syn with one video and not the other.

Postby watthis » Sun Jan 20, 2013 9:29 am

I've been searching the forums for a while now and have this exact same problems with files that has 29fps. Turns out they had this problem before with 25fps at viewtopic.php?f=11&t=3336&start=60.
The "Fix 23.976/25fps A/V Mismatch" option they mentioned in the video setting folder actually worked for me, but only for a few minutes then there's a bunch of skipping frames in the debug file which eventually crashed. Guess somebody just needs to modify that 25fps desync problem in order to also work for videos that are 29fps.
watthis
 
Posts: 1
Joined: Sun Jan 20, 2013 9:24 am

Re: Audio out of Syn with one video and not the other.

Postby ExSport » Sun Jan 20, 2013 10:36 am

This feature is not for you. It is for people from Europe where PAL is used instead of NTSC.
It fixes videos where you will use audio from PAL DVD (25fps) together with video in NTSC (23.976).
There are many titles which are released on DVD and Blu-Ray in europe countries but native language is only released on DVD or in TV. Mixing 25fps native audio with HD video (23.976) are played improperly so this feature is a fix for it.
Problem can be PMS wrongly detects fps or bug in MEncoder or bad settings. Post debug.log.
ExSport
 
Posts: 2167
Joined: Mon Jan 19, 2009 5:40 pm

Re: Audio out of Syn with one video and not the other.

Postby kanti123 » Sun Jan 20, 2013 1:48 pm

Here's my debug log, another thing I discovered is. If you play the video with FFmpeg or Tmuxer, you don't get the sync problem. Just when you play with Mencoder, but I need sub title so..

http://pastebin.com/d053DiNv
My Setup
Computer
Asus G73Jw
16Gig of ram
2x 512Gig of HDD
1 Gigabit LAN line
Geforce GTX460M

Output Setup
PS3 Slim
1000 base full band
HDMI to Denon AVR-4311CI to Samung un55ES7100 (Calibrated with X-Rite i1Pro Enhanced from Spectracal)
kanti123
 
Posts: 41
Joined: Fri Nov 25, 2011 6:02 pm

Re: Audio out of Syn with one video and not the other.

Postby ExSport » Sun Jan 20, 2013 3:20 pm

In log there is tsMuxeR engine used only. No info about pure [MEncoder] engine used.
You need to restart PMS, play file with MEncoder engine and close PMS again. Then post debug.log
Every PMS restart debug log is cleared.
ExSport
 
Posts: 2167
Joined: Mon Jan 19, 2009 5:40 pm

Re: Audio out of Syn with one video and not the other.

Postby kanti123 » Sun Jan 20, 2013 4:04 pm

ah okay, I closed PMS complete restart, then I went to Video setting and play the file that said {Mencoder} here's the debug log. I also disable Tmuxer and FFmeg in PMS to it'll play only from Mencoder.
http://pastebin.com/REd7sehm
My Setup
Computer
Asus G73Jw
16Gig of ram
2x 512Gig of HDD
1 Gigabit LAN line
Geforce GTX460M

Output Setup
PS3 Slim
1000 base full band
HDMI to Denon AVR-4311CI to Samung un55ES7100 (Calibrated with X-Rite i1Pro Enhanced from Spectracal)
kanti123
 
Posts: 41
Joined: Fri Nov 25, 2011 6:02 pm

Re: Audio out of Syn with one video and not the other.

Postby ExSport » Sun Jan 20, 2013 5:33 pm

DEBUG 2013-01-21 00:06:15.260 [mencoder.exe-1] Starting "C:\Program Files (x86)\PS3 Media Server\win32\mencoder.exe" -ss 0 "D:\Anime\[HorribleSubs] Maoyuu Maou Yuusha - 03 [1080p].mkv" -msglevel statusline=2 -oac lavc -of mpeg -mpegopts format=mpeg2:muxrate=500000:vbuf_size=1194:abuf_size=64 -ovc lavc -channels 6 -lavdopts debug=0:threads=8 -lavcopts autoaspect=1:vcodec=mpeg2video:acodec=ac3:abitrate=448:threads=8:keyint=5:vqscale=1:vqmin=1:vrc_maxrate=255000:vrc_buf_size=7000 -ass -fontconfig -sid 0 -fps 24000/1001 -ofps 24000/1001 -lavdopts fast -mc 0 -noskip -af lavcresample=48000 -srate 48000 -o \\.\pipe\mencoder1358694375187

PMS wrongly detected 23.976 but it is incorrect?
DEBUG 2013-01-21 00:06:15.288 [Thread-18] MEncoder SB41 (C) 2000-2012 MPlayer Team
DEBUG 2013-01-21 00:06:15.289 [Thread-18] Custom build by SubJunk, http://www.spirton.com
DEBUG 2013-01-21 00:06:15.289 [Thread-18]
DEBUG 2013-01-21 00:06:15.291 [Thread-18] success: format: 0 data: 0x0 - 0x21b0c206
DEBUG 2013-01-21 00:06:15.291 [Thread-18] libavformat version 54.29.105 (internal)
DEBUG 2013-01-21 00:06:15.293 [Thread-18] libavformat file format detected.
DEBUG 2013-01-21 00:06:15.355 [Thread-18] [lavf] stream 0: video (h264), -vid 0
DEBUG 2013-01-21 00:06:15.355 [Thread-18] [lavf] stream 1: audio (aac), -aid 0
DEBUG 2013-01-21 00:06:15.355 [Thread-18] [lavf] stream 2: subtitle (ass), -sid 0
DEBUG 2013-01-21 00:06:15.355 [Thread-18] VIDEO: [H264] 1920x1080 0bpp 30.303 fps 0.0 kbps ( 0.0 kbyte/s)
DEBUG 2013-01-21 00:06:15.356 [Thread-18] [V] filefmt:44 fourcc:0x34363248 size:1920x1080 fps:30.303 ftime:=0.0330
DEBUG 2013-01-21 00:06:15.356 [Thread-18] Input fps will be interpreted as 23.976 instead.

Try to delete cache, disable it and restart PMS but before doing this change logging level to TRACE in logback.xml file (check FAQ) so we can see what fps is detected by FFMPEG or MEDIAINFO library.
Anyway 30.303fps is not expected fps (I am not sure if PMS will not round it to 29.997 automatically)
ExSport
 
Posts: 2167
Joined: Mon Jan 19, 2009 5:40 pm

Re: Audio out of Syn with one video and not the other.

Postby kanti123 » Sun Jan 20, 2013 5:54 pm

My Setup
Computer
Asus G73Jw
16Gig of ram
2x 512Gig of HDD
1 Gigabit LAN line
Geforce GTX460M

Output Setup
PS3 Slim
1000 base full band
HDMI to Denon AVR-4311CI to Samung un55ES7100 (Calibrated with X-Rite i1Pro Enhanced from Spectracal)
kanti123
 
Posts: 41
Joined: Fri Nov 25, 2011 6:02 pm

Re: Audio out of Syn with one video and not the other.

Postby ExSport » Mon Jan 21, 2013 3:40 pm

TRACE 2013-01-21 01:52:42.288 [Request Handler] Matched format MKV to "D:\1\[HorribleSubs] Maoyuu Maou Yuusha - 03 [1080p].mkv"
TRACE 2013-01-21 01:52:42.333 [Request Handler] Parsing results: [HorribleSubs] Maoyuu Maou Yuusha - 03 [1080p].mkv / container: mkv / bitrate: 3182613 / size: 565232134 / codecV: h264 / duration: 00:23:40.00 / width: 1920 / height: 1080 / frameRate: null / thumb size : 0 / muxingMode: null
audio: id=0 / lang: und / flavor: null / codec: aac / sf:44100 / na: 2 / bs: 16
sub: id=0 / lang: und / flavor: null / type: ASS

It seems PMS code can't parse FPS from ffmpeg/mediainfo output so NULL is used.
For now you can test this "Expert settings" (in MEncoder TAB):
Code: Select all
framerate == null :: -fps 300/9 -ofps 300/9

For all videos without framerate, 30.333fps is used. Your video is 30.303fps but this fps is not supported in MEncoder for MPEG2 transcoding.
Also you can test "30000/1001" what will give you more general 29.97 fps but the difference from 30.303fps is bigger so it will get out of sync faster.
Also I am not sure if NULL is acceptable in "Expert settings" so you can also test without the if statement ==> ":: -fps 300/9 -ofps 300/9" (all files will be played at 30.333fps!!!)
Bug is that PMS stored NULL fps in DB but also in case it will detect 30.303fps, this value can't be used by MEncoder so it will not help. It is very hard to fix it. Better to have more proper videos than this non-standard one ;)
ExSport
 
Posts: 2167
Joined: Mon Jan 19, 2009 5:40 pm

Re: Audio out of Syn with one video and not the other.

Postby kanti123 » Mon Jan 21, 2013 5:01 pm

Tried your expert setting and it didn't help :(, Can this video be convert to 23 fps ?
My Setup
Computer
Asus G73Jw
16Gig of ram
2x 512Gig of HDD
1 Gigabit LAN line
Geforce GTX460M

Output Setup
PS3 Slim
1000 base full band
HDMI to Denon AVR-4311CI to Samung un55ES7100 (Calibrated with X-Rite i1Pro Enhanced from Spectracal)
kanti123
 
Posts: 41
Joined: Fri Nov 25, 2011 6:02 pm

Next

Return to General Help and Support

Who is online

Users browsing this forum: Bing [Bot] and 20 guests