mirror of
https://github.com/libsdl-org/SDL.git
synced 2026-05-09 01:14:24 +02:00
Fix -Wundef warnings due to use of unguarded SDL_ARM_SIMD_BLITTERS
This commit is contained in:
@@ -411,7 +411,7 @@ static void SDL_TARGETING("mmx") BlitRGBtoRGBPixelAlphaMMX(SDL_BlitInfo *info)
|
||||
|
||||
#endif /* SDL_MMX_INTRINSICS */
|
||||
|
||||
#if SDL_ARM_SIMD_BLITTERS
|
||||
#ifdef SDL_ARM_SIMD_BLITTERS
|
||||
void BlitARGBto565PixelAlphaARMSIMDAsm(int32_t w, int32_t h, uint16_t *dst, int32_t dst_stride, uint32_t *src, int32_t src_stride);
|
||||
|
||||
static void BlitARGBto565PixelAlphaARMSIMD(SDL_BlitInfo *info)
|
||||
@@ -1335,14 +1335,14 @@ SDL_CalculateBlitA(SDL_Surface *surface)
|
||||
}
|
||||
|
||||
case 2:
|
||||
#if SDL_ARM_NEON_BLITTERS || SDL_ARM_SIMD_BLITTERS
|
||||
#if SDL_ARM_NEON_BLITTERS || defined(SDL_ARM_SIMD_BLITTERS)
|
||||
if (sf->BytesPerPixel == 4 && sf->Amask == 0xff000000 && sf->Gmask == 0xff00 && df->Gmask == 0x7e0 && ((sf->Rmask == 0xff && df->Rmask == 0x1f) || (sf->Bmask == 0xff && df->Bmask == 0x1f))) {
|
||||
#if SDL_ARM_NEON_BLITTERS
|
||||
if (SDL_HasNEON()) {
|
||||
return BlitARGBto565PixelAlphaARMNEON;
|
||||
}
|
||||
#endif
|
||||
#if SDL_ARM_SIMD_BLITTERS
|
||||
#if defined(SDL_ARM_SIMD_BLITTERS)
|
||||
if (SDL_HasARMSIMD()) {
|
||||
return BlitARGBto565PixelAlphaARMSIMD;
|
||||
}
|
||||
@@ -1373,7 +1373,7 @@ SDL_CalculateBlitA(SDL_Surface *surface)
|
||||
return BlitRGBtoRGBPixelAlphaARMNEON;
|
||||
}
|
||||
#endif
|
||||
#if SDL_ARM_SIMD_BLITTERS
|
||||
#if defined(SDL_ARM_SIMD_BLITTERS)
|
||||
if (SDL_HasARMSIMD()) {
|
||||
return BlitRGBtoRGBPixelAlphaARMSIMD;
|
||||
}
|
||||
|
||||
@@ -904,7 +904,7 @@ static enum blit_features GetBlitFeatures(void)
|
||||
#define GetBlitFeatures() ((SDL_HasMMX() ? BLIT_FEATURE_HAS_MMX : 0) | (SDL_HasARMSIMD() ? BLIT_FEATURE_HAS_ARM_SIMD : 0))
|
||||
#endif
|
||||
|
||||
#if SDL_ARM_SIMD_BLITTERS
|
||||
#if defined(SDL_ARM_SIMD_BLITTERS)
|
||||
void Blit_BGR888_RGB888ARMSIMDAsm(int32_t w, int32_t h, uint32_t *dst, int32_t dst_stride, uint32_t *src, int32_t src_stride);
|
||||
|
||||
static void Blit_BGR888_RGB888ARMSIMD(SDL_BlitInfo *info)
|
||||
@@ -3221,7 +3221,7 @@ static const struct blit_table normal_blit_2[] = {
|
||||
{ 0x00007C00, 0x000003E0, 0x0000001F, 4, 0x00000000, 0x00000000, 0x00000000,
|
||||
BLIT_FEATURE_HAS_ALTIVEC, Blit_RGB555_32Altivec, NO_ALPHA | COPY_ALPHA | SET_ALPHA },
|
||||
#endif
|
||||
#if SDL_ARM_SIMD_BLITTERS
|
||||
#ifdef SDL_ARM_SIMD_BLITTERS
|
||||
{ 0x00000F00, 0x000000F0, 0x0000000F, 4, 0x00FF0000, 0x0000FF00, 0x000000FF,
|
||||
BLIT_FEATURE_HAS_ARM_SIMD, Blit_RGB444_RGB888ARMSIMD, NO_ALPHA | COPY_ALPHA },
|
||||
#endif
|
||||
@@ -3292,7 +3292,7 @@ static const struct blit_table normal_blit_4[] = {
|
||||
{ 0x00000000, 0x00000000, 0x00000000, 2, 0x0000F800, 0x000007E0, 0x0000001F,
|
||||
BLIT_FEATURE_HAS_ALTIVEC, Blit_RGB888_RGB565Altivec, NO_ALPHA },
|
||||
#endif
|
||||
#if SDL_ARM_SIMD_BLITTERS
|
||||
#ifdef SDL_ARM_SIMD_BLITTERS
|
||||
{ 0x000000FF, 0x0000FF00, 0x00FF0000, 4, 0x00FF0000, 0x0000FF00, 0x000000FF,
|
||||
BLIT_FEATURE_HAS_ARM_SIMD, Blit_BGR888_RGB888ARMSIMD, NO_ALPHA | COPY_ALPHA },
|
||||
#endif
|
||||
|
||||
@@ -271,7 +271,7 @@ static void fill_32_neon(Uint8 *pixels, int pitch, Uint32 color, int w, int h)
|
||||
}
|
||||
#endif
|
||||
|
||||
#if SDL_ARM_SIMD_BLITTERS
|
||||
#ifdef SDL_ARM_SIMD_BLITTERS
|
||||
void FillSurfaceRect8ARMSIMDAsm(int32_t w, int32_t h, uint8_t *dst, int32_t dst_stride, uint8_t src);
|
||||
void FillSurfaceRect16ARMSIMDAsm(int32_t w, int32_t h, uint16_t *dst, int32_t dst_stride, uint16_t src);
|
||||
void FillSurfaceRect32ARMSIMDAsm(int32_t w, int32_t h, uint32_t *dst, int32_t dst_stride, uint32_t src);
|
||||
@@ -354,7 +354,7 @@ int SDL_FillSurfaceRects(SDL_Surface *dst, const SDL_Rect *rects, int count,
|
||||
}
|
||||
}
|
||||
#endif
|
||||
#if SDL_ARM_SIMD_BLITTERS
|
||||
#ifdef SDL_ARM_SIMD_BLITTERS
|
||||
if (SDL_HasARMSIMD() && dst->format->BytesPerPixel != 3 && fill_function == NULL) {
|
||||
switch (dst->format->BytesPerPixel) {
|
||||
case 1:
|
||||
|
||||
Reference in New Issue
Block a user