summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJinghua Luo <sunmoon1997@gmail.com>2007-02-04 14:25:18 +0800
committerJinghua Luo <sunmoon1997@gmail.com>2007-02-04 14:25:18 +0800
commita06f01bd77284af60bbf1a6ca6a1f3576fa1160c (patch)
treeea76a7d1a746114cf65dafbcf150f3a76cf36d07
parent9062f3acc189bd0babfcec6f3a10d35dbf194a6f (diff)
test: cleanup opengl test.
-rw-r--r--src/sdl-opengl-test.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/sdl-opengl-test.c b/src/sdl-opengl-test.c
index b0d77c8..d622d9b 100644
--- a/src/sdl-opengl-test.c
+++ b/src/sdl-opengl-test.c
@@ -23,10 +23,8 @@ main(int argc, char *argv[])
sdl_freetype_text_extents_t extents;
/* Initialize SDL */
- if (SDL_Init(SDL_INIT_VIDEO) < 0) {
- fprintf(stderr, "Couldn't initialize SDL: %s\n", SDL_GetError());
+ if (SDL_Init(SDL_INIT_VIDEO) < 0)
goto errquit0;
- }
videoflags = SDL_HWSURFACE;
videoflags |= SDL_OPENGL;
@@ -34,11 +32,8 @@ main(int argc, char *argv[])
/* Set 640x480 video mode */
screen = SDL_SetVideoMode(640, 480, video_bpp, videoflags);
- if (!screen) {
- fprintf(stderr, "Couldn't set 640x480x%d video mode: %s\n",
- video_bpp, SDL_GetError());
+ if (!screen)
goto errquit0;
- }
font = sdl_ft_create_font ("sans", 20,
SDL_FT_WEIGHT_NORMAL, SDL_FT_SLANT_NORMAL, 96);