www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/09/02/04:19:32

Date: Wed, 2 Sep 1998 11:19:25 +0300 (IDT)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
To: Leif <LeifDude AT hotmail DOT com>
cc: djgpp AT delorie DOT com
Subject: Re: Mouse/Int 33h Problems
In-Reply-To: <35ECD969.219F@hotmail.com>
Message-ID: <Pine.SUN.3.91.980902111456.517c-100000@is>
MIME-Version: 1.0

On Tue, 1 Sep 1998, Leif wrote:

> I dont know whats goin on with my progy. Im writing a program and using
> int86() to call mouse functions of INT 33h. Everything was working fine
> and dandy(with a couple of exceptions I will describe later) untill I
> added a new loop/function in my program. Every time I called this loop
> it caused Int33h Function 03h (Get MousePosition) to report falsely.

The library reference for the function int86 explains some subtleties
about the size of the union REGS members: they are not always 16-bit wide! 
I suggest to read the docs carefully and try to define one of the symbols 
mentioned there, probably _NAIVE_DOS_REGS.  By default, .ax is 32-bit, 
and the upper 16 bits may contain garbage which screws up your code.

Because of these subtleties, I would generally recommend to stay away of 
int86 and use __dpmi_int instead.

- Raw text -


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