[Bug 8320] DirectInput joystick timestamps are wrong

Wine Bugs wine-bugs at winehq.org
Wed May 9 01:45:00 CDT 2007


http://bugs.winehq.org/show_bug.cgi?id=8320





------- Additional Comments From hoof at users.sourceforge.net  2007-09-05 01:45 -------
I understand perfectly well what the system time is.  I know that it doesn't
start from a fixed date and that it wraps every 49.71 days.  What you don't seem
to understand is that your joystick times are in a different time frame than
Wine's system time.  You can call GetTickCount() and get 20000, then read a
joystick event that says it happened at 80000000, then call GetTickCount() again
and get 21000.  That is clearly wrong.  The timestamp is supposed to be the
"System time at which the input event was generated, in milliseconds", not the
system time plus some random offset.

If you don't believe that is how it's supposed to work, look at Quake 3's source
code.  You will see DirectInput timestamps used exactly as I described. 
(Luckily they only use DirectInput to read the mouse, not the joystick, so they
don't hit the bug.)

Anyway, I am done wasting time on this.  Do what you will.


-- 
Configure bugmail: http://bugs.winehq.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug, or are watching the assignee.



More information about the wine-bugs mailing list