Mercurial > sdl-ios-xcode
comparison test/testgl2.c @ 1967:01e29c3e9a29
In general, fill in pointers to structures, rather than return them.
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Sat, 05 Aug 2006 22:34:23 +0000 |
parents | a788656ca29a |
children | 8055185ae4ed |
comparison
equal
deleted
inserted
replaced
1966:6472256c21eb | 1967:01e29c3e9a29 |
---|---|
163 main(int argc, char *argv[]) | 163 main(int argc, char *argv[]) |
164 { | 164 { |
165 int fsaa, accel; | 165 int fsaa, accel; |
166 int value; | 166 int value; |
167 int i, done; | 167 int i, done; |
168 SDL_DisplayMode mode; | |
168 SDL_Event event; | 169 SDL_Event event; |
169 Uint32 then, now, frames; | 170 Uint32 then, now, frames; |
170 | 171 |
171 /* Initialize parameters */ | 172 /* Initialize parameters */ |
172 fsaa = 0; | 173 fsaa = 0; |
233 SDL_GL_SetSwapInterval(1); | 234 SDL_GL_SetSwapInterval(1); |
234 } else { | 235 } else { |
235 SDL_GL_SetSwapInterval(0); | 236 SDL_GL_SetSwapInterval(0); |
236 } | 237 } |
237 | 238 |
238 printf("Screen BPP: %d\n", | 239 SDL_GetCurrentDisplayMode(&mode); |
239 SDL_BITSPERPIXEL(SDL_GetCurrentDisplayMode()->format)); | 240 printf("Screen BPP: %d\n", SDL_BITSPERPIXEL(mode.format)); |
240 printf("\n"); | 241 printf("\n"); |
241 printf("Vendor : %s\n", glGetString(GL_VENDOR)); | 242 printf("Vendor : %s\n", glGetString(GL_VENDOR)); |
242 printf("Renderer : %s\n", glGetString(GL_RENDERER)); | 243 printf("Renderer : %s\n", glGetString(GL_RENDERER)); |
243 printf("Version : %s\n", glGetString(GL_VERSION)); | 244 printf("Version : %s\n", glGetString(GL_VERSION)); |
244 printf("Extensions : %s\n", glGetString(GL_EXTENSIONS)); | 245 printf("Extensions : %s\n", glGetString(GL_EXTENSIONS)); |