From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LjLvM-0000oo-6F for qemu-devel@nongnu.org; Mon, 16 Mar 2009 19:08:48 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LjLvK-0000oc-6M for qemu-devel@nongnu.org; Mon, 16 Mar 2009 19:08:46 -0400 Received: from [199.232.76.173] (port=47770 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LjLvJ-0000oZ-WE for qemu-devel@nongnu.org; Mon, 16 Mar 2009 19:08:46 -0400 Received: from fe01x03-cgp.akado.ru ([77.232.31.164]:52981 helo=akado.ru) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LjLvJ-000797-Hf for qemu-devel@nongnu.org; Mon, 16 Mar 2009 19:08:45 -0400 Received: from [10.0.66.9] ([10.0.66.9] verified) by fe01-cgp.akado.ru (CommuniGate Pro SMTP 5.1.16) with ESMTP id 64030793 for qemu-devel@nongnu.org; Tue, 17 Mar 2009 02:08:14 +0300 Date: Tue, 17 Mar 2009 02:08:13 +0300 (MSK) From: malc Subject: Re: [Qemu-devel] r6349 broke Commander Keen 4 ;-( In-Reply-To: <49BECB48.2040107@bttr-software.de> Message-ID: References: <49BECB48.2040107@bttr-software.de> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Reply-To: qemu-devel@nongnu.org List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org On Mon, 16 Mar 2009, Robert Riebisch wrote: > Hi! > > When running Commander Keen 4 () > in DOS only the left half of the VGA screen is shown on the SDL interface. > > By doing lots of builds I narrowed the problem down to > by > Stefano Stabellini. 6349 is indeed what broke stuff, the code was moved (why?) and uses disp_width that could be modified later.. diff --git a/hw/vga.c b/hw/vga.c index e3d2446..eeb77f1 100644 --- a/hw/vga.c +++ b/hw/vga.c @@ -1619,6 +1619,16 @@ static void vga_draw_graphic(VGAState *s, int full_update) s->double_scan = double_scan; } + if (shift_control == 0) { + if (s->sr[0x01] & 8) { + disp_width <<= 1; + } + } else if (shift_control == 1) { + if (s->sr[0x01] & 8) { + disp_width <<= 1; + } + } + depth = s->get_bpp(s); if (s->line_offset != s->last_line_offset || disp_width != s->last_width || @@ -1660,7 +1670,6 @@ static void vga_draw_graphic(VGAState *s, int full_update) full_update |= update_palette16(s); if (s->sr[0x01] & 8) { v = VGA_DRAW_LINE4D2; - disp_width <<= 1; } else { v = VGA_DRAW_LINE4; } @@ -1669,7 +1678,6 @@ static void vga_draw_graphic(VGAState *s, int full_update) full_update |= update_palette16(s); if (s->sr[0x01] & 8) { v = VGA_DRAW_LINE2D2; - disp_width <<= 1; } else { v = VGA_DRAW_LINE2; } -- mailto:av1474@comtv.ru