src/test/SDL_test_imageBlitBlend.c
changeset 6763 9cbd31a3450b
parent 6762 c680e085a5f2
child 6885 700f1b25f77f
     1.1 --- a/src/test/SDL_test_imageBlitBlend.c	Thu Dec 20 08:50:36 2012 -0800
     1.2 +++ b/src/test/SDL_test_imageBlitBlend.c	Sat Dec 22 16:06:55 2012 -0800
     1.3 @@ -575,6 +575,32 @@
     1.4    "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0",
     1.5  };
     1.6  
     1.7 +/**
     1.8 + * \brief Returns the BlitBlendAdd test image as SDL_Surface.
     1.9 + */
    1.10 +SDL_Surface *SDLTest_ImageBlitBlendAdd()
    1.11 +{
    1.12 +   SDL_Surface *surface = SDL_CreateRGBSurfaceFrom( 
    1.13 +        (void*)SDLTest_imageBlitBlendAdd.pixel_data,
    1.14 +        SDLTest_imageBlitBlendAdd.width, 
    1.15 +        SDLTest_imageBlitBlendAdd.height, 
    1.16 +        SDLTest_imageBlitBlendAdd.bytes_per_pixel * 8, 
    1.17 +        SDLTest_imageBlitBlendAdd.width * SDLTest_imageBlitBlendAdd.bytes_per_pixel,
    1.18 +#if (SDL_BYTEORDER == SDL_BIG_ENDIAN)
    1.19 +         0xff000000, /* Red bit mask. */
    1.20 +         0x00ff0000, /* Green bit mask. */
    1.21 +         0x0000ff00, /* Blue bit mask. */
    1.22 +         0x000000ff  /* Alpha bit mask. */
    1.23 +#else
    1.24 +         0x000000ff, /* Red bit mask. */
    1.25 +         0x0000ff00, /* Green bit mask. */
    1.26 +         0x00ff0000, /* Blue bit mask. */
    1.27 +         0xff000000  /* Alpha bit mask. */
    1.28 +#endif
    1.29 +         );
    1.30 +   return surface;
    1.31 +}
    1.32 +
    1.33  const SDLTest_SurfaceImage_t SDLTest_imageBlitBlend = {
    1.34    80, 60, 3,
    1.35    "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
    1.36 @@ -1079,6 +1105,32 @@
    1.37    "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0",
    1.38  };
    1.39  
    1.40 +/**
    1.41 + * \brief Returns the BlitBlend test image as SDL_Surface.
    1.42 + */
    1.43 +SDL_Surface *SDLTest_ImageBlitBlend()
    1.44 +{
    1.45 +   SDL_Surface *surface = SDL_CreateRGBSurfaceFrom( 
    1.46 +        (void*)SDLTest_imageBlitBlend.pixel_data,
    1.47 +        SDLTest_imageBlitBlend.width, 
    1.48 +        SDLTest_imageBlitBlend.height, 
    1.49 +        SDLTest_imageBlitBlend.bytes_per_pixel * 8, 
    1.50 +        SDLTest_imageBlitBlend.width * SDLTest_imageBlitBlend.bytes_per_pixel,
    1.51 +#if (SDL_BYTEORDER == SDL_BIG_ENDIAN)
    1.52 +         0xff000000, /* Red bit mask. */
    1.53 +         0x00ff0000, /* Green bit mask. */
    1.54 +         0x0000ff00, /* Blue bit mask. */
    1.55 +         0x000000ff  /* Alpha bit mask. */
    1.56 +#else
    1.57 +         0x000000ff, /* Red bit mask. */
    1.58 +         0x0000ff00, /* Green bit mask. */
    1.59 +         0x00ff0000, /* Blue bit mask. */
    1.60 +         0xff000000  /* Alpha bit mask. */
    1.61 +#endif
    1.62 +         );
    1.63 +   return surface;
    1.64 +}
    1.65 +
    1.66  const SDLTest_SurfaceImage_t SDLTest_imageBlitBlendMod = {
    1.67    80, 60, 3,
    1.68    "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
    1.69 @@ -1483,6 +1535,32 @@
    1.70    "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0",
    1.71  };
    1.72  
    1.73 +/**
    1.74 + * \brief Returns the BlitBlendMod test image as SDL_Surface.
    1.75 + */
    1.76 +SDL_Surface *SDLTest_ImageBlitBlendMod()
    1.77 +{
    1.78 +   SDL_Surface *surface = SDL_CreateRGBSurfaceFrom( 
    1.79 +        (void*)SDLTest_imageBlitBlendMod.pixel_data,
    1.80 +        SDLTest_imageBlitBlendMod.width, 
    1.81 +        SDLTest_imageBlitBlendMod.height, 
    1.82 +        SDLTest_imageBlitBlendMod.bytes_per_pixel * 8, 
    1.83 +        SDLTest_imageBlitBlendMod.width * SDLTest_imageBlitBlendMod.bytes_per_pixel,
    1.84 +#if (SDL_BYTEORDER == SDL_BIG_ENDIAN)
    1.85 +         0xff000000, /* Red bit mask. */
    1.86 +         0x00ff0000, /* Green bit mask. */
    1.87 +         0x0000ff00, /* Blue bit mask. */
    1.88 +         0x000000ff  /* Alpha bit mask. */
    1.89 +#else
    1.90 +         0x000000ff, /* Red bit mask. */
    1.91 +         0x0000ff00, /* Green bit mask. */
    1.92 +         0x00ff0000, /* Blue bit mask. */
    1.93 +         0xff000000  /* Alpha bit mask. */
    1.94 +#endif
    1.95 +         );
    1.96 +   return surface;
    1.97 +}
    1.98 +
    1.99  const SDLTest_SurfaceImage_t SDLTest_imageBlitBlendNone = {
   1.100    80, 60, 3,
   1.101    "\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377\377"
   1.102 @@ -2270,6 +2348,32 @@
   1.103    "\377\377\377\377\377\377\377\377",
   1.104  };
   1.105  
   1.106 +/**
   1.107 + * \brief Returns the BlitBlendNone test image as SDL_Surface.
   1.108 + */
   1.109 +SDL_Surface *SDLTest_ImageBlitBlendNone()
   1.110 +{
   1.111 +   SDL_Surface *surface = SDL_CreateRGBSurfaceFrom( 
   1.112 +        (void*)SDLTest_imageBlitBlendNone.pixel_data,
   1.113 +        SDLTest_imageBlitBlendNone.width, 
   1.114 +        SDLTest_imageBlitBlendNone.height, 
   1.115 +        SDLTest_imageBlitBlendNone.bytes_per_pixel * 8, 
   1.116 +        SDLTest_imageBlitBlendNone.width * SDLTest_imageBlitBlendNone.bytes_per_pixel,
   1.117 +#if (SDL_BYTEORDER == SDL_BIG_ENDIAN)
   1.118 +         0xff000000, /* Red bit mask. */
   1.119 +         0x00ff0000, /* Green bit mask. */
   1.120 +         0x0000ff00, /* Blue bit mask. */
   1.121 +         0x000000ff  /* Alpha bit mask. */
   1.122 +#else
   1.123 +         0x000000ff, /* Red bit mask. */
   1.124 +         0x0000ff00, /* Green bit mask. */
   1.125 +         0x00ff0000, /* Blue bit mask. */
   1.126 +         0xff000000  /* Alpha bit mask. */
   1.127 +#endif
   1.128 +         );
   1.129 +   return surface;
   1.130 +}
   1.131 +
   1.132  const SDLTest_SurfaceImage_t SDLTest_imageBlitBlendAll = {
   1.133    80, 60, 3,
   1.134    "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0"
   1.135 @@ -2712,3 +2816,28 @@
   1.136    "\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0",
   1.137  };
   1.138  
   1.139 +/**
   1.140 + * \brief Returns the BlitBlendAll test image as SDL_Surface.
   1.141 + */
   1.142 +SDL_Surface *SDLTest_ImageBlitBlendAll()
   1.143 +{
   1.144 +   SDL_Surface *surface = SDL_CreateRGBSurfaceFrom( 
   1.145 +        (void*)SDLTest_imageBlitBlendAll.pixel_data,
   1.146 +        SDLTest_imageBlitBlendAll.width, 
   1.147 +        SDLTest_imageBlitBlendAll.height, 
   1.148 +        SDLTest_imageBlitBlendAll.bytes_per_pixel * 8, 
   1.149 +        SDLTest_imageBlitBlendAll.width * SDLTest_imageBlitBlendAll.bytes_per_pixel,
   1.150 +#if (SDL_BYTEORDER == SDL_BIG_ENDIAN)
   1.151 +         0xff000000, /* Red bit mask. */
   1.152 +         0x00ff0000, /* Green bit mask. */
   1.153 +         0x0000ff00, /* Blue bit mask. */
   1.154 +         0x000000ff  /* Alpha bit mask. */
   1.155 +#else
   1.156 +         0x000000ff, /* Red bit mask. */
   1.157 +         0x0000ff00, /* Green bit mask. */
   1.158 +         0x00ff0000, /* Blue bit mask. */
   1.159 +         0xff000000  /* Alpha bit mask. */
   1.160 +#endif
   1.161 +         );
   1.162 +   return surface;
   1.163 +}