changeset 58:76a7d469eab9

Cleanup.
author Matti Hamalainen <ccr@tnsp.org>
date Mon, 01 Oct 2012 07:09:37 +0300
parents 2edda27f951c
children c560703e85ed
files blittest.c
diffstat 1 files changed, 1 insertions(+), 35 deletions(-) [+]
line wrap: on
line diff
--- a/blittest.c	Mon Oct 01 07:01:38 2012 +0300
+++ b/blittest.c	Mon Oct 01 07:09:37 2012 +0300
@@ -17,7 +17,7 @@
     { 3, 'f', "full",       "Fullscreen", OPT_NONE },
     { 4, 'h', "hw",         "Use SDL hardware surface", OPT_NONE },
     { 5, 's', "size",       "Initial window size/resolution -s 640x480", OPT_ARGREQ },
-    { 6, 'd', "depth",      "Color depth of mode/window in bits (8/15/16/32)", OPT_ARGREQ },
+    { 6, 'd', "depth",      "Color depth of mode/window in bits (8/32)", OPT_ARGREQ },
     { 7, 'b', "bench",      "Run in benchmark mode", OPT_NONE },
 };
 
@@ -300,7 +300,6 @@
     SDL_Surface *screen = NULL, *bmap = NULL;
     TTF_Font *font = NULL;
     SDL_Color fontcol={255,155,155,0};
-    Uint32 lcol;
     SDL_Event event;
     int mouseX, mouseY;
     BOOL initSDL = FALSE, initTTF = FALSE, exitFlag, showMap = FALSE;
@@ -367,8 +366,6 @@
 
 
 
-    lcol = dmMapRGB(screen, 255,100,100);
-
     int numFrames = 0, startTime = SDL_GetTicks(), endTime = 0;
     exitFlag = FALSE;
 
@@ -426,43 +423,12 @@
         }
 
 
-        float f = SDL_GetTicks() / 250.0f;
-
-#if 1
         if (showMap)
             memcpy(bmap->pixels, heightMap, QWIDTH * QHEIGHT);
         else
             dmShadowTraceHeightMap(bmap->pixels, heightMap, &light);
         
         dmScaledBlitSurfaceAny(bmap, 0, 0, screen->w, screen->h, screen, DMD_NONE);
-#else
-        dmScaledBlitSurfaceAny(bmap,
-            100 + sin(f) * 50,
-            100 + cos(f) * 50,
-            screen->w - 200 + 50 * cos(f),
-            screen->h - 200 + 50 * sin(f),
-            screen, DMD_NONE);
-
-        dmScaledBlitSurfaceAny(bmap,
-            200 + sin(f) * 50,
-            200 + cos(f) * 50,
-            50 + 50 * cos(f),
-            50 + 50 * sin(f),
-            screen, DMD_NONE);
-
-        dmScaledBlitSurfaceAny(bmap,
-            400,
-            200,
-            50 + 50 * cos(f),
-            50 + 50 * sin(f),
-            screen, DMD_NONE);
-
-/*
-        dmDrawLineAny(screen, 30, 30, 600 + 200 * sin(f), 250              , lcol, DMD_NONE);
-        dmDrawLineAny(screen, 20, 30, 100              , 250 + 100 * sin(f), lcol, DMD_NONE);
-        dmDrawLineAny(screen, 100, 100, 100 + cos(f) * 50, 100 + sin(f) * 50, lcol, DMD_NONE);
-*/
-#endif
 
         if (!optBenchmark)
         {