W3C home > Mailing lists > Public > public-pointer-events@w3.org > April to June 2014

Exposing high-frequency mouse/touch movement?

From: Rick Byers <rbyers@google.com>
Date: Fri, 30 May 2014 12:48:00 -0400
Message-ID: <CAFUtAY80WOiNKgtV4qEQjz1JJBLpEpLSxOhVEW+dcdmhA9fmWw@mail.gmail.com>
To: "public-pointer-events@w3.org" <public-pointer-events@w3.org>
Platforms typically coalesce movement events, eg. possibly limiting them to
reporting at most 1 per video frame.  Some applications want additional
data, for example high-precision drawing and some games.  Windows 8 has a
GetPointerTouchInfoHistory
<http://msdn.microsoft.com/en-us/library/windows/desktop/hh454891(v=vs.85).aspx>
API
[1] for this (why is this just touch and not all pointers?), and Android
has methods on MotionEvent
<http://developer.android.com/reference/android/view/MotionEvent.html> [2]
for getting historical data out of the event batch.

Should we be exposing something similar to the web?

Other platforms take the approach of having an API to disable
coalescing/batching - eg. setMouseCoalescingEnabled
<https://developer.apple.com/library/mac/documentation/Cocoa/Reference/ApplicationKit/Classes/NSEvent_Class/Reference/Reference.html#//apple_ref/occ/clm/NSEvent/setMouseCoalescingEnabled:>
[3]
on Mac OS X.  One big disadvantage I see to this approach is that it treats
all event consumers the same.  For a particular event, there may be one
consumer that wants high-resolution data (and can process it efficiently)
while other consumers may get backlogged by an unusually high event
reporting rate.

Thanks,
  Rick

[1]
http://msdn.microsoft.com/en-us/library/windows/desktop/hh454891(v=vs.85).aspx

[2] http://developer.android.com/reference/android/view/MotionEvent.html
[3]
https://developer.apple.com/library/mac/documentation/Cocoa/Reference/ApplicationKit/Classes/NSEvent_Class/Reference/Reference.html#//apple_ref/occ/clm/NSEvent/setMouseCoalescingEnabled
:
Received on Friday, 30 May 2014 16:48:47 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 20:20:26 UTC