diff --git a/lib/audiodev/AudioMatrix.hpp b/lib/audiodev/AudioMatrix.hpp index ccc31f1..cce679c 100644 --- a/lib/audiodev/AudioMatrix.hpp +++ b/lib/audiodev/AudioMatrix.hpp @@ -25,7 +25,7 @@ static inline int16_t Clamp16(float in) { static inline int32_t Clamp32(float in) { if (in < INT_MIN) return INT_MIN; - else if (in > INT_MAX) + else if (in > static_cast(INT_MAX)) return INT_MAX; return in; } diff --git a/lib/audiodev/AudioSubmix.cpp b/lib/audiodev/AudioSubmix.cpp index ca9ddd7..4565648 100644 --- a/lib/audiodev/AudioSubmix.cpp +++ b/lib/audiodev/AudioSubmix.cpp @@ -101,7 +101,7 @@ constexpr T ClampInt(float in) { if (in < MIN) return MIN; - else if (in > MAX) + else if (in > static_cast(MAX)) return MAX; else return in;