www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/04/23/23:00:17

Newsgroups: comp.os.msdos.djgpp
Date: Wed, 23 Apr 1997 19:43:09 -0700 (PDT)
From: rellwood <rellwood AT scf DOT usc DOT edu>
To: Laszlo Vecsey <master AT internexus DOT net>
cc: djgpp AT delorie DOT com
Subject: Re: Mouse past edge of screen question
In-Reply-To: <Pine.LNX.3.96.970423192036.15622A-100000@micro.internexus.net>
Message-ID: <Pine.SV4.3.94.970423192955.24618A-100000@aludra.usc.edu>
References: <Pine DOT SV4 DOT 3 DOT 94 DOT 970423100448 DOT 26246A-100000 AT aludra DOT usc DOT edu> <Pine DOT LNX DOT 3 DOT 96 DOT 970423192036 DOT 15622A-100000 AT micro DOT internexus DOT net>
MIME-Version: 1.0

On Wed, 23 Apr 1997, Laszlo Vecsey wrote:
> > For a particular problem that I am trying to solve, I want to set the
> > boundry of the area that the mouse can scroll larger then the area of the
> > screen.  I'm using Allegro's mouse functions, but the one function that I
> > would think should do it, set_mouse_range(int, int, int, int), only seems
> > to be capable of setting the mouse range *smaller* then the screen, not
> > bigger.
> 
> One way to do it would be to use mouse ticks instead, and compute your own
> logical offset that way. "mouse mickey's" I believe they're called. Why
> exactly do you need to do this? Perhaps with some more details someone can
> suggest a better solution. 

Well, here's my problem: I want the user to be able to scroll the screen
by "pushing" against the edge of the screen with the pointer.  Thus, I
want to be able to determine how far the mouse has gone past the edge of
the screen: I scroll the screen the same number of pixles as the mouse has
moved past the edge, move the pointer back to the edge of the screen,
and repeat for each frame.

This way, I hope to attain a more fluid feel of scrolling around a large
area, then that annoying system whereby the screen scrolls at the rate
*it* want's to scroll when your pointer simply sits at the permiter of the
screen, such as in Warcraft, SimCity, etc.

Sorry I was so vague the first time.  The "mouse mickey's" you mentioned
sounds like a good possibility.  How do I get at these mouse ticks?  Or,
any better ideas?

Thanks a lot,
Richard Ellwood

- Raw text -


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