Wayland Relative Pointer API Progress
x414e54
x414e54 at linux.com
Thu Apr 16 19:51:41 PDT 2015
Hi,
I am wondering if there has been any recent progress on the stability of
the Wayland relative pointer API?
I had a few ideas on the original December implementation:
Whilst we definitely need the relative event support, I feel that the
client should never be allowed to warp or confine the global pointer even
if it is just a hint. There may be cases such as IR or laser pointer
devices (e.g. wii mote) which can never guarantee a warp or pointer
confinement but can still transmit accelerometer data as relative pointer
motion. Looking at most toolkits and applications they cannot be trusted
even with "hints".
I think the API needs to be split into two use cases:
1. GUI sliders etc. - They should be allowed to freeze the pointer and
receive relative events based on an implicit button down grab similar to
the drag and drop protocol. They should not be allowed to warp or confine
and upon button up the grab is lost. Gnome already looks like it uses
heuristics todo this if the cursor is hidden on button down.
1. Games - They do not really need relative "pointer" events they just want
the current seat mapped to a 6DOF or joystick style input. They should be
allowed to request some kind of wl_joystick or wl_6dof interface. Then the
compositor can decide what it actually presents to the application for
using that input. Maybe a user has a joystick they always select to use
instead of their mouse or they have an accelerometer device etc. It is then
up to the compositor what it does with the actual on screen cursor if it
confines it or hides it etc, there could be a notification of entering
"game mode" etc. If the compositor is not using the same input device for
wl_pointer and a wl_joystick or wl_6dof then it does nothing. This would
also allow a user to hot-swap the device between mouse and keyboard and a
gamepad just by using the WM settings. It could also allow for using 6DOF
or 3D mice in an application which is also mapped as the default x, y
pointer.
The application will then still receive absolute pointer events which it
can use for in game GUI clicks.
Any opinions on this would be appreciated.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/wayland-devel/attachments/20150417/bc837207/attachment.html>
More information about the wayland-devel
mailing list