INTERACT FORUM

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1]   Go Down

Author Topic: How Variable Frame Rates MKV are rendered?  (Read 1599 times)

tij

  • MC Beta Team
  • Citizen of the Universe
  • *****
  • Posts: 1563
How Variable Frame Rates MKV are rendered?
« on: May 03, 2022, 12:18:44 pm »

This has mostly to do with HD/UHD Blu-ray that have seamless branching (several versions of movies on one disk ... Theatrical, Director's Cut, etc ... videos are made up of several files/segments that are link together during playback).

Ideally, segments should have video and audio of exact same length ... so you do not loose audio/video sync over time. However, thats rarely the case. But BluRay players able to handle this (with exception of really badly mastered disks). And incidentally folder structure rips plays without apparent problems with JRiver or MPC-HC or VLC

At some point I started to back up seamless branch disk with Atmos audio with MKVToolnix ... as MakeMKV at that time could produced audio drop outs at segment joint. MakeMKV fixed this some time ago.

This was not a problem until I notice slight pop sound at segment joint with MKVToolnix  MKV. Its barely audible, but once you know its there, can always here it. So I tried MakeMKV again, and could not here that pop.

So I dig a bit deeper ... extracted time stamps from relevant MKVs and apparently

*MakeMKV tries to keep frame rates of both video and audio constant. If audio of segment is shorter than video, silence is inserted. If its longer, audio frames are dropped to keep things in sync (note: audio frames ... not video frames)

*MKVToolnix apparently does not drop any frames. Instead it varies frame rate. For example, one segment has video ending at 49341ns while audio ends at 49344ns. To sync MKVToolnix made that video end at 49344ns, making last frame 3ns longer (so the end frame become 44ns long instead of 41.7ns).

So for branching disk, MKVToolnix usually produced longer videos as some frames are made longer to sync. The increased length usually goes up the more branching segments you have.

Presumably this variable frame rate produces this slight pop. And here is the question

* how does video renderers render this 44ns frame ... if display is locked at 23.976fps (aka 41.7ns per frame) ... is this the reason for sound pop?
* which is better way to sync audio ... MakeMKV way ... or MKVToolnix way

PS. What bothers me with MakeMKV ... frame removal is not consistent ... i ran MakeMKV several times on same folder structure backup with same settings  ... and sometime it dropped 2 frames total ... sometimes 3 frames



Logged
HTPC: Win11 Pro, MC: latest 31(64b), NV Driver: v425.31, CPU: i9-12900K, 32GB RAM, GeForce: 2080ti
Screen: LG 2016 E6
NAS: FreeNAS 11.1, SuperMicro SSG-5048R-E1CR36L, E5-1620v4, 64GB ECC RAM, 18xUltrastar He12-SAS3 drives, 2x240GB SSD (OS)
Pages: [1]   Go Up