📃 master: update documentation
This commit is contained in:
parent
199e1fc530
commit
4053afc81d
1 changed files with 112 additions and 26 deletions
134
README.md
134
README.md
|
|
@ -1,34 +1,87 @@
|
||||||
NOTES:
|
XRForge is a tiny, powerful tool to interconnect XR experiences.<br>
|
||||||
|
|
||||||
|
## Adding content
|
||||||
|
|
||||||
|
First you need a directory with glTF or JanusXR experiences.<br>
|
||||||
|
Just run this in the terminal:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
$ unzip xrforge.com myverse
|
||||||
|
$ tree myverse
|
||||||
|
myverse
|
||||||
|
├── janusxr
|
||||||
|
│ ├── helloworld
|
||||||
|
│ │ └── janusxr.xml
|
||||||
|
│ ├── janusxr.png
|
||||||
|
│ └── tronverse -> ../tronverse <---
|
||||||
|
└── tronverse | recursive portals allowed
|
||||||
|
├── janusxr -> ../janusxr <--- via symlinks
|
||||||
|
├── tron
|
||||||
|
│ ├── README.md
|
||||||
|
│ ├── tron.glb
|
||||||
|
│ ├── tron.mp3
|
||||||
|
│ └── tron.png
|
||||||
|
└── tronverse.png
|
||||||
```
|
```
|
||||||
|
|
||||||
/admin.lua <--- define other instances..for CORS allow / mount http
|
> optionally you can run `./xrforge.com admin` and change the `myverse` directory if needed.
|
||||||
configure in-zip or filesystem-cache
|
|
||||||
|
|
||||||
opendirectory.lua <--- mount other instances over http (via xrforge or rclone)
|
Now xrforge.com will scan that local folder:
|
||||||
|
|
||||||
.xrforge/hook/scandir <-- event to hook
|
|
||||||
|
|
||||||
scan files
|
|
||||||
---------- middleware/xrexperience.lua
|
|
||||||
| events: ---------------------
|
|
||||||
+ file type: sidecarfile
|
|
||||||
+ sidecarfiles ---> regex = {"\.glb", "\.png", "\.vtt"}
|
|
||||||
| regex_minmatch = 2
|
|
||||||
+ folder viewer = /view/janusweb/#janus.url=${file}.glb
|
|
||||||
template = [[
|
|
||||||
<div class="tile"> ... </div>
|
|
||||||
]]
|
|
||||||
|
|
||||||
|
```bash
|
||||||
|
$ ./xrforge.gom
|
||||||
|
scanning experiences (this make take a while..)
|
||||||
|
✅ └─ plugin/diskscan: detected .png thumbnail file
|
||||||
|
✅ ./myverse/janusxr 10927498
|
||||||
|
✅ ./myverse/janusxr/helloworld 10927500
|
||||||
|
✅ └─ plugin/janusxr: janusxr.xml
|
||||||
|
✅ └─ plugin/diskscan: detected .png thumbnail file
|
||||||
|
✅ └─ plugin/diskscan: detected .png thumbnail file
|
||||||
|
✅ ./myverse/tronverse 10927503
|
||||||
|
✅ └─ plugin/diskscan: detected .png thumbnail file
|
||||||
|
✅ ./myverse/tronverse/tron 10927504
|
||||||
|
✅ └─ plugin/xrfragments: detected .png sidecarfile
|
||||||
|
✅ └─ plugin/markdown: detected README.md
|
||||||
|
✅ └─ plugin/diskscan: detected .png thumbnail file
|
||||||
|
ℹ️ ./myverse/janusxr/tronverse
|
||||||
|
✅ └─ plugin/diskscan: detected symlink..creating portal
|
||||||
|
ℹ️ ./myverse/tronverse/janusxr
|
||||||
|
✅ └─ plugin/diskscan: detected symlink..creating portal
|
||||||
```
|
```
|
||||||
|
|
||||||
## Ideas
|
## Customizing
|
||||||
|
|
||||||
* tabs horizontal stacked for xrforge.max.css
|
After first (in the terminal) run a lua config file is created, which you can edit:
|
||||||
* fuzzy search: https://github.com/ssimonp/FuzzySearch-Roblox
|
|
||||||
* landingpage = /about
|
```bash
|
||||||
* scan functions in xrforge.lua / .xrforge
|
$ xrforge.com
|
||||||
* video-hover: https://codepen.io/coderofsalvation/pen/YPNOyqx
|
$ ls
|
||||||
|
xrforge.com
|
||||||
|
xrforge.lua
|
||||||
|
```
|
||||||
|
|
||||||
|
With basic HTML/CSS skills you can edit the templates by running this in the terminal:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
$ unzip xrforge.com page css
|
||||||
|
$ ls
|
||||||
|
page css
|
||||||
|
```
|
||||||
|
|
||||||
|
> Profit! You can now edit the extracted html-templates and css-files, they will be detected automatically when running xrforge.com
|
||||||
|
|
||||||
|
Optionally you can re-distribute `xrforge.com` with your modifications by running `zip xrforge.com page`
|
||||||
|
|
||||||
|
## Plugins
|
||||||
|
|
||||||
|
xrforge is basically plugins working together.<br>
|
||||||
|
You can create your own plugins by running:
|
||||||
|
|
||||||
|
```bash
|
||||||
|
$ ./xrforge.com createplugin > xrforge.myplugin.lua
|
||||||
|
```
|
||||||
|
|
||||||
|
Look in the [src/plugin](src/plugin) directory for examples
|
||||||
|
|
||||||
## Scan manyfold
|
## Scan manyfold
|
||||||
|
|
||||||
|
|
@ -53,7 +106,6 @@ Then run with debug flag to see output of `trace()` calls
|
||||||
$ DEBUG=1 result/bin/xrforge.com
|
$ DEBUG=1 result/bin/xrforge.com
|
||||||
```
|
```
|
||||||
|
|
||||||
|
|
||||||
## Permacomputing Spirit
|
## Permacomputing Spirit
|
||||||
|
|
||||||
* developed on [Dillo](https://dillo-browser.github.io/) as lowest common denominator / compatibility
|
* developed on [Dillo](https://dillo-browser.github.io/) as lowest common denominator / compatibility
|
||||||
|
|
@ -70,3 +122,37 @@ $ DEBUG=1 result/bin/xrforge.com
|
||||||
* [xrfragments](https://xrfragment.org)
|
* [xrfragments](https://xrfragment.org)
|
||||||
* [janusxr](https://github.com/jbaicoianu/janusweb)
|
* [janusxr](https://github.com/jbaicoianu/janusweb)
|
||||||
* [janusweb](https://janusxr.org)
|
* [janusweb](https://janusxr.org)
|
||||||
|
|
||||||
|
## Ideas
|
||||||
|
|
||||||
|
* tabs horizontal stacked for xrforge.max.css
|
||||||
|
* fuzzy search: https://github.com/ssimonp/FuzzySearch-Roblox
|
||||||
|
* landingpage = /about
|
||||||
|
* scan functions in xrforge.lua / .xrforge
|
||||||
|
* video-hover: https://codepen.io/coderofsalvation/pen/YPNOyqx
|
||||||
|
|
||||||
|
NOTES:
|
||||||
|
|
||||||
|
```
|
||||||
|
|
||||||
|
/admin.lua <--- define other instances..for CORS allow / mount http
|
||||||
|
configure in-zip or filesystem-cache
|
||||||
|
|
||||||
|
opendirectory.lua <--- mount other instances over http (via xrforge or rclone)
|
||||||
|
|
||||||
|
.xrforge/hook/scandir <-- event to hook
|
||||||
|
|
||||||
|
scan files
|
||||||
|
---------- middleware/xrexperience.lua
|
||||||
|
| events: ---------------------
|
||||||
|
+ file type: sidecarfile
|
||||||
|
+ sidecarfiles ---> regex = {"\.glb", "\.png", "\.vtt"}
|
||||||
|
| regex_minmatch = 2
|
||||||
|
+ folder viewer = /view/janusweb/#janus.url=${file}.glb
|
||||||
|
template = [[
|
||||||
|
<div class="tile"> ... </div>
|
||||||
|
]]
|
||||||
|
|
||||||
|
```
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue