Mouse Coordinates
Hi,
Im using Managed DirectX and the SDK Sampleframework.
In the sampleframework, I can only capture the MouseX and MouseY as an integer (in the dxmutgui.cs).
Is there any way of getting the mouse coordinates as a float?
Im moving some graphics around with the mouse and it looks a little jaggy and not as smooth as I hoped for.
Thanks in advance.
I'd be very supprised if the mouse actually treated coordinates in decimal...
However, you could write a bit of code that uses acceleration, and so makes small movements of the mouse (for example, maybe just a few pixels in a second) only move a tiny (1 - 2 pixels?) amount, and larger movements much quicker. It's more detailed than that - but it's what your mouse, in Windows at least, already does. This won't affect your program, though, which probably doesn't use the same acceleration.
However, you could write a bit of code that uses acceleration, and so makes small movements of the mouse (for example, maybe just a few pixels in a second) only move a tiny (1 - 2 pixels?) amount, and larger movements much quicker. It's more detailed than that - but it's what your mouse, in Windows at least, already does. This won't affect your program, though, which probably doesn't use the same acceleration.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement