comparison render_sdl.c @ 339:80d934369fd5

Increase sample size for min_delay
author Mike Pavone <pavone@retrodev.com>
date Wed, 15 May 2013 22:39:36 -0700
parents 5c34a9c39394
children 58a085cfc6bd
comparison
equal deleted inserted replaced
338:5c34a9c39394 339:80d934369fd5
48 r = levels[color & 0xE]; 48 r = levels[color & 0xE];
49 } 49 }
50 color_map[color] = SDL_MapRGB(screen->format, r, g, b); 50 color_map[color] = SDL_MapRGB(screen->format, r, g, b);
51 } 51 }
52 min_delay = 0; 52 min_delay = 0;
53 for (int i = 0; i < 20; i++) { 53 for (int i = 0; i < 100; i++) {
54 uint32_t start = SDL_GetTicks(); 54 uint32_t start = SDL_GetTicks();
55 SDL_Delay(1); 55 SDL_Delay(1);
56 uint32_t delay = SDL_GetTicks()-start; 56 uint32_t delay = SDL_GetTicks()-start;
57 if (delay > min_delay) { 57 if (delay > min_delay) {
58 min_delay = delay; 58 min_delay = delay;