forked from EXT/VR180-Web-Player
Typescript conversion
This commit is contained in:
12
README.md
12
README.md
@@ -7,7 +7,7 @@ The player supports two projection modes:
|
||||
- `plane`: a flat stereoscopic video plane in WebXR, with a normal flat left-eye fallback on non-XR browsers.
|
||||
|
||||
## How to use it
|
||||
Include the module script from your CDN. The script automatically loads its matching CSS file and image assets from the same folder.
|
||||
Host the whole `vr180player/` directory on your CDN, then include the module script. The script automatically loads its matching CSS file and image assets from the same folder, and it imports its helper modules with relative module paths.
|
||||
|
||||
```html
|
||||
<div data-vr-web-player data-projection="vr180">
|
||||
@@ -43,3 +43,13 @@ When the page loads, the video is embedded normally with a play button over the
|
||||
|
||||
## Demo
|
||||
Open this repository's `index.html` through a local web server and switch `data-projection` between `vr180` and `plane` to test both modes.
|
||||
|
||||
## Development
|
||||
The player source is TypeScript in `src/vr180player/`. Build the CDN-ready JavaScript files into `vr180player/` with:
|
||||
|
||||
```sh
|
||||
npm install
|
||||
npm run build
|
||||
```
|
||||
|
||||
Edit the TypeScript source files rather than the generated JavaScript files in `vr180player/`.
|
||||
|
||||
Reference in New Issue
Block a user