2018-07-14, 17:05
Btw. as this file is 720p - could you please try to disable Surface? Also stutter?
(2018-07-14, 17:00)fritsch Wrote: Nice - Nicely linear PTS fetched and output. Cool.Bad thing is though that the delta is 40ms instead of 41.7ms. But it is actually as wrong for SPMC17 as it is for Kodi. Still, SPMC17 plays it smoothly.
Quote:Btw. as this file is 720p - could you please try to disable Surface? Also stutter?Yes. That has been written before. It does not play 100% smooth all the time in MediaCodec EGL mode, but it does not exhibit those heavy stutters every 2-3s.
(2018-07-14, 15:13)CiNcH Wrote:Quote:Not sure if MediaTek drivers look at the "original fps", if so, its IMO wrong.MediaTek should know nothing about container fps. Video decoder only receives ES, no?
And how does SPMC17 fix it? Think we haven't really understood the real problem.
Quote:Original FPS seems for me not to be in Container, its more in SPS of the stream.Yes. That's also what I assume. So everything should actually be fine as SPS fps is correct.
Quote:Even if 25 fps is wrong, it should not lead to stutter, it should lead to slightly faster playback.With mpiet's provided sample where I stripped away the audio, I agree. With audio, playing the sample at 25fps would explain those stutters, no? The Kodi behavior is actually more plausible than SPMC17 (which also plays it with a wrong 40ms frame duration but without stutters). If you play video faster, you will run into problems with audio unless you resync video by repeating frames. However it actually looks like frames get dropped rather than repeated.
Because PTS values are clearly 40ms == 25fps
Quote:Generale
ID univoco : 223753716360348807282419165092524738472 (0xA85565F3C0E1BC879715E44794B647A8)
Nome completo : E:\Telefilm\Shameless\Shameless.US.9x01.Il.prezzo.per.essere.un.Gallagher.ITA.ENG.1080p.AMZN.WEB-DLMux.H.264-Morpheus.mkv
Formato : Matroska
Versione formato : Version 4
Dimensione : 3,55 GiB
Durata : 52 min 59s
Bitrate totale : 9.591 kb/s
Data codifica : UTC 2019-02-08 22:28:39
Creato con : mkvmerge v7.1.0 ('Good Love') 32bit built on Jul 27 2014 12:59:18
Compressore : libebml v1.3.0 + libmatroska v1.4.1
Video
ID : 1
Formato : AVC
Formato/Informazioni : Advanced Video Codec
Profilo formato : High@L4
Impostazioni formato : CABAC / 4 Ref Frames
Impostazioni formato, CABAC : Si
Impostazioni formato, RefFrames : 4 frame
ID codec : V_MPEG4/ISO/AVC
Durata : 52 min 59s
Bitrate : 9.012 kb/s
Larghezza : 1.920 pixel
Altezza : 1.080 pixel
Rapporto aspetto visualizzazione : 16:9
Modalità frame rate : Costante
Frame rate : 25,000 FPS
Frame rate originale : 23,976 (24000/1001) FPS
Spazio colore : YUV
Croma subsampling : 4:2:0
Profondità bit : 8 bit
Tipo scansione : Progressivo
Bit/(pixel*frame) : 0.174
Dimensione della traccia : 3,34 GiB (94%)
Default : Si
Forced : No
colour_range : Limited
Colori primari : BT.709
Caratteristiche trasferimento : BT.709
Coefficienti matrici : BT.709
Audio #1
ID : 2
Formato : AC-3
Formato/Informazioni : Audio Coding 3
Nome commereciale : Dolby Digital
ID codec : A_AC3
Durata : 52 min 59s
Modalità bitrate : Costante
Bitrate : 192 kb/s
Canali : 2 canali
Channel layout : L R
Frequenza campionamento : 48,0 kHz
Frame rate : 31,250 FPS (1536 SPF)
Profondità bit : 16 bit
Modo compressione : Con perdita
Dimensione della traccia : 72,8MiB (2%)
Titolo : ITA
Lingua : Italiano
ServiceKind/String : Complete Main
Default : Si
Forced : Si
Audio #2
ID : 3
Formato : AC-3
Formato/Informazioni : Audio Coding 3
Nome commereciale : Dolby Digital
ID codec : A_AC3
Durata : 52 min 59s
Modalità bitrate : Costante
Bitrate : 384 kb/s
Canali : 6 canali
Channel layout : L R C LFE Ls Rs
Frequenza campionamento : 48,0 kHz
Frame rate : 31,250 FPS (1536 SPF)
Profondità bit : 16 bit
Modo compressione : Con perdita
Dimensione della traccia : 146MiB (4%)
Titolo : ENG
Lingua : Inglese
ServiceKind/String : Complete Main
Default : No
Forced : No
Testo #1
ID : 4
Formato : UTF-8
ID codec : S_TEXT/UTF8
ID codec/Informazioni : UTF-8 Plain Text
Durata : 51 min 34s
Bitrate : 6 b/s
ElementCount : 54
Dimensione della traccia : 2,40 KiB (0%)
Titolo : Forced
Lingua : Italiano
Default : Si
Forced : Si
Testo #2
ID : 5
Formato : UTF-8
ID codec : S_TEXT/UTF8
ID codec/Informazioni : UTF-8 Plain Text
Durata : 52 min 42s
Bitrate : 83 b/s
ElementCount : 970
Dimensione della traccia : 32,2 KiB (0%)
Lingua : Italiano
Default : No
Forced : No
Testo #3
ID : 6
Formato : UTF-8
ID codec : S_TEXT/UTF8
ID codec/Informazioni : UTF-8 Plain Text
Durata : 51 min 18s
Bitrate : 96 b/s
ElementCount : 1365
Dimensione della traccia : 36,2 KiB (0%)
Titolo : SDH
Lingua : Inglese
Default : No
Forced : No
(2018-01-25, 08:03)CiNcH Wrote: Since SPMC17 alphas do not suffer from this issues (SPMC16 does), I once went over the commits on top of stock Kodi and noted the most relevant (A/V related) ones. I am attaching the list for documentation...
- FIX: [amc] force immediate rendering
- FIXUP: [AT] blocking writes (also tried sample remuxed without audio)
- FIX: [AT] simplify blocking loop (also tried sample remuxed without audio)
- FIX: [amc] let droid do its ts magic
- ADD; [amc] Detect and report frames dropped in decoder
- FIX: [amcs] Adjust surface rect only when really necessary
- FIX: [droid] use CLOCK_MONOTONIC, as OS
- FIX: [droid] better texture pool
- [K] Videosync
- FIX: [droid;videosync] handle refresh rate changes (Sony does not do refresh rate changing)
- FIX: [droid;videosync] use actual vsync time
- FIX: [droid] simplify video sync
- CHG: [droid;vsync] use vblank event for videosync
I wonder why sync happens twice, in an own thread (Run method) and via FrameCallback method. And as far as I can see, both get triggered by Choreographer.FrameCallback.
- FIX: [refclock] use provided timestamp
- CHG: [droid;amc] Dynamic surface view instances
Some are more likely, some are less likey. Some have also been present in SPMC16 already which however does suffer from the issue...