From b5e526686d014839ef200ba2d60833bfa608ce92 Mon Sep 17 00:00:00 2001 From: Ozkan Sezer Date: Fri, 23 Apr 2010 06:55:20 +0000 Subject: [PATCH] gl_vidsdl.c (VID_Restart): make sure that scr_conscale.value is positive in conwidth and conheight recalculation (fitzquake-0.85 change). git-svn-id: svn://svn.code.sf.net/p/quakespasm/code/trunk/quakespasm@122 af15c1b1-3010-417e-b628-4374ebc0bcbd --- Quake/gl_vidsdl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Quake/gl_vidsdl.c b/Quake/gl_vidsdl.c index ba7b2734..be1cefb8 100644 --- a/Quake/gl_vidsdl.c +++ b/Quake/gl_vidsdl.c @@ -435,7 +435,7 @@ void VID_Restart (void) TexMgr_RecalcWarpImageSize (); //conwidth and conheight need to be recalculated - vid.conwidth = (scr_conwidth.value > 0) ? (int)scr_conwidth.value : vid.width; + vid.conwidth = (scr_conwidth.value > 0) ? (int)scr_conwidth.value : (scr_conscale.value > 0) ? (int)(vid.width/scr_conscale.value) : vid.width; vid.conwidth = CLAMP (320, vid.conwidth, vid.width); vid.conwidth &= 0xFFFFFFF8; vid.conheight = vid.conwidth * vid.height / vid.width;