From: Steinar H. Gunderson Date: Fri, 1 Mar 2019 22:29:28 +0000 (+0100) Subject: Make TIMEBASE signed again; unsigned caused pts bugs, as signed * unsigned = signed. X-Git-Tag: 1.8.3~24 X-Git-Url: https://git.sesse.net/?p=nageru;a=commitdiff_plain;h=6418f4d7f875c13044c3c8561a4b84d7c4af6192 Make TIMEBASE signed again; unsigned caused pts bugs, as signed * unsigned = signed. --- diff --git a/shared/timebase.h b/shared/timebase.h index ba20d7f..823ae56 100644 --- a/shared/timebase.h +++ b/shared/timebase.h @@ -17,7 +17,7 @@ // If we also wanted to represent one sample at 48000 Hz, we'd need // to go to 300000. Also supporting one sample at 44100 Hz would mean // going to 44100000; probably a bit excessive. -constexpr uint64_t TIMEBASE = 120000; +constexpr int64_t TIMEBASE = 120000; // Some muxes, like MP4 (or at least avformat's implementation of it), // are not too fond of values above 2^31. At timebase 120000, that's only