mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2024-11-27 04:01:08 +00:00
matroska-demux: Allow a bit more variation when detecting common framerates
Instead of +/- 1ns we allow 2ns now. Due to rounding errors there are some Matroska files out there with 33.333331ms per frame for 30fps.
This commit is contained in:
parent
20ad174679
commit
fb14f66696
1 changed files with 1 additions and 1 deletions
|
@ -4930,7 +4930,7 @@ gst_duration_to_fraction (guint64 duration, gint * dest_n, gint * dest_d)
|
|||
d = common_den[i];
|
||||
n = floor (0.5 + (d * 1e9) / duration);
|
||||
a = gst_util_uint64_scale_int (1000000000, d, n);
|
||||
if (duration >= a - 1 && duration <= a + 1) {
|
||||
if (duration >= a - 2 && duration <= a + 2) {
|
||||
goto out;
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue