]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commitdiff
don't allow stencil without bitsperpixel 32
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 7 Nov 2002 20:38:57 +0000 (20:38 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Thu, 7 Nov 2002 20:38:57 +0000 (20:38 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@2605 d7cf8633-e32d-0410-b094-e92efae38249

vid_shared.c

index 2743742d0bd61a0ccc3c3ef5164d850b856ce8ed..6cf000ac49d9a2a4e8ee94074da8e117579f2e07 100644 (file)
@@ -541,6 +541,12 @@ void VID_Open(void)
                        Cvar_SetValueQuick(&vid_stencil, 1);
        }
 
+       if (vid_stencil.integer && vid_bitsperpixel.integer != 32)
+       {
+               Con_Printf("vid_stencil not allowed without vid_bitsperpixel 32, turning off vid_stencil\n");
+               Cvar_SetValueQuick(&vid_stencil, 0);
+       }
+
        Con_Printf("Starting video system\n");
        if (!VID_Mode(vid_fullscreen.integer, vid_width.integer, vid_height.integer, vid_bitsperpixel.integer, vid_stencil.integer))
        {