src/video/SDL_blit_N.c
changeset 2247 93994f65c74c
parent 1985 8055185ae4ed
child 2257 340942cfda48
     1.1 --- a/src/video/SDL_blit_N.c	Wed Aug 15 04:04:17 2007 +0000
     1.2 +++ b/src/video/SDL_blit_N.c	Wed Aug 15 08:21:10 2007 +0000
     1.3 @@ -879,19 +879,6 @@
     1.4  #define LO	1
     1.5  #endif
     1.6  
     1.7 -#if SDL_HERMES_BLITTERS
     1.8 -
     1.9 -/* Heheheh, we coerce Hermes into using SDL blit information */
    1.10 -#define X86_ASSEMBLER
    1.11 -#define HermesConverterInterface	SDL_BlitInfo
    1.12 -#define HermesClearInterface		void
    1.13 -#define STACKCALL
    1.14 -
    1.15 -#include "../hermes/HeadMMX.h"
    1.16 -#include "../hermes/HeadX86.h"
    1.17 -
    1.18 -#else
    1.19 -
    1.20  /* Special optimized blit for RGB 8-8-8 --> RGB 3-3-2 */
    1.21  #define RGB888_RGB332(dst, src) { \
    1.22  	dst = (Uint8)((((src)&0x00E00000)>>16)| \
    1.23 @@ -1250,8 +1237,6 @@
    1.24  #endif /* USE_DUFFS_LOOP */
    1.25  }
    1.26  
    1.27 -#endif /* SDL_HERMES_BLITTERS */
    1.28 -
    1.29  
    1.30  /* Special optimized blit for RGB 5-6-5 --> 32-bit RGB surfaces */
    1.31  #define RGB565_32(dst, src, map) (map[src[LO]*2] + map[src[HI]*2+1])
    1.32 @@ -2357,17 +2342,7 @@
    1.33      {0, 0, 0, 0, 0, 0, 0, 0, NULL, NULL},
    1.34  };
    1.35  static const struct blit_table normal_blit_2[] = {
    1.36 -#if SDL_HERMES_BLITTERS
    1.37 -    {0x0000F800, 0x000007E0, 0x0000001F, 2, 0x0000001F, 0x000007E0,
    1.38 -     0x0000F800,
    1.39 -     0, ConvertX86p16_16BGR565, ConvertX86, NO_ALPHA},
    1.40 -    {0x0000F800, 0x000007E0, 0x0000001F, 2, 0x00007C00, 0x000003E0,
    1.41 -     0x0000001F,
    1.42 -     0, ConvertX86p16_16RGB555, ConvertX86, NO_ALPHA},
    1.43 -    {0x0000F800, 0x000007E0, 0x0000001F, 2, 0x0000001F, 0x000003E0,
    1.44 -     0x00007C00,
    1.45 -     0, ConvertX86p16_16BGR555, ConvertX86, NO_ALPHA},
    1.46 -#elif SDL_ALTIVEC_BLITTERS
    1.47 +#if SDL_ALTIVEC_BLITTERS
    1.48      /* has-altivec */
    1.49      {0x0000F800, 0x000007E0, 0x0000001F, 4, 0x00000000, 0x00000000,
    1.50       0x00000000,
    1.51 @@ -2397,47 +2372,6 @@
    1.52      {0, 0, 0, 0, 0, 0, 0, 0, NULL, BlitNtoN, 0}
    1.53  };
    1.54  static const struct blit_table normal_blit_4[] = {
    1.55 -#if SDL_HERMES_BLITTERS
    1.56 -    {0x00FF0000, 0x0000FF00, 0x000000FF, 2, 0x0000F800, 0x000007E0,
    1.57 -     0x0000001F,
    1.58 -     1, ConvertMMXpII32_16RGB565, ConvertMMX, NO_ALPHA},
    1.59 -    {0x00FF0000, 0x0000FF00, 0x000000FF, 2, 0x0000F800, 0x000007E0,
    1.60 -     0x0000001F,
    1.61 -     0, ConvertX86p32_16RGB565, ConvertX86, NO_ALPHA},
    1.62 -    {0x00FF0000, 0x0000FF00, 0x000000FF, 2, 0x0000001F, 0x000007E0,
    1.63 -     0x0000F800,
    1.64 -     1, ConvertMMXpII32_16BGR565, ConvertMMX, NO_ALPHA},
    1.65 -    {0x00FF0000, 0x0000FF00, 0x000000FF, 2, 0x0000001F, 0x000007E0,
    1.66 -     0x0000F800,
    1.67 -     0, ConvertX86p32_16BGR565, ConvertX86, NO_ALPHA},
    1.68 -    {0x00FF0000, 0x0000FF00, 0x000000FF, 2, 0x00007C00, 0x000003E0,
    1.69 -     0x0000001F,
    1.70 -     1, ConvertMMXpII32_16RGB555, ConvertMMX, NO_ALPHA},
    1.71 -    {0x00FF0000, 0x0000FF00, 0x000000FF, 2, 0x00007C00, 0x000003E0,
    1.72 -     0x0000001F,
    1.73 -     0, ConvertX86p32_16RGB555, ConvertX86, NO_ALPHA},
    1.74 -    {0x00FF0000, 0x0000FF00, 0x000000FF, 2, 0x0000001F, 0x000003E0,
    1.75 -     0x00007C00,
    1.76 -     1, ConvertMMXpII32_16BGR555, ConvertMMX, NO_ALPHA},
    1.77 -    {0x00FF0000, 0x0000FF00, 0x000000FF, 2, 0x0000001F, 0x000003E0,
    1.78 -     0x00007C00,
    1.79 -     0, ConvertX86p32_16BGR555, ConvertX86, NO_ALPHA},
    1.80 -    {0x00FF0000, 0x0000FF00, 0x000000FF, 3, 0x00FF0000, 0x0000FF00,
    1.81 -     0x000000FF,
    1.82 -     0, ConvertX86p32_24RGB888, ConvertX86, NO_ALPHA},
    1.83 -    {0x00FF0000, 0x0000FF00, 0x000000FF, 3, 0x000000FF, 0x0000FF00,
    1.84 -     0x00FF0000,
    1.85 -     0, ConvertX86p32_24BGR888, ConvertX86, NO_ALPHA},
    1.86 -    {0x00FF0000, 0x0000FF00, 0x000000FF, 4, 0x000000FF, 0x0000FF00,
    1.87 -     0x00FF0000,
    1.88 -     0, ConvertX86p32_32BGR888, ConvertX86, NO_ALPHA},
    1.89 -    {0x00FF0000, 0x0000FF00, 0x000000FF, 4, 0xFF000000, 0x00FF0000,
    1.90 -     0x0000FF00,
    1.91 -     0, ConvertX86p32_32RGBA888, ConvertX86, NO_ALPHA},
    1.92 -    {0x00FF0000, 0x0000FF00, 0x000000FF, 4, 0x0000FF00, 0x00FF0000,
    1.93 -     0xFF000000,
    1.94 -     0, ConvertX86p32_32BGRA888, ConvertX86, NO_ALPHA},
    1.95 -#else
    1.96  #if SDL_ALTIVEC_BLITTERS
    1.97      /* has-altivec | dont-use-prefetch */
    1.98      {0x00000000, 0x00000000, 0x00000000, 4, 0x00000000, 0x00000000,
    1.99 @@ -2460,7 +2394,6 @@
   1.100      {0x00FF0000, 0x0000FF00, 0x000000FF, 2, 0x00007C00, 0x000003E0,
   1.101       0x0000001F,
   1.102       0, NULL, Blit_RGB888_RGB555, NO_ALPHA},
   1.103 -#endif
   1.104      /* Default for 32-bit RGB source, used if no other blitter matches */
   1.105      {0, 0, 0, 0, 0, 0, 0, 0, NULL, BlitNtoN, 0}
   1.106  };
   1.107 @@ -2529,12 +2462,7 @@
   1.108              if (surface->map->table) {
   1.109                  blitfun = Blit_RGB888_index8_map;
   1.110              } else {
   1.111 -#if SDL_HERMES_BLITTERS
   1.112 -                sdata->aux_data = ConvertX86p32_8RGB332;
   1.113 -                blitfun = ConvertX86;
   1.114 -#else
   1.115                  blitfun = Blit_RGB888_index8;
   1.116 -#endif
   1.117              }
   1.118          } else {
   1.119              blitfun = BlitNto1;
   1.120 @@ -2575,13 +2503,6 @@
   1.121      }
   1.122  
   1.123  #ifdef DEBUG_ASM
   1.124 -#if SDL_HERMES_BLITTERS
   1.125 -    if (blitfun == ConvertMMX)
   1.126 -        fprintf(stderr, "Using mmx blit\n");
   1.127 -    else if (blitfun == ConvertX86)
   1.128 -        fprintf(stderr, "Using asm blit\n");
   1.129 -    else
   1.130 -#endif
   1.131      if ((blitfun == BlitNtoN) || (blitfun == BlitNto1))
   1.132          fprintf(stderr, "Using C blit\n");
   1.133      else