www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1996/04/07/16:25:23

Xref: news2.mv.net comp.os.msdos.djgpp:2523
From: gaghon AT nevada DOT edu (GEORGE GAGHON)
Newsgroups: comp.os.msdos.djgpp
Subject: Re: Graphics Mode Switching
Date: 6 Apr 1996 04:42:27 GMT
Organization: University of Nevada System Computing Services
Lines: 25
Message-ID: <4k4snj$57a@news.nevada.edu>
References: <Pine DOT SUN DOT 3 DOT 90 DOT 960404053259 DOT 16526A-100000 AT sparc20-1 DOT unixlab DOT Virginia DOT EDU>
NNTP-Posting-Host: unauthenticated_user AT pioneer DOT nevada DOT edu
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

Keith Alan Kile (kak7c AT sparc20-1 DOT unixlab DOT virginia DOT edu) wrote:
: 
: 	What is the recommended way to change video modes using djgpp 
: v2.x?  I have tried using the BIOS video interupt 0x10 through the 
: library function _go32_dpmi_simulate_int (...) and the compiled program 
: would hang or cause a general protection exception in a DOS-box under 
: Win95.  Is this the only method currently available under djgpp to switch 
: video modes, or can I opt to using direct port access?  Exactly how is 
: direct port access handle under the djgpp run-time environment anyhow?
: 

here's some quick code.  Please don't shoot me if I have a couple of 
errors, as I have no code in front of me.  :)

#include <dpmi.h>

__dpmi.regs reg;
reg.x.ax = 0x0013;      /* ah = 0 al = 0x13 or vga 320x200x256colors
__dpmi_int(0x10, &reg);


That should do it.....

Vince

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019