# HG changeset patch # User Mike Gorchak # Date 1255433076 0 # Node ID 45f140dd4b089ca5619bb81484037b67e06b2f72 # Parent 2b0a3b2f2fc65e425c4f05549562150d5e6ca85e Options --double --triple have been added to test double and triple buffering. diff -r 2b0a3b2f2fc6 -r 45f140dd4b08 test/common.c --- a/test/common.c Tue Oct 13 07:02:19 2009 +0000 +++ b/test/common.c Tue Oct 13 11:24:36 2009 +0000 @@ -6,7 +6,7 @@ #include "common.h" #define VIDEO_USAGE \ -"[--video driver] [--renderer driver] [--info all|video|modes|render|event] [--display %d] [--fullscreen | --windows N] [--title title] [--center | --position X,Y] [--geometry WxH] [--depth N] [--refresh R] [--vsync] [--noframe] [--resize] [--minimize] [--maximize] [--grab]" +"[--video driver] [--renderer driver] [--info all|video|modes|render|event] [--display %d] [--fullscreen | --windows N] [--title title] [--center | --position X,Y] [--geometry WxH] [--depth N] [--refresh R] [--vsync] [--noframe] [--resize] [--minimize] [--maximize] [--grab] [--double] [--triple]" #define AUDIO_USAGE \ "[--rate N] [--format U8|S8|U16|U16LE|U16BE|S16|S16LE|S16BE] [--channels N] [--samples N]" @@ -233,6 +233,14 @@ state->render_flags |= SDL_RENDERER_PRESENTVSYNC; return 1; } + if (SDL_strcasecmp(argv[index], "--double") == 0) { + state->render_flags |= SDL_RENDERER_PRESENTFLIP2; + return 1; + } + if (SDL_strcasecmp(argv[index], "--triple") == 0) { + state->render_flags |= SDL_RENDERER_PRESENTFLIP3; + return 1; + } if (SDL_strcasecmp(argv[index], "--noframe") == 0) { state->window_flags |= SDL_WINDOW_BORDERLESS; return 1;