From 6fe8c5ada85a59ac3f86427dc08bc70c0b239d85 Mon Sep 17 00:00:00 2001 From: ConfiG Date: Sat, 14 Oct 2023 15:29:49 +0300 Subject: [PATCH] fix msvc warnings --- include/qoixx.hpp | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/include/qoixx.hpp b/include/qoixx.hpp index e1b664f..3ab9e5c 100644 --- a/include/qoixx.hpp +++ b/include/qoixx.hpp @@ -1060,8 +1060,8 @@ class qoi{ constexpr std::uint32_t mask_tail_4 = 0b0000'1111u; const auto vr = (i >> 4); const auto vb = (i & mask_tail_4); - table[i][0] = vr; - table[i][1] = vb; + table[i][0] = static_cast(vr); + table[i][1] = static_cast(vb); } return table; } @@ -1072,9 +1072,9 @@ class qoi{ const auto vr = ((i >> 4) & mask_tail_2) - 2; const auto vg = ((i >> 2) & mask_tail_2) - 2; const auto vb = ( i & mask_tail_2) - 2; - table[i][0] = vr; - table[i][1] = vg; - table[i][2] = vb; + table[i][0] = static_cast(vr); + table[i][1] = static_cast(vg); + table[i][2] = static_cast(vb); } return table; }