From 1588c2f3da5c7e92a885eef4296a91a1286d392b Mon Sep 17 00:00:00 2001 From: Lukas Volf Date: Sun, 21 May 2023 13:43:28 +0200 Subject: [PATCH] B Fixed wrong function being used to calculate the timescale https://github.com/sannies/mp4parser/issues/443 --- src/SharpMp4Parser/SharpMp4Parser/Muxer/Movie.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/SharpMp4Parser/SharpMp4Parser/Muxer/Movie.cs b/src/SharpMp4Parser/SharpMp4Parser/Muxer/Movie.cs index c7d7364..70e7537 100644 --- a/src/SharpMp4Parser/SharpMp4Parser/Muxer/Movie.cs +++ b/src/SharpMp4Parser/SharpMp4Parser/Muxer/Movie.cs @@ -103,7 +103,7 @@ public long getTimescale() long timescale = enumerator.Current.getTrackMetaData().getTimescale(); foreach (Track track in this.getTracks()) { - timescale = Mp4Math.gcd(track.getTrackMetaData().getTimescale(), timescale); + timescale = Mp4Math.lcm(track.getTrackMetaData().getTimescale(), timescale); } return timescale; }