From b799d94762ff24fe9a56df3774e5195d77cea8dc Mon Sep 17 00:00:00 2001 From: rogerman Date: Thu, 8 Aug 2024 12:11:20 -0700 Subject: [PATCH] Colorspace Handler: Fix compiling for strict NEON. - We could always use -flax-vector-conversions, but let's try to stay disciplined for now. --- .../utils/colorspacehandler/colorspacehandler_NEON.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/desmume/src/utils/colorspacehandler/colorspacehandler_NEON.cpp b/desmume/src/utils/colorspacehandler/colorspacehandler_NEON.cpp index fa6641fb4..aefcc8278 100644 --- a/desmume/src/utils/colorspacehandler/colorspacehandler_NEON.cpp +++ b/desmume/src/utils/colorspacehandler/colorspacehandler_NEON.cpp @@ -168,15 +168,15 @@ FORCEINLINE void ColorspaceConvert555xTo6665Opaque_NEON(const v128u16 &srcColor, template FORCEINLINE void ColorspaceConvert5551To8888_NEON(const v128u16 &srcColor, v128u32 &dstLo, v128u32 &dstHi) { - const v128s16 srcAlphaBits16 = vandq_s16( vcgtq_s16(vdupq_n_s16(0), vreinterpretq_u16_s16(srcColor)), vdupq_n_s16(0xFF00) ); - ColorspaceConvert555aTo8888_NEON(srcColor, vreinterpretq_s16_u16(srcAlphaBits16), dstLo, dstHi); + const v128u16 srcAlphaBits16 = vandq_u16( vcgtq_s16(vdupq_n_s16(0), vreinterpretq_s16_u16(srcColor)), vdupq_n_u16(0xFF00) ); + ColorspaceConvert555aTo8888_NEON(srcColor, srcAlphaBits16, dstLo, dstHi); } template FORCEINLINE void ColorspaceConvert5551To6665_NEON(const v128u16 &srcColor, v128u32 &dstLo, v128u32 &dstHi) { - const v128s16 srcAlphaBits16 = vandq_s16( vcgtq_s16(vdupq_n_s16(0), vreinterpretq_u16_s16(srcColor)), vdupq_n_s16(0x1F00) ); - ColorspaceConvert555aTo6665_NEON(srcColor, vreinterpretq_s16_u16(srcAlphaBits16), dstLo, dstHi); + const v128u16 srcAlphaBits16 = vandq_u16( vcgtq_s16(vdupq_n_s16(0), vreinterpretq_s16_u16(srcColor)), vdupq_n_u16(0x1F00) ); + ColorspaceConvert555aTo6665_NEON(srcColor, srcAlphaBits16, dstLo, dstHi); } template