From 39d429e49705fe153a20dfb27421f1246237a683 Mon Sep 17 00:00:00 2001 From: kobewi Date: Tue, 8 Mar 2022 15:10:48 +0100 Subject: Change some math macros to constexpr Changes `MAX`, `MIN`, `ABS`, `CLAMP` and `SIGN`. --- core/io/image.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'core/io/image.cpp') diff --git a/core/io/image.cpp b/core/io/image.cpp index 577fc59807..766c84bdbe 100644 --- a/core/io/image.cpp +++ b/core/io/image.cpp @@ -1465,8 +1465,8 @@ template static void _generate_po2_mipmap(const Component *p_src, Component *p_dst, uint32_t p_width, uint32_t p_height) { //fast power of 2 mipmap generation - uint32_t dst_w = MAX(p_width >> 1, 1); - uint32_t dst_h = MAX(p_height >> 1, 1); + uint32_t dst_w = MAX(p_width >> 1, 1u); + uint32_t dst_h = MAX(p_height >> 1, 1u); int right_step = (p_width == 1) ? 0 : CC; int down_step = (p_height == 1) ? 0 : (p_width * CC); -- cgit v1.2.3