Fixed compiling YUV code
authorSam Lantinga <slouken@libsdl.org>
Wed, 11 Jul 2007 14:50:21 +0000
changeset 2172bef26cfc8f79
parent 2171 4bd2dc41fc15
child 2173 26233707bc94
Fixed compiling YUV code
src/video/SDL_yuv_sw.c
     1.1 --- a/src/video/SDL_yuv_sw.c	Wed Jul 11 14:49:44 2007 +0000
     1.2 +++ b/src/video/SDL_yuv_sw.c	Wed Jul 11 14:50:21 2007 +0000
     1.3 @@ -981,7 +981,8 @@
     1.4  #if (__GNUC__ > 2) && defined(__i386__) && SDL_ASSEMBLY_ROUTINES
     1.5              /* inline assembly functions */
     1.6              if (SDL_HasMMX() && (Rmask == 0xF800) &&
     1.7 -                (Gmask == 0x07E0) && (Bmask == 0x001F) && (width & 15) == 0) {
     1.8 +                (Gmask == 0x07E0) && (Bmask == 0x001F)
     1.9 +                && (swdata->texture->w & 15) == 0) {
    1.10  /*printf("Using MMX 16-bit 565 dither\n");*/
    1.11                  swdata->Display1X = Color565DitherYV12MMX1X;
    1.12              } else {
    1.13 @@ -1002,7 +1003,7 @@
    1.14              /* inline assembly functions */
    1.15              if (SDL_HasMMX() && (Rmask == 0x00FF0000) &&
    1.16                  (Gmask == 0x0000FF00) &&
    1.17 -                (Bmask == 0x000000FF) && (width & 15) == 0) {
    1.18 +                (Bmask == 0x000000FF) && (swdata->texture->w & 15) == 0) {
    1.19  /*printf("Using MMX 32-bit dither\n");*/
    1.20                  swdata->Display1X = ColorRGBDitherYV12MMX1X;
    1.21              } else {