https://github.com/mathdroid/simple-raycaster
👆 Simple raycaster (cursor) for ReactVR
https://github.com/mathdroid/simple-raycaster
Last synced: 9 months ago
JSON representation
👆 Simple raycaster (cursor) for ReactVR
- Host: GitHub
- URL: https://github.com/mathdroid/simple-raycaster
- Owner: mathdroid
- License: mit
- Created: 2017-04-22T04:33:53.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2018-05-11T10:58:09.000Z (almost 8 years ago)
- Last Synced: 2025-04-20T06:34:53.629Z (10 months ago)
- Language: JavaScript
- Size: 25.4 KB
- Stars: 9
- Watchers: 2
- Forks: 1
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# simple-raycaster
> 👆 Simple raycaster (cursor) for ReactVR
# Usage
In your `ReactVR`'s `client.js`:
```js
import { VRInstance } from "react-vr-web";
import * as SimpleRaycaster from "simple-raycaster";
function init(bundle, parent, options) {
const vr = new VRInstance(bundle, "librarytests", parent, {
raycasters: [
SimpleRaycaster // Add SimpleRaycaster to the options
],
cursorVisibility: "auto", // Add cursorVisibility
...options
});
vr.start();
return vr;
}
window.ReactVR = { init };
```
# License
MIT. See [License](./LICENSE)