A free API for the Steam Controller?

A free API for the Steam Controller?

Postby afeder » 26 Jan 2014, 00:14

As many of you know, Valve Corporation - the creators of the Half-Life franchise and the Steam digital distribution platform - has recently launched a strategy to bring PC gaming to the living room, through console-like devices called "Steam Machines". The Steam Machines, which will be manufactured by a variety of vendors, will run a Debian-based operating system called "SteamOS". More interestingly, perhaps, for game developers, is the fact that the devices will come with a new kind of touch-based controller, designed by Valve, for mouse-like input.

Only some 2000 copies of this "Steam Controller" has been released to beta testers so far, but from what I gather, the device will connect to the host machine as a regular USB HID device - no new kernel-level driver required. By default, the controller will map its right touchpad to mouse movement input and its left touchpad to the WASD set of keys commonly used for player character movement. However - and this is the salient point - games designed specifically against Valve's Steamworks API will be able to take full advantage of the controller in that they may completely rebind the trackpads and buttons of the controller, and inspect its state directly, via the API. But, since the library is proprietary, this API is effectively "forbidden fruit" for free-as-in-freedom games. Linking Valve's binary Steamworks blob with GPL code, for instance, might require anyone distributing the resulting binary to also release the source code for the Steamworks blob under the GPL - something they cannot do since that code is closed-source and owned by Valve. (An open-source attempt to reverse the Steamworks library, called Open Steamworks, do exist, but in my opinion this amounts to little more than a hack: it will be an endless game of catch-up to stay up to date with the changes that keep being made to the official library.)

This leaves free games in a very disadvantageous situation, compared to proprietary games, on SteamOS. Which is ironic, since part of Valve's motivation for launching their SteamOS strategy in the first place has been to offer gamers and developers a platform that is "as open as possible", compared to its Microsoft and Sony counterparts. It also does not sit well with the fact that the vast majority of the SteamOS platform is composed of components developed by upstream projects like the Linux kernel project and Debian - common courtesy would suggest that Valve should strive to give back on terms reciprocal to those it is itself benefiting from.

I am not really calling for a pitchfork-style uprising, however. So far, Valve's approach to this whole project has been decent: back in December, Valve joined the Linux Foundation as a Silver-level member, and just a few days ago they've offered all official Debian developers free access to all past and future Valve-produced games. Thus, what I think would be more constructive, would be to write up some kind of statement, laying out what our issue with Valve's licensing is, and requesting that it be resolved in some manner. The easiest solution would be for them to simple release the source code for the library under a free (and GPL-compatible) license, but there could be issues such as the presence of proprietary code from third-parties in the codebase to take into account, in which case alternatives would need to be agreed upon.

So, what do you think? I'm particularly interested in hearing from the active FOSS game developers in this forum: might you be willing to discuss and potentially undersign such a statement to be sent to Valve?

Thanks.
afeder
 
Posts: 8
Joined: 23 Jan 2014, 19:25

Re: A free API for the Steam Controller?

Postby Julius » 26 Jan 2014, 13:19

Hmm, do you have a definit statement from Valve somewhere that the controller is tied to the Steamworks API?

From what I have gathered it will be perfectly usable in non steam games and have support through the open-source SDL2 library to which Valve contributes greatly.

I haven't followed this in great detail though, but AFAIK the steamworks integration was just to allow older games to best utilize the controller like a mouse & keyboard replacement without the original creators of said games having to modify their game.
User avatar
Julius
Community Moderator
 
Posts: 3297
Joined: 06 Dec 2009, 14:02

Re: A free API for the Steam Controller?

Postby afeder » 26 Jan 2014, 14:12

Julius {l Wrote}:Hmm, do you have a definit statement from Valve somewhere that the controller is tied to the Steamworks API?

From what I have gathered it will be perfectly usable in non steam games and have support through the open-source SDL2 library to which Valve contributes greatly.

I haven't followed this in great detail though, but AFAIK the steamworks integration was just to allow older games to best utilize the controller like a mouse & keyboard replacement without the original creators of said games having to modify their game.

In the "Steam Controller API" section of the Steamworks documentation site (free login required) it is written that: "The Stream Controller APIs require Steamworks SDK version 1.27 or above." It then lists a few functions in Steamworks for things like getting controller state and sending haptic pulses.

SDL2 has a new generic controller API, but I was under the impression that it would not support all the unique features of the Steam Controller. Any links to sources showing the contrary would be appreciated.
afeder
 
Posts: 8
Joined: 23 Jan 2014, 19:25

