]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commitdiff
sdl2: fix compile.
authordivverent <divverent@d7cf8633-e32d-0410-b094-e92efae38249>
Fri, 10 Jan 2014 18:38:11 +0000 (18:38 +0000)
committerRudolf Polzer <divverent@xonotic.org>
Fri, 10 Jan 2014 18:57:50 +0000 (19:57 +0100)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@12048 d7cf8633-e32d-0410-b094-e92efae38249
::stable-branch::merge=8b71b1316efa1753420f848c919215e6b46479bb

vid_sdl.c

index 324800d5368f0dc0eefd7105f66af4f1b30fa2d1..11fec7351456f3ab8f4f011a9cec8ce83772d909 100644 (file)
--- a/vid_sdl.c
+++ b/vid_sdl.c
@@ -2879,12 +2879,12 @@ vid_mode_t *VID_GetDesktopMode(void)
        Uint32 rmask, gmask, bmask, amask;
        SDL_GetDesktopDisplayMode(0, &mode);
        SDL_PixelFormatEnumToMasks(mode.format, &bpp, &rmask, &gmask, &bmask, &amask);
-       modes[k].width = mode.w;
-       modes[k].height = mode.h;
-       modes[k].bpp = bpp;
-       modes[k].refreshrate = mode.refreshrate;
-       modes[k].pixelheight_num = 1;
-       modes[k].pixelheight_denom = 1; // SDL does not provide this
+       desktop_mode.width = mode.w;
+       desktop_mode.height = mode.h;
+       desktop_mode.bpp = bpp;
+       desktop_mode.refreshrate = mode.refresh_rate;
+       desktop_mode.pixelheight_num = 1;
+       desktop_mode.pixelheight_denom = 1; // SDL does not provide this
        // TODO check whether this actually works, or whether we do still need
        // a read-window-size-after-entering-desktop-fullscreen hack for
        // multiscreen setups.