diff options
| author | Pokechu22 <Pokechu022@gmail.com> | 2021-04-01 14:30:01 -0700 |
|---|---|---|
| committer | Pokechu22 <Pokechu022@gmail.com> | 2021-04-02 10:18:18 -0700 |
| commit | 004dfd1586f787f27f36c4326b9222a314295735 (patch) | |
| tree | d00fdf2411f117a66f64def7ca1e59661d1ce642 /Source/Core/VideoCommon/TextureDecoder_x64.cpp | |
| parent | a2fa9aab5be3ec4916bd3beb05163c325dcbc9dd (diff) | |
Replace uses of cassert with Common/Assert.h
Diffstat (limited to 'Source/Core/VideoCommon/TextureDecoder_x64.cpp')
| -rw-r--r-- | Source/Core/VideoCommon/TextureDecoder_x64.cpp | 20 |
1 files changed, 12 insertions, 8 deletions
diff --git a/Source/Core/VideoCommon/TextureDecoder_x64.cpp b/Source/Core/VideoCommon/TextureDecoder_x64.cpp index ea8f3e2e43..2ee2ec48f5 100644 --- a/Source/Core/VideoCommon/TextureDecoder_x64.cpp +++ b/Source/Core/VideoCommon/TextureDecoder_x64.cpp @@ -6,6 +6,10 @@ #include <cmath> #include <cstring> +#ifdef CHECK +#include "Common/Assert.h" +#endif + #include "Common/CPUDetect.h" #include "Common/CommonTypes.h" #include "Common/Intrinsics.h" @@ -1362,8 +1366,8 @@ static void TexDecoder_DecodeImpl_CMPR(u32* dst, const u8* src, int width, int h dst32[(width * 0) + 6] = colors1[(dxt1sel >> ((0 * 8) + 2)) & 3]; dst32[(width * 0) + 7] = colors1[(dxt1sel >> ((0 * 8) + 0)) & 3]; #ifdef CHECK - assert(memcmp(&(tmp0[0]), &dst32[(width * 0)], 16) == 0); - assert(memcmp(&(tmp1[0]), &dst32[(width * 0) + 4], 16) == 0); + ASSERT(memcmp(&(tmp0[0]), &dst32[(width * 0)], 16) == 0); + ASSERT(memcmp(&(tmp1[0]), &dst32[(width * 0) + 4], 16) == 0); #endif // Row 1: dst32[(width * 1) + 0] = colors0[(dxt0sel >> ((1 * 8) + 6)) & 3]; @@ -1375,8 +1379,8 @@ static void TexDecoder_DecodeImpl_CMPR(u32* dst, const u8* src, int width, int h dst32[(width * 1) + 6] = colors1[(dxt1sel >> ((1 * 8) + 2)) & 3]; dst32[(width * 1) + 7] = colors1[(dxt1sel >> ((1 * 8) + 0)) & 3]; #ifdef CHECK - assert(memcmp(&(tmp0[1]), &dst32[(width * 1)], 16) == 0); - assert(memcmp(&(tmp1[1]), &dst32[(width * 1) + 4], 16) == 0); + ASSERT(memcmp(&(tmp0[1]), &dst32[(width * 1)], 16) == 0); + ASSERT(memcmp(&(tmp1[1]), &dst32[(width * 1) + 4], 16) == 0); #endif // Row 2: dst32[(width * 2) + 0] = colors0[(dxt0sel >> ((2 * 8) + 6)) & 3]; @@ -1388,8 +1392,8 @@ static void TexDecoder_DecodeImpl_CMPR(u32* dst, const u8* src, int width, int h dst32[(width * 2) + 6] = colors1[(dxt1sel >> ((2 * 8) + 2)) & 3]; dst32[(width * 2) + 7] = colors1[(dxt1sel >> ((2 * 8) + 0)) & 3]; #ifdef CHECK - assert(memcmp(&(tmp0[2]), &dst32[(width * 2)], 16) == 0); - assert(memcmp(&(tmp1[2]), &dst32[(width * 2) + 4], 16) == 0); + ASSERT(memcmp(&(tmp0[2]), &dst32[(width * 2)], 16) == 0); + ASSERT(memcmp(&(tmp1[2]), &dst32[(width * 2) + 4], 16) == 0); #endif // Row 3: dst32[(width * 3) + 0] = colors0[(dxt0sel >> ((3 * 8) + 6)) & 3]; @@ -1401,8 +1405,8 @@ static void TexDecoder_DecodeImpl_CMPR(u32* dst, const u8* src, int width, int h dst32[(width * 3) + 6] = colors1[(dxt1sel >> ((3 * 8) + 2)) & 3]; dst32[(width * 3) + 7] = colors1[(dxt1sel >> ((3 * 8) + 0)) & 3]; #ifdef CHECK - assert(memcmp(&(tmp0[3]), &dst32[(width * 3)], 16) == 0); - assert(memcmp(&(tmp1[3]), &dst32[(width * 3) + 4], 16) == 0); + ASSERT(memcmp(&(tmp0[3]), &dst32[(width * 3)], 16) == 0); + ASSERT(memcmp(&(tmp1[3]), &dst32[(width * 3) + 4], 16) == 0); #endif } } |
