[Development] Introducing Qt Gamepad, a new qt-labs project

Christian Gagneraud chgans at gna.org
Wed May 13 01:04:31 CEST 2015

On Tue, 12 May 2015 16:16:00 Nichols Andy wrote:
> You may have noticed if you religiously watch #qt-labs or just poke around
> on code.qt.io page that a new project has recently been added to qt-labs. 
> QtGamepad is a spare-time / creative Friday project that I've been playing
> with on-and-off since 2012.  Some of you may have seen the first version
> available on my Github account, but the new version available now on
> qt-labs has been mostly rewritten.
> http://code.qt.io/cgit/qt-labs/qtgamepad.git/
> The now available version is loosely inspired by the HTML 5 Gamepad API:
> http://www.w3.org/TR/2015/WD-gamepad-20150414/
> but now with a much more Qt-like API.  There are both C++ and QtQuick APIs
> available for interacting with Gamepad devices, as well as some convience
> APIs for mapping gamepad buttons to keyboard buttons (to for example drive
> and existing interface with 5-key navigation).
> Right now there is a plugin architecture for providing different backends
> for interacting with gamepads.  The current backends include: XInput -
> Windows
> evdev - Linux
> SDL2 - Any platform supported by SDL2 (we just use their Gamepad module)
> I'm also currently working on the native OSX/iOS backend (now that I
> actually have an iOS Gamepad to test)
> The Qt Gamepad module should already be useful for many of you who would
> like to play with Gamepad interactions in your Qt Applications, but there
> also is some additional work that needs to be done to improve this module
> so feedback and contributions are appreciated as usual ;-)

Hi Andy,

Any chance QtGamepad would provide support for devices like the SpaceNavigator 
(3D mouse) [1]? I recently posted a question about this on this mailing list 
 These 3D mice send events for translation and rotation around all 3 Axis,  I 
don't know how well they fit with gamepads. Accdording to [3] it seems to fit in 
terms of events, the only exception is that the space navigator requires it's 
own protocol handler [4]


[1] http://www.3dconnexion.eu/products/spacemouse/spacenavigator.html
[2] http://lists.qt-project.org/pipermail/interest/2015-April/016294.html
[3] http://code.qt.io/cgit/qt-labs/qtgamepad.git/tree/src/plugins/gamepads/evdev/qevdevgamepadbackend.cpp
[4] http://sourceforge.net/p/spacenav/code/HEAD/tree/trunk/libspnav/

> Regards and happy hacking,
> Andy Nichols
> @nezticle
> _______________________________________________
> Development mailing list
> Development at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/development

More information about the Development mailing list