Re: A free API for the Steam Controller?

Postby Julius » 26 Jan 2014, 14:31

Hmm, I think it is a bit too early to tell, and given that they seem to have axed the build in touch-screen, standard SDL2 support for all features shouldn't be all that hard to implement.
User avatar
Julius
Community Moderator
 
Posts: 3297
Joined: 06 Dec 2009, 14:02

Re: A free API for the Steam Controller?

Postby afeder » 26 Jan 2014, 14:36

Julius {l Wrote}:Hmm, I think it is a bit too early to tell, and given that they seem to have axed the build in touch-screen, standard SDL2 support for all features shouldn't be all that hard to implement.

It's true, it is a bit too early to tell. But just quickly browsing through the SDL2 documentation, for instance, I can't find a way to send a haptic effect to a specific pad on a specific controller. This can be done through Steamworks with a call of the type:
{l Code}: {l Select All Code}
ISteamController::TriggerHapticPulse( uint32 unControllerIndex, ESteamControllerPad eTargetPad, unsigned short usDurationMicroSec )
afeder
 
Posts: 8
Joined: 23 Jan 2014, 19:25

Re: A free API for the Steam Controller?

Postby mdwh » 26 Jan 2014, 18:35

How is this different to Open Source games on other proprietary platforms, e.g., linking to MSVC libraries or requiring DirectX? It is fine to link to proprietary libraries if they are covered by the "system library exception" ( http://www.gnu.org/licenses/gpl-faq.htm ... yException ). Is the Steamworks library not covered by the system library exception?
mdwh
 
Posts: 67
Joined: 13 Aug 2011, 01:53

Re: A free API for the Steam Controller?

Postby afeder » 27 Jan 2014, 10:21

mdwh {l Wrote}:How is this different to Open Source games on other proprietary platforms, e.g., linking to MSVC libraries or requiring DirectX? It is fine to link to proprietary libraries if they are covered by the "system library exception" ( http://www.gnu.org/licenses/gpl-faq.htm ... yException ). Is the Steamworks library not covered by the system library exception?

It is different in the fact that Steamworks is not - at least not necessarily - part of the operating system. In GPL2, the system library exception is formulated as:
However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable.

In GPL3, it is:
The “System Libraries” of an executable work include anything, other than the work as a whole, that (a) is included in the normal form of packaging a Major Component, but which is not part of that Major Component, and (b) serves only to enable use of the work with that Major Component, or to implement a Standard Interface for which an implementation is available to the public in source code form. A “Major Component”, in this context, means a major essential component (kernel, window system, and so on) of the specific operating system (if any) on which the executable work runs, or a compiler used to produce the work, or an object code interpreter used to run it.

Steamworks is part of the Steam client, and the Steam client is a stand-alone software package, designed to run on multiple different platforms - not just on SteamOS. So calling it a "major component of the operating system" seems something of a stretch. Also, you may use the Steam Controller with other operating systems - e.g. Ubuntu - just as a regular gamepad. Even if you are able to somehow convince a court that Steamworks is a system library on SteamOS, GPL games would still be left unable to take advantage of the Steam Controller on those other, non-SteamOS platforms, while proprietary games would not face such a limitation.
afeder
 
Posts: 8
Joined: 23 Jan 2014, 19:25

Re: A free API for the Steam Controller?

Postby Julius » 01 Feb 2014, 15:42

User avatar
Julius
Community Moderator
 
Posts: 3297
Joined: 06 Dec 2009, 14:02

Re: A free API for the Steam Controller?

Postby afeder » 01 Feb 2014, 17:03


I wonder how Phoronix came to the conclusion that the Steam Controller will use this driver... Could just be support for legacy XBox 360 controllers that Valve was aiming for here, as far as I am able to tell.
afeder
 
Posts: 8
Joined: 23 Jan 2014, 19:25

Re: A free API for the Steam Controller?

Postby afeder » 12 Feb 2014, 00:13

Thorough introduction to the Steam Controller in this video: https://www.youtube.com/watch?v=UfN5WK7 ... be&t=29m1s (the "legacy mode" they refer to is basically backwards compatibility for games not implementing Steam Controller support natively.)

At around the 29 minutes mark, they describe the API, and as you can see, it is solely framed in terms of their proprietary Steamworks library. If there is any SDL support at all, it is something secondary - a "stepchild" as it were.
afeder
 
Posts: 8
Joined: 23 Jan 2014, 19:25

Who is online

Users browsing this forum: No registered users and 1 guest