Skip to content

mitchallen/three-xr-controller

Repository files navigation

@mitchallen/three-xr-controller

ThreeJS XR Controller Library


Downloads Version License jsdelivr

Usage

Get from npm via jsdelivr

import {
  XRCONTROLLER,
} from 'https://cdn.jsdelivr.net/npm/@mitchallen/[email protected]/dist/three-xr-controller.modern.js'

Example code

See the repo examples folder.

Video Demo

A video of the example code, recorded on an Oculus Quest 2 can be found here:

Live VR demos

To see live VR demos using this package, browse to:

If you browse to this site in your VR headset you can click the Enter VR button.

This package has been tested on:

  • Oculus Go - the current demo only works on the Quest
  • Oculus Quest 2

WebXR Chrome Extension Issues

Please note that at the time of this writing there are issue with the button mapping of the WebXR Chrome Extension.

The button mappings in this package were confirmed on actual devices.


Publishing

To publish your version of the package you must first setup an account and project in NPM.

This will boost the version number, push and publish:

git add .
git commit -m "updated code"
npm run pub:patch

As an alternative:

git add .
git commit -m "updated code"
npm version patch -m "Upgrade to %s for reasons"

References

About

ThreeJS XR Controller Library

Resources

Stars

Watchers

Forks

Packages

No packages published