Merge pull request #5562 from J08nY/hq2x-fix

Fixed HQ2x compiler warnings
This commit is contained in:
Rémi Verschelde 2016-07-05 22:04:44 +02:00 committed by GitHub
commit 647dc1e214
1 changed files with 2 additions and 2 deletions

View File

@ -91,7 +91,7 @@ _FORCE_INLINE_ static bool isDifferent(
#define HQX_MIX_2(C0,C1,W0,W1) \
((((C0 & MASK_RB) * W0 + (C1 & MASK_RB) * W1) / (W0 + W1)) & MASK_RB) | \
((((C0 & MASK_G) * W0 + (C1 & MASK_G) * W1) / (W0 + W1)) & MASK_G) | \
(((((C0 & MASK_A) >> 8) * W0 + ((C1 & MASK_A) >> 8) * W1) / (W0 + W1)) << 8) & MASK_A
((((((C0 & MASK_A) >> 8) * W0 + ((C1 & MASK_A) >> 8) * W1) / (W0 + W1)) << 8) & MASK_A)
/**
* @brief Mixes three colors using the given weights.
@ -99,7 +99,7 @@ _FORCE_INLINE_ static bool isDifferent(
#define HQX_MIX_3(C0,C1,C2,W0,W1,W2) \
((((C0 & MASK_RB) * W0 + (C1 & MASK_RB) * W1 + (C2 & MASK_RB) * W2) / (W0 + W1 + W2)) & MASK_RB) | \
((((C0 & MASK_G) * W0 + (C1 & MASK_G) * W1 + (C2 & MASK_G) * W2) / (W0 + W1 + W2)) & MASK_G) | \
(((((C0 & MASK_A) >> 8) * W0 + ((C1 & MASK_A) >> 8) * W1 + ((C2 & MASK_A) >> 8) * W2) / (W0 + W1 + W2)) << 8) & MASK_A
((((((C0 & MASK_A) >> 8) * W0 + ((C1 & MASK_A) >> 8) * W1 + ((C2 & MASK_A) >> 8) * W2) / (W0 + W1 + W2)) << 8) & MASK_A)
#define MIX_00_4 *output = w[4];