diff test/automated/render/render.c @ 3536:0267b8b1595c

Added interfaces for batch drawing of points, lines and rects: SDL_DrawPoints() SDL_BlendPoints() SDL_BlendLines() SDL_DrawLines() SDL_FillRects() SDL_BlendRects() SDL_RenderPoints() SDL_RenderLines() SDL_RenderRects() Renamed SDL_RenderFill() to SDL_RenderRect()
author Sam Lantinga <slouken@libsdl.org>
date Wed, 09 Dec 2009 15:56:56 +0000
parents 61b7f5821576
children 5f038ec1a1af
line wrap: on
line diff
--- a/test/automated/render/render.c	Mon Dec 07 10:08:24 2009 +0000
+++ b/test/automated/render/render.c	Wed Dec 09 15:56:56 2009 +0000
@@ -340,9 +340,9 @@
    */
 
    /* Clear screen. */
-   ret = SDL_RenderFill( NULL );
+   ret = SDL_RenderRect( NULL );
    /*
-   if (SDL_ATassert( "SDL_RenderFill", ret == 0))
+   if (SDL_ATassert( "SDL_RenderRect", ret == 0))
       return -1;
    */
 
@@ -387,7 +387,7 @@
    ret = SDL_SetRenderDrawColor( 13, 73, 200, SDL_ALPHA_OPAQUE );
    if (SDL_ATassert( "SDL_SetRenderDrawColor", ret == 0))
       return -1;
-   ret = SDL_RenderFill( &rect );
+   ret = SDL_RenderRect( &rect );
    if (SDL_ATassert( "SDL_RenderRect", ret == 0))
       return -1;
 
@@ -399,7 +399,7 @@
    ret = SDL_SetRenderDrawColor( 200, 0, 100, SDL_ALPHA_OPAQUE );
    if (SDL_ATassert( "SDL_SetRenderDrawColor", ret == 0))
       return -1;
-   ret = SDL_RenderFill( &rect );
+   ret = SDL_RenderRect( &rect );
    if (SDL_ATassert( "SDL_RenderRect", ret == 0))
       return -1;
 
@@ -480,8 +480,8 @@
    ret = SDL_SetRenderDrawBlendMode( SDL_BLENDMODE_NONE );
    if (SDL_ATassert( "SDL_SetRenderDrawBlendMode", ret == 0))
       return -1;
-   ret = SDL_RenderFill( NULL );
-   if (SDL_ATassert( "SDL_RenderFill", ret == 0))
+   ret = SDL_RenderRect( NULL );
+   if (SDL_ATassert( "SDL_RenderRect", ret == 0))
       return -1;
    rect.x = 10;
    rect.y = 25;
@@ -493,8 +493,8 @@
    ret = SDL_SetRenderDrawBlendMode( SDL_BLENDMODE_ADD );
    if (SDL_ATassert( "SDL_SetRenderDrawBlendMode", ret == 0))
       return -1;
-   ret = SDL_RenderFill( &rect );
-   if (SDL_ATassert( "SDL_RenderFill", ret == 0))
+   ret = SDL_RenderRect( &rect );
+   if (SDL_ATassert( "SDL_RenderRect", ret == 0))
       return -1;
    rect.x = 30;
    rect.y = 40;
@@ -506,8 +506,8 @@
    ret = SDL_SetRenderDrawBlendMode( SDL_BLENDMODE_BLEND );
    if (SDL_ATassert( "SDL_SetRenderDrawBlendMode", ret == 0))
       return -1;
-   ret = SDL_RenderFill( &rect );
-   if (SDL_ATassert( "SDL_RenderFill", ret == 0))
+   ret = SDL_RenderRect( &rect );
+   if (SDL_ATassert( "SDL_RenderRect", ret == 0))
       return -1;
    rect.x = 25;
    rect.y = 25;
@@ -519,8 +519,8 @@
    ret = SDL_SetRenderDrawBlendMode( SDL_BLENDMODE_MOD );
    if (SDL_ATassert( "SDL_SetRenderDrawBlendMode", ret == 0))
       return -1;
-   ret = SDL_RenderFill( &rect );
-   if (SDL_ATassert( "SDL_RenderFill", ret == 0))
+   ret = SDL_RenderRect( &rect );
+   if (SDL_ATassert( "SDL_RenderRect", ret == 0))
       return -1;
 
    /* Draw blended lines, lines for everyone. */