From 8dde3b25486761f1f93efb2448d20f4f1b84ac90 Mon Sep 17 00:00:00 2001 From: terminx Date: Sat, 5 Mar 2011 07:17:00 +0000 Subject: [PATCH] Fix a couple of warnings when building with SDL 1.3 git-svn-id: https://svn.eduke32.com/eduke32@1829 1a8010ca-5511-0410-912e-c29ae57300e0 --- polymer/eduke32/build/src/sdlayer.c | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/polymer/eduke32/build/src/sdlayer.c b/polymer/eduke32/build/src/sdlayer.c index 4ee6ab552..fc8b957d1 100644 --- a/polymer/eduke32/build/src/sdlayer.c +++ b/polymer/eduke32/build/src/sdlayer.c @@ -795,11 +795,12 @@ void getvalidmodes(void) 0 }; SDL_Rect **modes; -#if (SDL_MAJOR_VERSION > 1 || SDL_MINOR_VERSION > 2) - SDL_PixelFormat pf = { NULL, 8, 1, 0,0,0,0, 0,0,0,0, 0,0,0,0 }; -#else - SDL_PixelFormat pf = { NULL, 8, 1, 0,0,0,0, 0,0,0,0, 0,0,0,0, 0,0 }; -#endif + SDL_PixelFormat pf; + + pf.palette = NULL; + pf.BitsPerPixel = 8; + pf.BytesPerPixel = 1; + int32_t i, j, maxx=0, maxy=0; if (modeschecked || novideo) return; @@ -834,9 +835,9 @@ void getvalidmodes(void) pf.BytesPerPixel = cdepths[j] >> 3; modes = SDL_ListModes(&pf, SURFACE_FLAGS -#if (SDL_MAJOR_VERSION == 1 && SDL_MINOR_VERSION < 3) +// #if (SDL_MAJOR_VERSION == 1 && SDL_MINOR_VERSION < 3) | SDL_FULLSCREEN // not implemented/working in SDL 1.3 SDL_compat.c -#endif +//#endif ); if (modes == (SDL_Rect **)0)