Back in June we’ve presented a prototype of a new RESTful interface to exchange graphics based data values across networks at Web3D 2013. This interface can be used to query data from a running application, modify or use it to display something. Said prototype is implemented inside InstantIO, the hardware component of Instant Reality which supports more than 40 devices. For the first time now, you’re able to query hardware information from InstantIO through Javascript from a browser. We’ve set up a tutorial on how to connect a Oculus Rift HMD to an X3DOM application: X3DOM renders a scene as distorted stereo image but connects via REST API to a local InstantIO server, opens a WebSocket connection on the orientation field of the Oculus and uses the incoming data to rotate the view!
You can do this of course with arbitrary hardware (think of the LEAP support or the Kinect), but please bear in mind that this is only a preview at the moment.
You can find the tutorial here. Enjoy!