From: Chris Tallon Date: Thu, 21 May 2020 15:14:07 +0000 (+0100) Subject: 2 CWFs in videoomx.h X-Git-Url: https://git.vomp.tv/gitweb/?a=commitdiff_plain;h=9233b5a53c6b62187cdf3c164c3de0d39bc3a4d2;p=vompclient.git 2 CWFs in videoomx.h --- diff --git a/videoomx.h b/videoomx.h index 1143349..c78e5e6 100644 --- a/videoomx.h +++ b/videoomx.h @@ -132,17 +132,16 @@ class VideoOMX : public Video int test2(); #endif - - - static inline OMX_TICKS intToOMXTicks(long long pts) { - OMX_TICKS temp; - temp.nLowPart=pts; - temp.nHighPart=pts>>32; - return temp; + static inline OMX_TICKS intToOMXTicks(long long pts) + { + OMX_TICKS temp; + // Assigning a long long int to an int drops the MSBs which is what we want here + // But to avoid a -Wconversion warning, cast it + temp.nLowPart = static_cast(pts); + temp.nHighPart = static_cast(pts >> 32); + return temp; } - - private: int EnterIframePlayback(); bool iframemode;