diff test/automated/surface/surface.c @ 5143:e743b9c3f6d6

Making the API simpler, the blend modes are "none, blend, add" and are supported by all renderers.
author Sam Lantinga <slouken@libsdl.org>
date Mon, 31 Jan 2011 23:23:57 -0800
parents 947201caa46e
children 3e4086b3bcd2
line wrap: on
line diff
--- a/test/automated/surface/surface.c	Mon Jan 31 22:53:45 2011 -0800
+++ b/test/automated/surface/surface.c	Mon Jan 31 23:23:57 2011 -0800
@@ -480,13 +480,6 @@
             surface_compare( testsur, &img_blendNone, 0 )==0 ))
       return;
 
-   /* Test Mask. */
-   if (surface_testBlitBlendMode( testsur, face, SDL_BLENDMODE_MASK ))
-      return;
-   if (SDL_ATassert( "Blitting blending output not the same (using SDL_BLENDMODE_MASK).",
-            surface_compare( testsur, &img_blendMask, 0 )==0 ))
-      return;
-
    /* Test Blend. */
    if (surface_testBlitBlendMode( testsur, face, SDL_BLENDMODE_BLEND ))
       return;
@@ -501,13 +494,6 @@
             surface_compare( testsur, &img_blendAdd, 0 )==0 ))
       return;
 
-   /* Test Mod. */
-   if (surface_testBlitBlendMode( testsur, face, SDL_BLENDMODE_MOD ))
-      return;
-   if (SDL_ATassert( "Blitting blending output not the same (using SDL_BLENDMODE_MOD).",
-            surface_compare( testsur, &img_blendMod, 0 )==0 ))
-      return;
-
    /* Clear surface. */
    ret = SDL_FillRect( testsur, NULL,
          SDL_MapRGB( testsur->format, 0, 0, 0 ) );
@@ -530,10 +516,10 @@
 
          /* Crazy blending mode magic. */
          mode = (i/4*j/4) % 4;
-         if (mode==0) mode = SDL_BLENDMODE_MASK;
+         if (mode==0) mode = SDL_BLENDMODE_NONE;
          else if (mode==1) mode = SDL_BLENDMODE_BLEND;
          else if (mode==2) mode = SDL_BLENDMODE_ADD;
-         else if (mode==3) mode = SDL_BLENDMODE_MOD;
+         else if (mode==3) mode = SDL_BLENDMODE_NONE;
          ret = SDL_SetSurfaceBlendMode( face, mode );
          if (SDL_ATassert( "SDL_SetSurfaceBlendMode", ret == 0))
             return;