dataarts / dat.guiVR

A flexible graphical user interface for changing variables within WebVR.
https://workshop.chromeexperiments.com/examples/guiVR/
Apache License 2.0
312 stars 49 forks source link

Enable mouse access #8

Closed mflux closed 8 years ago

mflux commented 8 years ago

API would look something like

gui.enableMouse( camera, renderer );

This should create a new input object internally that uses mouse as raycaster to control GUIVR.

mflux commented 8 years ago

I'm thinking we can have some similar convenience for vive controllers

gui.enableRoomscaleControllers()...

It would bloat the lib a bit (include vrpad with the lib) in exchange which is currently 30kb unminified.

mflux commented 8 years ago

Implemented in 2fcbf7a63c643f7eb915375b6973d089a9fb2b3f

You now just addInputObject( controller ) and if the controller is an instance of THREE.ViveController then DATGUIVR will simply bind the correct buttons.