Subject: Re: kern/25977: Implement WSMOUSEIO_SSCALE as software scaling
To: Johan Danielsson <joda@pdc.kth.se>
From: Paul Ripke <stix@stix.homeunix.net>
List: tech-kern
Date: 06/21/2004 18:45:31
On Monday, Jun 21, 2004, at 18:31 Australia/Sydney, Johan Danielsson 
wrote:

> Paul Ripke <stix@stix-amd.stix.org.au> writes:
>
>> I have a USB mouse with an annoying feature - the smallest delta the 
>> mouse
>> returns is 4 in either the x or y axis.  No matter what settings are 
>> used
>> in X, jumpy behaviour results.  Seeing WSMOUSEIO_SSCALE in the kernel
>> source, I implemented it as generic software scaling in the wscons 
>> layer.
>> I've run the following patch on i386 for some time with no problems.
>
> Isn't it good enough to set the denominator to a fixed number?

I suppose what triggered my use of the num/den style setting was the
previously existing comment. I don't mind either way, but I'd imagine
that fractional scaling may be of benefit in some strange
configurations (none come to mind).

> I would
> also add per axis scaling, and allow for zero scaling. This way you
> can do "mouse invert" as well as fake your own one axis mouse.

I don't see any reason why this can't be done, probably for all
currently supported axis - x,y,z. Zero scaling - well, I can't think
of a use, but that definitely doesn't mean it shouldn't exist. I did
test negative scaling (inversion) which would succeed in giving me
a headache pretty quickly.

It should probably also support reading, rather than the current
FLG_WRONLY.

--
stix.