03-30-2004, 09:52 PM
Yeah, int 33h is lazy . I found out some years ago when I first used a mouse handler in QB. I realized that the coordinates were multiplied by two in screen modes with 320 pixels wide, and by 8 in text mode.
Sterling wrote this:
Meaning that if you read the X position of your mouse you have to divide it by two to get the real screen position in a 320 pixels wide mode, and if you want to write a new value to the mouse's X position you have to multiply the real screen position in a 320 pixels wide mode by two. There was just a bit of misunderstanding
As in the SVGA resolutions, libraries usually do two things:
1.- They are lazy and use the mickeys to move the mouse (a mickey is some kind of measure that tells "how much" the mouse has moved in the horizontal and vertical axis.
2.- They are cool and use the mickeys to create a pseudo-virtual mouse resolution that ranges in the screen mode size.
Sterling wrote this:
Quote:When taking X coords from the driver in mode 13 you have to divide by 2, when giving X coords to the driver you have to multiply by 2
Meaning that if you read the X position of your mouse you have to divide it by two to get the real screen position in a 320 pixels wide mode, and if you want to write a new value to the mouse's X position you have to multiply the real screen position in a 320 pixels wide mode by two. There was just a bit of misunderstanding
As in the SVGA resolutions, libraries usually do two things:
1.- They are lazy and use the mickeys to move the mouse (a mickey is some kind of measure that tells "how much" the mouse has moved in the horizontal and vertical axis.
2.- They are cool and use the mickeys to create a pseudo-virtual mouse resolution that ranges in the screen mode size.
SCUMM (the band) on Myspace!
ComputerEmuzone Games Studio
underBASIC, homegrown musicians
[img]http://www.ojodepez-fanzine.net/almacen/yoghourtslover.png[/i
ComputerEmuzone Games Studio
underBASIC, homegrown musicians
[img]http://www.ojodepez-fanzine.net/almacen/yoghourtslover.png[/i