update docs
This commit is contained in:
parent
1bcad8243b
commit
959e8a22e4
|
@ -81,7 +81,7 @@ value: draft-XRFRAGMENTS-leonvankammen-00
|
|||
<h1 class="special" id="abstract">Abstract</h1>
|
||||
|
||||
<p>This draft is a specification for 4D URI’s & <a href="https://github.com/coderofsalvation/hypermediatic">hypermediatic</a> navigation, which links together space, time & text together, for hypermedia browsers with- or without a network-connection.<br>
|
||||
The specification promotes spatial addressibility, sharing, navigation, filtering and databinding objects for (XR) Browsers.<br>
|
||||
The specification uses <a href="https://www.w3.org/TR/media-frags/">W3C Media Fragments</a> and <a href="https://www.rfc-editor.org/rfc/rfc6570">URI Templates (RFC6570)</a> to promote spatial addressibility, sharing, navigation, filtering and databinding objects for (XR) Browsers.<br>
|
||||
XR Fragments allows us to better use existing metadata inside 3D scene(files), by connecting it to proven technologies like <a href="https://en.wikipedia.org/wiki/URI_fragment">URI Fragments</a>.</p>
|
||||
|
||||
<blockquote>
|
||||
|
@ -377,13 +377,14 @@ That way, if the link gets shared, the XR Fragments implementation at <code>http
|
|||
<p>Supported popular compatible 3D fileformats: <code>.gltf</code>, <code>.obj</code>, <code>.fbx</code>, <code>.usdz</code>, <code>.json</code> (THREE.js), <code>.dae</code> and so on.</p>
|
||||
</blockquote>
|
||||
|
||||
<h2 id="dynamic-xr-fragments-databindings">Dynamic XR Fragments (+databindings)</h2>
|
||||
<h2 id="fragment-to-metadata-mapping">Fragment-to-metadata mapping</h2>
|
||||
|
||||
<p>These are automatic fragment-to-metadata mappings, which only trigger if the 3D scene metadata matches a specific identifier (<code>aliasname</code> e.g.)</p>
|
||||
<p>These are automatic fragment-to-metadata mappings, which only trigger if the 3D scene metadata matches a specific identifier:</p>
|
||||
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th></th>
|
||||
<th>fragment</th>
|
||||
<th>type</th>
|
||||
<th>example</th>
|
||||
|
@ -393,59 +394,59 @@ That way, if the link gets shared, the XR Fragments implementation at <code>http
|
|||
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><code>#<aliasname></code></td>
|
||||
<td><strong>PRESET</strong></td>
|
||||
<td><code>#<preset></code></td>
|
||||
<td>string</td>
|
||||
<td><code>#cubes</code></td>
|
||||
<td>evaluate predefined view (<code>#foo&bar</code>) defined in 3D Object metadata (<code>#cubes: #foo&bar</code> e.g.)</td>
|
||||
<td>evaluates preset (<code>#foo&bar</code>) defined in 3D Object metadata (<code>#cubes: #foo&bar</code> e.g.) while URL-browserbar reflects <code>#cubes</code>. Only works when metadata-key starts with <code>#</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>FOCUS</strong></td>
|
||||
<td><code>#<tag_or_objectname></code></td>
|
||||
<td>string</td>
|
||||
<td><code>#person</code></td>
|
||||
<td>focus object(s) with <code>tag: person</code> or name <code>person</code> by looking up XRWG</td>
|
||||
<td>(and show) object(s) with <code>tag: person</code> or name <code>person</code> (XRWG lookup)</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><code>#[-]<tag_or_objectname></code></td>
|
||||
<td><strong>FILTERS</strong></td>
|
||||
<td><code>#[!][-]<tag_or_objectname>[*]</code></td>
|
||||
<td>string</td>
|
||||
<td><code>#person</code> (<code>#-person</code>)</td>
|
||||
<td>focus/show (or hide) object(s) with <code>tag: person</code> or name <code>person</code> by looking up XRWG</td>
|
||||
<td>will reset (<code>!</code>), show/focus or hide (<code>-</code>) focus object(s) with <code>tag: person</code> or name <code>person</code> by looking up XRWG (<code>*</code>=including children)</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>CAMERASWITCH</strong></td>
|
||||
<td><code>#<cameraname></code></td>
|
||||
<td>string</td>
|
||||
<td><code>#cam01</code></td>
|
||||
<td>set camera with name <code>cam01</code> as active camera</td>
|
||||
<td>sets camera with name <code>cam01</code> as active camera</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><code>#<tag_or_objectname>=<material></code></td>
|
||||
<td><strong>MATERIALUPDATE</strong></td>
|
||||
<td><code>#<tag_or_objectname>[*]=<materialname></code></td>
|
||||
<td>string=string</td>
|
||||
<td><code>#car=metallic</code></td>
|
||||
<td>set material of car to material with name <code>metallic</code></td>
|
||||
<td>sets material of car to material with name <code>metallic</code> (<code>*</code>=including children)</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td></td>
|
||||
<td>r</td>
|
||||
<td></td>
|
||||
<td><code>#product=metallic</code></td>
|
||||
<td><code>#soldout*=halfopacity</code></td>
|
||||
<td>set material of objects tagged with <code>product</code> to material with name <code>metallic</code></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><code>#<tag_or_objectname>=<mediafrag></code></td>
|
||||
<td>string=<a href="https://www.w3.org/TR/media-frags/#valid-uri">media frag</a></td>
|
||||
<td><code>#foo=0,1</code> `</td>
|
||||
<td>play 3D animation (or <code>src</code> media) using <a href="https://www.w3.org/TR/media-frags/#valid-uri">media fragment URI</a> with <a href="#media%20fragments%20and%20datatypes">looping/speed/texturescroll abilities</a></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td></td>
|
||||
<td></td>
|
||||
<td><code>#foo=uv:0,0.5</code> `</td>
|
||||
<td>texturescroll to uv-coordinate <code>0,0.05</code> (see <a href="#media%20fragments%20and%20datatypes">looping/speed/texturescroll abilities here</a></td>
|
||||
<td><strong>VARIABLE UPDATE</strong></td>
|
||||
<td><code>#<variable>=<metadata-key></code></td>
|
||||
<td>string=string</td>
|
||||
<td><code>#foo=bar</code></td>
|
||||
<td>sets <a href="https://www.rfc-editor.org/rfc/rfc6570">URI Template</a> variable <code>foo</code> to the value <code>#t=0</code> from <strong>existing</strong> object metadata (<code>bar</code>:<code>#t=0</code> e.g.), This allows for reactive <a href="https://www.rfc-editor.org/rfc/rfc6570">URI Template</a> defined in object metadata elsewhere (<code>src</code>:<code>://m.com/cat.mp4#{foo}</code> e.g., to play media using <a href="https://www.w3.org/TR/media-frags/#valid-uri">media fragment URI</a>). NOTE: metadata-key should not start with <code>#</code></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
@ -495,13 +496,6 @@ That way, if the link gets shared, the XR Fragments implementation at <code>http
|
|||
<td>play from 0 seconds till 2 seconds (and stop)</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>temporal W3C media fragment</td>
|
||||
<td>xywh=x,y,w,h</td>
|
||||
<td>0,0,1,1</td>
|
||||
<td>crop (uv) coordinates (default for uv-coordinates is <code>0,0,1,1</code>)</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>temporal W3C media fragment *</td>
|
||||
<td>t=[l:]x,y</td>
|
||||
|
@ -511,20 +505,27 @@ That way, if the link gets shared, the XR Fragments implementation at <code>http
|
|||
|
||||
<tr>
|
||||
<td>temporal W3C media fragment *</td>
|
||||
<td>s=x[,y]</td>
|
||||
<td>uv=u,v</td>
|
||||
<td>uv:0,0,1,1</td>
|
||||
<td>set uv offset (default <code>0,0</code>)</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>temporal W3C media fragment *</td>
|
||||
<td>s=x</td>
|
||||
<td>1</td>
|
||||
<td>set playback speed of audio/video/3D anim</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>temporal W3C media fragment *</td>
|
||||
<td>sxy=[l:]x,y</td>
|
||||
<td>0.1,0.2</td>
|
||||
<td>xy scrollspeed of new xywh viewport/uvcoordinates (default <code>1,1</code> is instant): allows lerping to new <code>xywh</code> values [or infinite texturescrolling]</td>
|
||||
<td>suv=[l:]uspeed,vspeed</td>
|
||||
<td>uv:l:0.1,0.2</td>
|
||||
<td>set uv scroll speed of (default <code>1,1</code> is instant) [<code>l:</code> means infinite texturescrolling] otherwise new <code>u,v</code> values will be lerped to</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>temporal W3C media fragment *</td>
|
||||
<td>media parameter (shader uniform)</td>
|
||||
<td>u:<uniform>=<string</td>
|
||||
<td>float</td>
|
||||
<td>vec2</td>
|
||||
|
@ -533,7 +534,7 @@ That way, if the link gets shared, the XR Fragments implementation at <code>http
|
|||
</table>
|
||||
|
||||
<blockquote>
|
||||
<p>* = this is extending the <a href="https://www.w3.org/TR/media-frags/#mf-advanced">W3C media fragments</a> with finer playback/viewport-control:</p>
|
||||
<p>* = this is extending the <a href="https://www.w3.org/TR/media-frags/#mf-advanced">W3C media fragments</a> with finergrained playback/viewport-control:</p>
|
||||
</blockquote>
|
||||
|
||||
<table>
|
||||
|
@ -550,60 +551,60 @@ That way, if the link gets shared, the XR Fragments implementation at <code>http
|
|||
<td><code>t=0,2</code> specifies oneshot-play (default) whereas <code>t=l:0,2</code> indicates looped-play</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><code>#uv=</code> specifies uv-coordinates</td>
|
||||
<td>allows offsetting the uv-coordinates</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><code>#suv=</code> specifies scrollspeed of uv-coordinates</td>
|
||||
<td>allows single/infinite uv-scrolling</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><code>#s</code> specifies playback speed</td>
|
||||
<td>being able to specify loop(speed) of audio/video</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><code>#sxy=</code> specifies lerping of xy(wh) values</td>
|
||||
<td>allows animated cropping and infinite texturescroll with configurable speed for u/v coordinates</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><code>#u:<uniform>=</code></td>
|
||||
<td>specifies updating a uniform value</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
|
||||
<blockquote>
|
||||
<p>The rationale not to extend the <code>xywh</code>-media fragment is that 3D geometries deal with triangular polygons (not rectangular).</p>
|
||||
</blockquote>
|
||||
|
||||
<p>Example URI’s:</p>
|
||||
|
||||
<ul>
|
||||
<li><code>https://images.org/credits.jpg#t=0&suv=l:0,0.1</code> (infinite vertical texturescrolling)</li>
|
||||
<li><code>https://video.org/organogram.mp4#t=0&suv:0.1,0.1&uv=0.3,0.3</code> (animated zoom towards region in video)</li>
|
||||
<li><code>https://shaders.org/plasma.glsl#t=0&u:col1=1,0,0&u:col2=0,1,0</code> (red-green shader plasma starts playing from time-offset 0)</li>
|
||||
<li><code>https://images.org/credits.jpg#t=0&sxy=l:0,0.1</code> (infinite vertical texturescrolling)</li>
|
||||
<li><code>https://video.org/organogram.mp4#t=0&sxy:0.1,0.1&xywh=500,500,480,640</code> (animated zoom towards region in video)</li>
|
||||
</ul>
|
||||
|
||||
<pre><code> +──────────────────────────────────────────────────────────+
|
||||
│ │
|
||||
│ index.gltf#playall │
|
||||
│ │ │
|
||||
│ ├ # : #playall │ apply default XR Fragment on load
|
||||
│ ├ #playall: #media=play&wall=calm&t=1 │ here `t` plays the 3D animations inside index.gltf from 1 seconds
|
||||
│ ├ # : #t=0&shared=play │ apply default XR Fragment on load (`t` plays global 3D animation timeline)
|
||||
│ ├ play : #t=l:0,2 │ variable for [URI Templates (RFC6570)](https://www.rfc-editor.org/rfc/rfc6570)
|
||||
│ │ │
|
||||
│ ├── ◻ playbutton │
|
||||
│ │ └ href: #media=play&wall=calm ······· │ (re)trigger `play` on object 'media' and `calm` on 'wall'
|
||||
│ │ · │
|
||||
│ ├── ◻ plane · │
|
||||
│ │ └ src: foo.jpg#sxy=l:0,0.1 · │ infinite texturescroll `v` of uv·coordinates with 0.1/fps
|
||||
│ │ · │ with u·speed `0.1` and v·speed `0.1` (`#s` defaults) units p/second
|
||||
│ ├── ◻ media · │
|
||||
│ │ ├ play: #t=0 ················ · │ play cat.mp4 from 0 sec
|
||||
│ │ ├ #: #play ···^ · · │ apply default XR fragment (on load)
|
||||
│ │ ├ stop: #t=0,0 ··········· · │ stop
|
||||
│ │ ├ loop: #t=l:1,2&s=2 ············ │ loop cat.mp4 between 1 and 2 sec with double speed
|
||||
│ │ ├ crop: #xywh=0,0,0.5,0.5 ····· · │ crop viewport/uv·coordinates
|
||||
│ │ └ src: cat.mp4#t=l:2,10 <<······· · │ loop cat.mp4 (or mp3/wav/jpg) between 2 and 10 seconds
|
||||
│ │ · │
|
||||
│ └── ◻ wall · │
|
||||
│ ├ calm: #u:color=1,0,0 ················ │ updates uniform values (IFS shader e.g.)
|
||||
│ ├ #: #wall=calm ···^ · │ apply default XR Fragment (on load)
|
||||
│ └ src: ://a.com/art.fs#sxy:l:0,0.1 <<··· │ .fs/.vs/.glsl/.wgsl etc
|
||||
│ ├── ◻ plane (with material) │
|
||||
│ │ └ #: #suv=l:0,0.1 │ infinite texturescroll `v` of uv·coordinates with 0.1/fps
|
||||
│ │ │
|
||||
│ ├── ◻ plane │
|
||||
│ │ └ src: foo.jpg#suv=l:0,0.1 │ infinite texturescroll `v` of uv·coordinates with 0.1/fps
|
||||
│ │ │
|
||||
│ ├── ◻ media │
|
||||
│ │ └ src: cat.mp4#t=l:2,10&uv=0.5,0.5 │ loop cat.mp4 (or mp3/wav/jpg) between 2 and 10 seconds (uv's shifted with 0.5,0.5)
|
||||
│ │ │
|
||||
│ └── ◻ wall │
|
||||
│ ├ href: #color=blue │ updates uniform values (IFS shader e.g.)
|
||||
│ ├ blue: t=0&u:col=0,0,1 │ variable for [Level1 URI Templates (RFC6570)](https://www.rfc-editor.org/rfc/rfc6570)
|
||||
│ └ src: ://a.com/art.glsl#{color}&{shared} │ .fs/.vs/.glsl/.wgsl etc shader [Level1 URI Template (RFC6570)](https://www.rfc-editor.org/rfc/rfc6570)
|
||||
│ │
|
||||
│ │
|
||||
+──────────────────────────────────────────────────────────+
|
||||
|
||||
> NOTE: node-metadata (without #-prefix) applies XR Fragments to its `src` URL, otherwise it applies it to the browser URL. Full addressibility can be maintained, since top-level `href` values can trigger node-specific aliases (`media=play` e.g.).
|
||||
> NOTE: URI Template variables are immutable and respect scope: in other words, the end-user cannot modify `blue` by entering an URL like `#blue=.....` in the browser URL, and `blue` is not accessible by the plane/media-object (however `{play}` would work).
|
||||
|
||||
</code></pre>
|
||||
|
||||
|
@ -834,6 +835,8 @@ Resizing will be happen accordingly to its placeholder object <code>aquariumcube
|
|||
<li><p>in case of navigating to a new [[pos)ition, “first” navigate to the “current position” so that the “back-button” of the “browser-history” always refers to the previous position (see [<a href="https://github.com/coderofsalvation/xrfragment/blob/main/src/3rd/js/three/xrf/href.js#L97">here</a>)</p></li>
|
||||
|
||||
<li><p>ignore previous rule in special cases, like clicking an <code>href</code> using camera-portal collision (the back-button would cause a teleport-loop)</p></li>
|
||||
|
||||
<li><p>href-events should bubble upward the node-tree</p></li>
|
||||
</ol>
|
||||
|
||||
<p><a href="https://github.com/coderofsalvation/xrfragment/blob/main/src/3rd/js/three/xrf/href.js">» example implementation</a><br>
|
||||
|
@ -1231,7 +1234,7 @@ Some pointers for good UX (but not necessary to be XR Fragment compatible):</p>
|
|||
|
||||
<p>The <code>src</code>-values work as expected (respecting mime-types), however:</p>
|
||||
|
||||
<p>The XR Fragment specification bumps the traditional default browser-mimetype</p>
|
||||
<p>The XR Fragment specification advices to bump the traditional default browser-mimetype</p>
|
||||
|
||||
<p><code>text/plain;charset=US-ASCII</code></p>
|
||||
|
||||
|
@ -1471,13 +1474,38 @@ To filter out non-related objects one could take it a step further using filters
|
|||
|
||||
<p>This makes spatial content multi-purpose, without the need to separate content into separate files, or show/hide things using a complex logiclayer like javascript.</p>
|
||||
|
||||
<h1 id="uri-templates-rfc6570">URI Templates (RFC6570)</h1>
|
||||
|
||||
<p>XR Fragments adopts Level1 URI <strong>Fragment</strong> expansion to provide safe interactivity.<br>
|
||||
The following demonstrates a simple video player:</p>
|
||||
|
||||
<pre><code>
|
||||
+─────────────────────────────────────────────+
|
||||
│ │
|
||||
│ foo.usdz │
|
||||
│ │ │
|
||||
│ │ │
|
||||
│ ├── ◻ stopbutton │
|
||||
│ │ ├ #: #-stopbutton │
|
||||
│ │ └ href: #player=stop&-stopbutton │ (stop and hide stop-button)
|
||||
│ │ │
|
||||
│ └── ◻ plane │
|
||||
│ ├ play: #t=l:0,10 │
|
||||
│ ├ stop: #t=0,0 │
|
||||
│ ├ href: #player=play&stopbutton │ (play and show stop-button)
|
||||
│ └ src: cat.mp4#{player} │
|
||||
│ │
|
||||
│ │
|
||||
+─────────────────────────────────────────────+
|
||||
|
||||
|
||||
</code></pre>
|
||||
|
||||
<h1 id="security-considerations">Security Considerations</h1>
|
||||
|
||||
<p>Since XR Text contains metadata too, the user should be able to set up tagging-rules, so the copy-paste feature can :</p>
|
||||
|
||||
<ul>
|
||||
<li>filter out sensitive data when copy/pasting (XR text with <code>tag:secret</code> e.g.)</li>
|
||||
</ul>
|
||||
<p>The only dynamic parts are <a href="https://www.w3.org/TR/media-frags/">W3C Media Fragments</a> and <a href="https://www.rfc-editor.org/rfc/rfc6570">URI Templates (RFC6570)</a>.<br>
|
||||
The use of URI Templates is limited to pre-defined variables and Level0 fragments-expansion only, which makes it quite safe.<br>
|
||||
In fact, it is much safer than relying on a scripting language (javascript) which can change URN too.</p>
|
||||
|
||||
<h1 id="faq">FAQ</h1>
|
||||
|
||||
|
@ -1486,12 +1514,19 @@ To filter out non-related objects one could take it a step further using filters
|
|||
|
||||
<hr>
|
||||
|
||||
<p><strong>Q:</strong> Why isn’t there support for scripting, while we have things like WASM
|
||||
<strong>A:</strong> This is out of scope as it unhyperifies hypermedia, and this is up to XR hypermedia browser-extensions.<br> Historically scripting/Javascript seems to been able to turn webpages from hypermedia documents into its opposite (hyperscripted nonhypermedia documents).<br>In order to prevent this backward-movement (hypermedia tends to liberate people from finnicky scripting) XR Fragments should never unhyperify itself by hardcoupling to a particular markup or scripting language. <a href="https://xrfragment.org/doc/RFC_XR_Macros.html">XR Macro’s</a> are an example of something which is probably smarter and safer for hypermedia browsers to implement, instead of going full-in with a turing-complete scripting language (and suffer the security consequences later).<br>
|
||||
<p><strong>Q:</strong> Why isn’t there support for scripting, URI Template Fragments are so limited compared to WASM & javascript
|
||||
<strong>A:</strong> This is out of scope as it unhyperifies hypermedia, and this is up to XR hypermedia browser-extensions.<br> Historically scripting/Javascript seems to been able to turn webpages from hypermedia documents into its opposite (hyperscripted nonhypermedia documents).<br>In order to prevent this backward-movement (hypermedia tends to liberate people from finnicky scripting) XR Fragment uses <a href="https://www.w3.org/TR/media-frags/">W3C Media Fragments</a> and <a href="https://www.rfc-editor.org/rfc/rfc6570">URI Templates (RFC6570)</a>, to prevent unhyperifying itself by hardcoupling to a particular markup or scripting language. <br>
|
||||
XR Fragments supports filtering objects in a scene only, because in the history of the javascript-powered web, showing/hiding document-entities seems to be one of the most popular basic usecases.<br>
|
||||
Doing advanced scripting & networkrequests under the hood are obviously interesting endavours, but this is something which should not be hardcoupled with hypermedia.<br>This belongs to browser extensions.<br>
|
||||
Doing advanced scripting & networkrequests under the hood are obviously interesting endavours, but this is something which should not be hardcoupled with XR Fragments or hypermedia.<br>This perhaps belongs more to browser extensions.<br>
|
||||
Non-HTML Hypermedia browsers should make browser extensions the right place, to ‘extend’ experiences, in contrast to code/javascript inside hypermedia documents (this turned out as a hypermedia antipattern).</p>
|
||||
|
||||
<h1 id="authors">authors</h1>
|
||||
|
||||
<ul>
|
||||
<li>Leon van Kammen (@lvk@mastodon.online)</li>
|
||||
<li>Jens Finkhäuser (@jens@social.finkhaeuser.de)</li>
|
||||
</ul>
|
||||
|
||||
<h1 id="iana-considerations">IANA Considerations</h1>
|
||||
|
||||
<p>This document has no IANA actions.</p>
|
||||
|
@ -1549,6 +1584,11 @@ Non-HTML Hypermedia browsers should make browser extensions the right place, to
|
|||
<td>something somewhere via someprotocol (<code>http://me.com/foo.glb</code>)</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>URN</td>
|
||||
<td>something at some domain (<code>me.com/foo.glb</code>)</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>metadata</td>
|
||||
<td>custom properties of text, 3D Scene or Object(nodes), relevant to machines and a human minority (academics/developers)</td>
|
||||
|
|
|
@ -246,7 +246,7 @@ That way, if the link gets shared, the XR Fragments implementation at `https://m
|
|||
|
||||
> Supported popular compatible 3D fileformats: `.gltf`, `.obj`, `.fbx`, `.usdz`, `.json` (THREE.js), `.dae` and so on.
|
||||
|
||||
## Dynamic XR Fragments (+databindings)
|
||||
## Fragment-to-metadata mapping
|
||||
|
||||
These are automatic fragment-to-metadata mappings, which only trigger if the 3D scene metadata matches a specific identifier:
|
||||
|
||||
|
@ -257,7 +257,7 @@ These are automatic fragment-to-metadata mappings, which only trigger if the 3D
|
|||
| **FILTERS** | `#[!][-]<tag_or_objectname>[*]` | string | `#person` (`#-person`) | will reset (`!`), show/focus or hide (`-`) focus object(s) with `tag: person` or name `person` by looking up XRWG (`*`=including children) |
|
||||
| **CAMERASWITCH** | `#<cameraname>` | string | `#cam01` | sets camera with name `cam01` as active camera |
|
||||
| **MATERIALUPDATE** | `#<tag_or_objectname>[*]=<materialname>` | string=string | `#car=metallic`| sets material of car to material with name `metallic` (`*`=including children)|
|
||||
| | r | | `#soldout*=halfopacity`| set material of objects tagged with `product` to material with name `metallic` |
|
||||
| | | | `#soldout*=halfopacity`| set material of objects tagged with `product` to material with name `metallic` |
|
||||
| **VARIABLE UPDATE** | `#<variable>=<metadata-key>` | string=string | `#foo=bar` | sets [URI Template](https://www.rfc-editor.org/rfc/rfc6570) variable `foo` to the value `#t=0` from **existing** object metadata (`bar`:`#t=0` e.g.), This allows for reactive [URI Template](https://www.rfc-editor.org/rfc/rfc6570) defined in object metadata elsewhere (`src`:`://m.com/cat.mp4#{foo}` e.g., to play media using [media fragment URI](https://www.w3.org/TR/media-frags/#valid-uri)). NOTE: metadata-key should not start with `#` |
|
||||
|
||||
## media fragments and datatypes
|
||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 564 KiB After Width: | Height: | Size: 12 KiB |
File diff suppressed because it is too large
Load Diff
|
@ -7,12 +7,12 @@
|
|||
<author initials="L.R." surname="van Kammen" fullname="L.R. van Kammen"><organization></organization><address><postal><street></street>
|
||||
</postal></address></author><date/>
|
||||
<area>Internet</area>
|
||||
<workgroup>Internet Engineering Task Force</workgroup>
|
||||
<workgroup>Jens & Leon Internet Engineering Task Force</workgroup>
|
||||
|
||||
<abstract>
|
||||
<t>This draft is a specification for 4D URI's & <eref target="https://github.com/coderofsalvation/hypermediatic">hypermediatic</eref> navigation, which links together space, time & text together, for hypermedia browsers with- or without a network-connection.<br />
|
||||
|
||||
The specification promotes spatial addressibility, sharing, navigation, filtering and databinding objects for (XR) Browsers.<br />
|
||||
The specification uses <eref target="https://www.w3.org/TR/media-frags/">W3C Media Fragments</eref> and <eref target="https://www.rfc-editor.org/rfc/rfc6570">URI Templates (RFC6570)</eref> to promote spatial addressibility, sharing, navigation, filtering and databinding objects for (XR) Browsers.<br />
|
||||
|
||||
XR Fragments allows us to better use existing metadata inside 3D scene(files), by connecting it to proven technologies like <eref target="https://en.wikipedia.org/wiki/URI_fragment">URI Fragments</eref>.</t>
|
||||
<t>Almost every idea in this document is demonstrated at <eref target="https://xrfragment.org">https://xrfragment.org</eref></t>
|
||||
|
@ -48,18 +48,18 @@ XR Fragments exploits the fact that all 3D models already contain such metadata:
|
|||
Instead of forcing authors to combine 3D/2D objects programmatically (publishing thru a game-editor e.g.), XR Fragments <strong>integrates all</strong> which allows a universal viewing experience.<br />
|
||||
</t>
|
||||
|
||||
<artwork> +───────────────────────────────────────────────────────────────────────────────────────────────+
|
||||
<artwork><![CDATA[ +───────────────────────────────────────────────────────────────────────────────────────────────+
|
||||
│ │
|
||||
│ U R N │
|
||||
│ U R L | │
|
||||
│ | |-----------------+--------| │
|
||||
│ +--------------------------------------------------| │
|
||||
│ | │
|
||||
│ + https://foo.com/some/foo/scene.glb#someview <-- http URI (=URL and has URN) │
|
||||
│ + https://foo.com/some/foo/scene.glb#someview <-- http URI (=URL and has URN) │
|
||||
│ | │
|
||||
│ + ipfs://cfe0987ec9r9098ecr/cats.fbx#someview <-- an IPFS URI (=URL and has URN) │
|
||||
│ + ipfs://cfe0987ec9r9098ecr/cats.fbx#someview <-- an IPFS URI (=URL and has URN) │
|
||||
│ │
|
||||
│ ec09f7e9cf8e7f09c8e7f98e79c09ef89e000efece8f7ecfe9fe <-- an interpeer URI │
|
||||
│ ec09f7e9cf8e7f09c8e7f98e79c09ef89e000efece8f7ecfe9fe <-- an interpeer URI │
|
||||
│ │
|
||||
│ │
|
||||
│ |------------------------+-------------------------| │
|
||||
|
@ -68,19 +68,20 @@ Instead of forcing authors to combine 3D/2D objects programmatically (publishing
|
|||
│ │
|
||||
+───────────────────────────────────────────────────────────────────────────────────────────────+
|
||||
|
||||
]]>
|
||||
</artwork>
|
||||
<t>Fact: our typical browser URL's are just <strong>a possible implementation</strong> of URI's (for untapped humancentric potential of URI's <eref target="https://interpeer.io">see interpeer.io</eref>)</t>
|
||||
<blockquote><t>XR Fragments does not look at XR (or the web) thru the lens of HTML or URLs.<br />
|
||||
But approaches things from a higherlevel feedbackloop/hypermedia browser-perspective.</t>
|
||||
</blockquote><t>Below you can see how this translates back into good-old URLs:</t>
|
||||
|
||||
<artwork> +───────────────────────────────────────────────────────────────────────────────────────────────+
|
||||
<artwork><![CDATA[ +───────────────────────────────────────────────────────────────────────────────────────────────+
|
||||
│ │
|
||||
│ the soul of any URL: ://macro /meso ?micro #nano │
|
||||
│ │
|
||||
│ 2D URL: ://library.com /document ?search #chapter │
|
||||
│ │
|
||||
│ 4D URL: ://park.com /4Dscene.fbx ─> ?other.glb ─> #view ───> hashbus │
|
||||
│ 4D URL: ://park.com /4Dscene.fbx ─> ?other.glb ─> #view ───> hashbus │
|
||||
│ │ #filter │ │
|
||||
│ │ #tag │ │
|
||||
│ │ (hypermediatic) #material │ │
|
||||
|
@ -88,13 +89,14 @@ But approaches things from a higherlevel feedbackloop/hypermedia browser-perspec
|
|||
│ │ ( loop ) #texture │ │
|
||||
│ │ #variable │ │
|
||||
│ │ │ │
|
||||
│ XRWG <─────────────────────<─────────────+ │
|
||||
│ XRWG <─────────────────────<─────────────+ │
|
||||
│ │ │ │
|
||||
│ └─ objects ──────────────>─────────────+ │
|
||||
│ └─ objects ──────────────>─────────────+ │
|
||||
│ │
|
||||
│ │
|
||||
+───────────────────────────────────────────────────────────────────────────────────────────────+
|
||||
|
||||
]]>
|
||||
</artwork>
|
||||
<blockquote><t>?-linked and #-linked navigation allows a Hypermediatic FeedbackLoop (HFL) between external and internal 4D navigation.</t>
|
||||
</blockquote><t>Traditional webbrowsers can become 4D document-ready by:</t>
|
||||
|
@ -172,9 +174,10 @@ But approaches things from a higherlevel feedbackloop/hypermedia browser-perspec
|
|||
<section anchor="xr-fragment-url-grammar"><name>XR Fragment URL Grammar</name>
|
||||
<t>For typical HTTP-like browsers/applications:</t>
|
||||
|
||||
<artwork>reserved = gen-delims / sub-delims
|
||||
gen-delims = "#" / "&"
|
||||
sub-delims = "," / "="
|
||||
<artwork><![CDATA[reserved = gen-delims / sub-delims
|
||||
gen-delims = "#" / "&"
|
||||
sub-delims = "," / "="
|
||||
]]>
|
||||
</artwork>
|
||||
<blockquote><t>Example: <tt>://foo.com/my3d.gltf#pos=1,0,0&prio=-5&t=0,100</tt></t>
|
||||
</blockquote><table>
|
||||
|
@ -286,11 +289,12 @@ That way, if the link gets shared, the XR Fragments implementation at <tt>https:
|
|||
</table><blockquote><t>Supported popular compatible 3D fileformats: <tt>.gltf</tt>, <tt>.obj</tt>, <tt>.fbx</tt>, <tt>.usdz</tt>, <tt>.json</tt> (THREE.js), <tt>.dae</tt> and so on.</t>
|
||||
</blockquote></section>
|
||||
|
||||
<section anchor="dynamic-xr-fragments-databindings"><name>Dynamic XR Fragments (+databindings)</name>
|
||||
<t>These are automatic fragment-to-metadata mappings, which only trigger if the 3D scene metadata matches a specific identifier (<tt>aliasname</tt> e.g.)</t>
|
||||
<section anchor="fragment-to-metadata-mapping"><name>Fragment-to-metadata mapping</name>
|
||||
<t>These are automatic fragment-to-metadata mappings, which only trigger if the 3D scene metadata matches a specific identifier:</t>
|
||||
<table>
|
||||
<thead>
|
||||
<tr>
|
||||
<th></th>
|
||||
<th>fragment</th>
|
||||
<th>type</th>
|
||||
<th>example</th>
|
||||
|
@ -300,59 +304,59 @@ That way, if the link gets shared, the XR Fragments implementation at <tt>https:
|
|||
|
||||
<tbody>
|
||||
<tr>
|
||||
<td><tt>#<aliasname></tt></td>
|
||||
<td><strong>PRESET</strong></td>
|
||||
<td><tt>#<preset></tt></td>
|
||||
<td>string</td>
|
||||
<td><tt>#cubes</tt></td>
|
||||
<td>evaluate predefined view (<tt>#foo&bar</tt>) defined in 3D Object metadata (<tt>#cubes: #foo&bar</tt> e.g.)</td>
|
||||
<td>evaluates preset (<tt>#foo&bar</tt>) defined in 3D Object metadata (<tt>#cubes: #foo&bar</tt> e.g.) while URL-browserbar reflects <tt>#cubes</tt>. Only works when metadata-key starts with <tt>#</tt></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>FOCUS</strong></td>
|
||||
<td><tt>#<tag_or_objectname></tt></td>
|
||||
<td>string</td>
|
||||
<td><tt>#person</tt></td>
|
||||
<td>focus object(s) with <tt>tag: person</tt> or name <tt>person</tt> by looking up XRWG</td>
|
||||
<td>(and show) object(s) with <tt>tag: person</tt> or name <tt>person</tt> (XRWG lookup)</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><tt>#[-]<tag_or_objectname></tt></td>
|
||||
<td><strong>FILTERS</strong></td>
|
||||
<td><tt>#[!][-]<tag_or_objectname>[*]</tt></td>
|
||||
<td>string</td>
|
||||
<td><tt>#person</tt> (<tt>#-person</tt>)</td>
|
||||
<td>focus/show (or hide) object(s) with <tt>tag: person</tt> or name <tt>person</tt> by looking up XRWG</td>
|
||||
<td>will reset (<tt>!</tt>), show/focus or hide (<tt>-</tt>) focus object(s) with <tt>tag: person</tt> or name <tt>person</tt> by looking up XRWG (<tt>*</tt>=including children)</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><strong>CAMERASWITCH</strong></td>
|
||||
<td><tt>#<cameraname></tt></td>
|
||||
<td>string</td>
|
||||
<td><tt>#cam01</tt></td>
|
||||
<td>set camera with name <tt>cam01</tt> as active camera</td>
|
||||
<td>sets camera with name <tt>cam01</tt> as active camera</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><tt>#<tag_or_objectname>=<material></tt></td>
|
||||
<td><strong>MATERIALUPDATE</strong></td>
|
||||
<td><tt>#<tag_or_objectname>[*]=<materialname></tt></td>
|
||||
<td>string=string</td>
|
||||
<td><tt>#car=metallic</tt></td>
|
||||
<td>set material of car to material with name <tt>metallic</tt></td>
|
||||
<td>sets material of car to material with name <tt>metallic</tt> (<tt>*</tt>=including children)</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td></td>
|
||||
<td>r</td>
|
||||
<td></td>
|
||||
<td><tt>#product=metallic</tt></td>
|
||||
<td><tt>#soldout*=halfopacity</tt></td>
|
||||
<td>set material of objects tagged with <tt>product</tt> to material with name <tt>metallic</tt></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><tt>#<tag_or_objectname>=<mediafrag></tt></td>
|
||||
<td>string=<eref target="https://www.w3.org/TR/media-frags/#valid-uri">media frag</eref></td>
|
||||
<td><tt>#foo=0,1</tt> `</td>
|
||||
<td>play 3D animation (or <tt>src</tt> media) using <eref target="https://www.w3.org/TR/media-frags/#valid-uri">media fragment URI</eref> with <eref target="#media%20fragments%20and%20datatypes">looping/speed/texturescroll abilities</eref></td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td></td>
|
||||
<td></td>
|
||||
<td><tt>#foo=uv:0,0.5</tt> `</td>
|
||||
<td>texturescroll to uv-coordinate <tt>0,0.05</tt> (see <eref target="#media%20fragments%20and%20datatypes">looping/speed/texturescroll abilities here</eref></td>
|
||||
<td><strong>VARIABLE UPDATE</strong></td>
|
||||
<td><tt>#<variable>=<metadata-key></tt></td>
|
||||
<td>string=string</td>
|
||||
<td><tt>#foo=bar</tt></td>
|
||||
<td>sets <eref target="https://www.rfc-editor.org/rfc/rfc6570">URI Template</eref> variable <tt>foo</tt> to the value <tt>#t=0</tt> from <strong>existing</strong> object metadata (<tt>bar</tt>:<tt>#t=0</tt> e.g.), This allows for reactive <eref target="https://www.rfc-editor.org/rfc/rfc6570">URI Template</eref> defined in object metadata elsewhere (<tt>src</tt>:<tt>://m.com/cat.mp4#{foo}</tt> e.g., to play media using <eref target="https://www.w3.org/TR/media-frags/#valid-uri">media fragment URI</eref>). NOTE: metadata-key should not start with <tt>#</tt></td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table></section>
|
||||
|
@ -398,13 +402,6 @@ That way, if the link gets shared, the XR Fragments implementation at <tt>https:
|
|||
<td>play from 0 seconds till 2 seconds (and stop)</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>temporal W3C media fragment</td>
|
||||
<td>xywh=x,y,w,h</td>
|
||||
<td>0,0,1,1</td>
|
||||
<td>crop (uv) coordinates (default for uv-coordinates is <tt>0,0,1,1</tt>)</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>temporal W3C media fragment *</td>
|
||||
<td>t=[l:]x,y</td>
|
||||
|
@ -414,26 +411,33 @@ That way, if the link gets shared, the XR Fragments implementation at <tt>https:
|
|||
|
||||
<tr>
|
||||
<td>temporal W3C media fragment *</td>
|
||||
<td>s=x[,y]</td>
|
||||
<td>uv=u,v</td>
|
||||
<td>uv:0,0,1,1</td>
|
||||
<td>set uv offset (default <tt>0,0</tt>)</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>temporal W3C media fragment *</td>
|
||||
<td>s=x</td>
|
||||
<td>1</td>
|
||||
<td>set playback speed of audio/video/3D anim</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>temporal W3C media fragment *</td>
|
||||
<td>sxy=[l:]x,y</td>
|
||||
<td>0.1,0.2</td>
|
||||
<td>xy scrollspeed of new xywh viewport/uvcoordinates (default <tt>1,1</tt> is instant): allows lerping to new <tt>xywh</tt> values [or infinite texturescrolling]</td>
|
||||
<td>suv=[l:]uspeed,vspeed</td>
|
||||
<td>uv:l:0.1,0.2</td>
|
||||
<td>set uv scroll speed of (default <tt>1,1</tt> is instant) [<tt>l:</tt> means infinite texturescrolling] otherwise new <tt>u,v</tt> values will be lerped to</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>temporal W3C media fragment *</td>
|
||||
<td>media parameter (shader uniform)</td>
|
||||
<td>u:<uniform>=<string</td>
|
||||
<td>float</td>
|
||||
<td>vec2</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table><blockquote><t>* = this is extending the <eref target="https://www.w3.org/TR/media-frags/#mf-advanced">W3C media fragments</eref> with finer playback/viewport-control:</t>
|
||||
</table><blockquote><t>* = this is extending the <eref target="https://www.w3.org/TR/media-frags/#mf-advanced">W3C media fragments</eref> with finergrained playback/viewport-control:</t>
|
||||
</blockquote><table>
|
||||
<thead>
|
||||
<tr>
|
||||
|
@ -448,60 +452,57 @@ That way, if the link gets shared, the XR Fragments implementation at <tt>https:
|
|||
<td><tt>t=0,2</tt> specifies oneshot-play (default) whereas <tt>t=l:0,2</tt> indicates looped-play</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><tt>#uv=</tt> specifies uv-coordinates</td>
|
||||
<td>allows offsetting the uv-coordinates</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><tt>#suv=</tt> specifies scrollspeed of uv-coordinates</td>
|
||||
<td>allows single/infinite uv-scrolling</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><tt>#s</tt> specifies playback speed</td>
|
||||
<td>being able to specify loop(speed) of audio/video</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><tt>#sxy=</tt> specifies lerping of xy(wh) values</td>
|
||||
<td>allows animated cropping and infinite texturescroll with configurable speed for u/v coordinates</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td><tt>#u:<uniform>=</tt></td>
|
||||
<td>specifies updating a uniform value</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table><t>Example URI's:</t>
|
||||
</table><blockquote><t>The rationale not to extend the <tt>xywh</tt>-media fragment is that 3D geometries deal with triangular polygons (not rectangular).</t>
|
||||
</blockquote><t>Example URI's:</t>
|
||||
|
||||
<ul spacing="compact">
|
||||
<li><tt>https://images.org/credits.jpg#t=0&suv=l:0,0.1</tt> (infinite vertical texturescrolling)</li>
|
||||
<li><tt>https://video.org/organogram.mp4#t=0&suv:0.1,0.1&uv=0.3,0.3</tt> (animated zoom towards region in video)</li>
|
||||
<li><tt>https://shaders.org/plasma.glsl#t=0&u:col1=1,0,0&u:col2=0,1,0</tt> (red-green shader plasma starts playing from time-offset 0)</li>
|
||||
<li><tt>https://images.org/credits.jpg#t=0&sxy=l:0,0.1</tt> (infinite vertical texturescrolling)</li>
|
||||
<li><tt>https://video.org/organogram.mp4#t=0&sxy:0.1,0.1&xywh=500,500,480,640</tt> (animated zoom towards region in video)</li>
|
||||
</ul>
|
||||
|
||||
<artwork> +──────────────────────────────────────────────────────────+
|
||||
<artwork><![CDATA[ +──────────────────────────────────────────────────────────+
|
||||
│ │
|
||||
│ index.gltf#playall │
|
||||
│ │ │
|
||||
│ ├ # : #playall │ apply default XR Fragment on load
|
||||
│ ├ #playall: #media=play&wall=calm&t=1 │ here `t` plays the 3D animations inside index.gltf from 1 seconds
|
||||
│ ├ # : #t=0&shared=play │ apply default XR Fragment on load (`t` plays global 3D animation timeline)
|
||||
│ ├ play : #t=l:0,2 │ variable for [URI Templates (RFC6570)](https://www.rfc-editor.org/rfc/rfc6570)
|
||||
│ │ │
|
||||
│ ├── ◻ playbutton │
|
||||
│ │ └ href: #media=play&wall=calm ······· │ (re)trigger `play` on object 'media' and `calm` on 'wall'
|
||||
│ │ · │
|
||||
│ ├── ◻ plane · │
|
||||
│ │ └ src: foo.jpg#sxy=l:0,0.1 · │ infinite texturescroll `v` of uv·coordinates with 0.1/fps
|
||||
│ │ · │ with u·speed `0.1` and v·speed `0.1` (`#s` defaults) units p/second
|
||||
│ ├── ◻ media · │
|
||||
│ │ ├ play: #t=0 ················ · │ play cat.mp4 from 0 sec
|
||||
│ │ ├ #: #play ···^ · · │ apply default XR fragment (on load)
|
||||
│ │ ├ stop: #t=0,0 ··········· · │ stop
|
||||
│ │ ├ loop: #t=l:1,2&s=2 ············ │ loop cat.mp4 between 1 and 2 sec with double speed
|
||||
│ │ ├ crop: #xywh=0,0,0.5,0.5 ····· · │ crop viewport/uv·coordinates
|
||||
│ │ └ src: cat.mp4#t=l:2,10 <<······· · │ loop cat.mp4 (or mp3/wav/jpg) between 2 and 10 seconds
|
||||
│ │ · │
|
||||
│ └── ◻ wall · │
|
||||
│ ├ calm: #u:color=1,0,0 ················ │ updates uniform values (IFS shader e.g.)
|
||||
│ ├ #: #wall=calm ···^ · │ apply default XR Fragment (on load)
|
||||
│ └ src: ://a.com/art.fs#sxy:l:0,0.1 <<··· │ .fs/.vs/.glsl/.wgsl etc
|
||||
│ ├── ◻ plane (with material) │
|
||||
│ │ └ #: #suv=l:0,0.1 │ infinite texturescroll `v` of uv·coordinates with 0.1/fps
|
||||
│ │ │
|
||||
│ ├── ◻ plane │
|
||||
│ │ └ src: foo.jpg#suv=l:0,0.1 │ infinite texturescroll `v` of uv·coordinates with 0.1/fps
|
||||
│ │ │
|
||||
│ ├── ◻ media │
|
||||
│ │ └ src: cat.mp4#t=l:2,10&uv=0.5,0.5 │ loop cat.mp4 (or mp3/wav/jpg) between 2 and 10 seconds (uv's shifted with 0.5,0.5)
|
||||
│ │ │
|
||||
│ └── ◻ wall │
|
||||
│ ├ href: #color=blue │ updates uniform values (IFS shader e.g.)
|
||||
│ ├ blue: t=0&u:col=0,0,1 │ variable for [Level1 URI Templates (RFC6570)](https://www.rfc-editor.org/rfc/rfc6570)
|
||||
│ └ src: ://a.com/art.glsl#{color}&{shared} │ .fs/.vs/.glsl/.wgsl etc shader [Level1 URI Template (RFC6570)](https://www.rfc-editor.org/rfc/rfc6570)
|
||||
│ │
|
||||
│ │
|
||||
+──────────────────────────────────────────────────────────+
|
||||
|
||||
> NOTE: node-metadata (without #-prefix) applies XR Fragments to its `src` URL, otherwise it applies it to the browser URL. Full addressibility can be maintained, since top-level `href` values can trigger node-specific aliases (`media=play` e.g.).
|
||||
> NOTE: URI Template variables are immutable and respect scope: in other words, the end-user cannot modify `blue` by entering an URL like `#blue=.....` in the browser URL, and `blue` is not accessible by the plane/media-object (however `{play}` would work).
|
||||
|
||||
]]>
|
||||
</artwork>
|
||||
</section>
|
||||
</section>
|
||||
|
@ -509,7 +510,7 @@ That way, if the link gets shared, the XR Fragments implementation at <tt>https:
|
|||
<section anchor="spatial-referencing-3d"><name>Spatial Referencing 3D</name>
|
||||
<t>XR Fragments assume the following objectname-to-URIFragment mapping:</t>
|
||||
|
||||
<artwork>
|
||||
<artwork><![CDATA[
|
||||
my.io/scene.fbx
|
||||
+─────────────────────────────+
|
||||
│ sky │ src: http://my.io/scene.fbx#sky (includes building,mainobject,floor)
|
||||
|
@ -525,6 +526,7 @@ That way, if the link gets shared, the XR Fragments implementation at <tt>https:
|
|||
│ +─────────────────────────+ │
|
||||
+─────────────────────────────+
|
||||
|
||||
]]>
|
||||
</artwork>
|
||||
<blockquote><t>Every 3D fileformat supports named 3D object, and this name allows URLs (fragments) to reference them (and their children objects).</t>
|
||||
</blockquote><t>Clever nested design of 3D scenes allow great ways for re-using content, and/or previewing scenes.<br />
|
||||
|
@ -575,18 +577,19 @@ For example, to render a portal with a preview-version of the scene, create an 3
|
|||
</ol>
|
||||
<t>Here's an ascii representation of a 3D scene-graph which contains 3D objects <tt>◻</tt> and their metadata:</t>
|
||||
|
||||
<artwork> +────────────────────────────────────────────────────────+
|
||||
<artwork><![CDATA[ +────────────────────────────────────────────────────────+
|
||||
│ │
|
||||
│ index.gltf │
|
||||
│ │ │
|
||||
│ ├── ◻ buttonA │
|
||||
│ │ └ href: #pos=1,0,1&t=100,200 │
|
||||
│ │ └ href: #pos=1,0,1&t=100,200 │
|
||||
│ │ │
|
||||
│ └── ◻ buttonB │
|
||||
│ └ href: other.fbx │ <── file─agnostic (can be .gltf .obj etc)
|
||||
│ └ href: other.fbx │ <── file─agnostic (can be .gltf .obj etc)
|
||||
│ │
|
||||
+────────────────────────────────────────────────────────+
|
||||
|
||||
]]>
|
||||
</artwork>
|
||||
<t>An XR Fragment-compatible browser viewing this scene, allows the end-user to interact with the <tt>buttonA</tt> and <tt>buttonB</tt>.<br />
|
||||
|
||||
|
@ -634,7 +637,7 @@ It instances content (in objects) in the current scene/asset.</t>
|
|||
</tbody>
|
||||
</table><t>Here's an ascii representation of a 3D scene-graph with 3D objects <tt>◻</tt> which embeds remote & local 3D objects <tt>◻</tt> with/out using filters:</t>
|
||||
|
||||
<artwork> +────────────────────────────────────────────────────────+ +─────────────────────────+
|
||||
<artwork><![CDATA[ +────────────────────────────────────────────────────────+ +─────────────────────────+
|
||||
│ │ │ │
|
||||
│ index.gltf │ │ ocean.com/aquarium.fbx │
|
||||
│ │ │ │ ├ room │
|
||||
|
@ -651,6 +654,7 @@ It instances content (in objects) in the current scene/asset.</t>
|
|||
│ └ src: #canvas │
|
||||
│ │
|
||||
+────────────────────────────────────────────────────────+
|
||||
]]>
|
||||
</artwork>
|
||||
<t>An XR Fragment-compatible browser viewing this scene, lazy-loads and projects <tt>painting.png</tt> onto the (plane) object called <tt>canvas</tt> (which is copy-instanced in the bed and livingroom).<br />
|
||||
|
||||
|
@ -730,6 +734,8 @@ Resizing will be happen accordingly to its placeholder object <tt>aquariumcube</
|
|||
</li>
|
||||
<li><t>ignore previous rule in special cases, like clicking an <tt>href</tt> using camera-portal collision (the back-button would cause a teleport-loop)</t>
|
||||
</li>
|
||||
<li><t>href-events should bubble upward the node-tree</t>
|
||||
</li>
|
||||
</ol>
|
||||
<t><eref target="https://github.com/coderofsalvation/xrfragment/blob/main/src/3rd/js/three/xrf/href.js">» example implementation</eref><br />
|
||||
|
||||
|
@ -967,7 +973,7 @@ XR Fragments does this by detecting Bib(s)Tex, without introducing a new languag
|
|||
</ol>
|
||||
<t>Example:</t>
|
||||
|
||||
<artwork> http://y.io/z.fbx | Derived XRWG (expressed as BibTex)
|
||||
<artwork><![CDATA[ http://y.io/z.fbx | Derived XRWG (expressed as BibTex)
|
||||
----------------------------------------------------------------------------+--------------------------------------
|
||||
| @house{castle,
|
||||
+-[src: data:.....]----------------------+ +-[3D mesh]-+ | url = {https://y.io/z.fbx#castle}
|
||||
|
@ -985,11 +991,12 @@ XR Fragments does this by detecting Bib(s)Tex, without introducing a new languag
|
|||
| /|\ | |
|
||||
| / \ | |
|
||||
+--------+ |
|
||||
]]>
|
||||
</artwork>
|
||||
<blockquote><t>the <tt>#john@baroque</tt>-bib associates both text <tt>John</tt> and objectname <tt>john</tt>, with tag <tt>baroque</tt></t>
|
||||
</blockquote><t>Another example:</t>
|
||||
|
||||
<artwork> http://y.io/z.fbx | Derived XRWG (expressed as BibTex)
|
||||
<artwork><![CDATA[ http://y.io/z.fbx | Derived XRWG (expressed as BibTex)
|
||||
----------------------------------------------------------------------------+--------------------------------------
|
||||
|
|
||||
+-[src: data:.....]----------------------+ +-[3D mesh]-+ | @house{castle,
|
||||
|
@ -1007,6 +1014,7 @@ XR Fragments does this by detecting Bib(s)Tex, without introducing a new languag
|
|||
| #baroque@todo@house | | /|\ | |
|
||||
| ... | | / \ | |
|
||||
+----------------------------------------+ +--------+ |
|
||||
]]>
|
||||
</artwork>
|
||||
<blockquote><t>both <tt>#john@baroque</tt>-bib and BibTex <tt>@baroque{john}</tt> result in the same XRWG, however on top of that 2 tages (<tt>house</tt> and <tt>todo</tt>) are now associated with text/objectname/tag 'baroque'.</t>
|
||||
</blockquote><t>As seen above, the XRWG can expand <eref target="https://github.com/coderofsalvation/hashtagbibs">bibs</eref> (and the whole scene) to BibTeX.<br />
|
||||
|
@ -1060,26 +1068,27 @@ Some pointers for good UX (but not necessary to be XR Fragment compatible):</t>
|
|||
<blockquote><t>The simplicity of appending metadata (and leveling the metadata-playfield between humans and machines) is also demonstrated by <eref target="https://visual-meta.info">visual-meta</eref> in greater detail.</t>
|
||||
</blockquote><t>Fictional chat:</t>
|
||||
|
||||
<artwork><John> Hey what about this: https://my.com/station.gltf#pos=0,0,1&rot=90,2,0&t=500,1000
|
||||
<Sarah> I'm checking it right now
|
||||
<Sarah> I don't see everything..where's our text from yesterday?
|
||||
<John> Ah wait, that's tagged with tag 'draft' (and hidden)..hold on, try this:
|
||||
<John> https://my.com/station.gltf#.draft&pos=0,0,1&rot=90,2,0&t=500,1000
|
||||
<Sarah> how about we link the draft to the upcoming YELLO-event?
|
||||
<John> ok I'm adding #draft@YELLO
|
||||
<Sarah> Yesterday I also came up with other usefull assocations between other texts in the scene:
|
||||
<artwork><![CDATA[<John> Hey what about this: https://my.com/station.gltf#pos=0,0,1&rot=90,2,0&t=500,1000
|
||||
<Sarah> I'm checking it right now
|
||||
<Sarah> I don't see everything..where's our text from yesterday?
|
||||
<John> Ah wait, that's tagged with tag 'draft' (and hidden)..hold on, try this:
|
||||
<John> https://my.com/station.gltf#.draft&pos=0,0,1&rot=90,2,0&t=500,1000
|
||||
<Sarah> how about we link the draft to the upcoming YELLO-event?
|
||||
<John> ok I'm adding #draft@YELLO
|
||||
<Sarah> Yesterday I also came up with other usefull assocations between other texts in the scene:
|
||||
#event#YELLO
|
||||
#2025@YELLO
|
||||
<John> thanks, added.
|
||||
<Sarah> Btw. I stumbled upon this spatial book which references station.gltf in some chapters:
|
||||
<Sarah> https://thecommunity.org/forum/foo/mytrainstory.txt
|
||||
<John> interesting, I'm importing mytrainstory.txt into station.gltf
|
||||
<John> ah yes, chapter three points to trainterminal_2A in the scene, cool
|
||||
<John> thanks, added.
|
||||
<Sarah> Btw. I stumbled upon this spatial book which references station.gltf in some chapters:
|
||||
<Sarah> https://thecommunity.org/forum/foo/mytrainstory.txt
|
||||
<John> interesting, I'm importing mytrainstory.txt into station.gltf
|
||||
<John> ah yes, chapter three points to trainterminal_2A in the scene, cool
|
||||
]]>
|
||||
</artwork>
|
||||
|
||||
<section anchor="default-data-uri-mimetype"><name>Default Data URI mimetype</name>
|
||||
<t>The <tt>src</tt>-values work as expected (respecting mime-types), however:</t>
|
||||
<t>The XR Fragment specification bumps the traditional default browser-mimetype</t>
|
||||
<t>The XR Fragment specification advices to bump the traditional default browser-mimetype</t>
|
||||
<t><tt>text/plain;charset=US-ASCII</tt></t>
|
||||
<t>to a hashtagbib(tex)-friendly one:</t>
|
||||
<t><tt>text/plain;charset=utf-8;bib=^@</tt></t>
|
||||
|
@ -1110,7 +1119,7 @@ to connect text further with its environment ( setup links between textual/spati
|
|||
|
||||
<section anchor="url-and-data-uri"><name>URL and Data URI</name>
|
||||
|
||||
<artwork> +--------------------------------------------------------------+ +------------------------+
|
||||
<artwork><![CDATA[ +--------------------------------------------------------------+ +------------------------+
|
||||
| | | author.com/article.txt |
|
||||
| index.gltf | +------------------------+
|
||||
| │ | | |
|
||||
|
@ -1122,6 +1131,7 @@ to connect text further with its environment ( setup links between textual/spati
|
|||
| | +------------------------+
|
||||
| |
|
||||
+--------------------------------------------------------------+
|
||||
]]>
|
||||
</artwork>
|
||||
<t>The enduser will only see <tt>welcome human</tt> and <tt>Hello friends</tt> rendered verbatim (see mimetype).
|
||||
The beauty is that text in Data URI automatically promotes rich copy-paste (retaining metadata).
|
||||
|
@ -1133,14 +1143,14 @@ The XR Fragment-compatible browser can let the enduser access visual-meta(data)-
|
|||
<section anchor="xr-text-example-parser"><name>XR Text example parser</name>
|
||||
<t>To prime the XRWG with text from plain text <tt>src</tt>-values, here's an example XR Text (de)multiplexer in javascript (which supports inline bibs & bibtex):</t>
|
||||
|
||||
<artwork>xrtext = {
|
||||
<artwork><![CDATA[xrtext = {
|
||||
|
||||
expandBibs: (text) => {
|
||||
expandBibs: (text) => {
|
||||
let bibs = { regex: /(#[a-zA-Z0-9_+@\-]+(#)?)/g, tags: {}}
|
||||
text.replace( bibs.regex , (m,k,v) => {
|
||||
tok = m.substr(1).split("@")
|
||||
text.replace( bibs.regex , (m,k,v) => {
|
||||
tok = m.substr(1).split("@")
|
||||
match = tok.shift()
|
||||
if( tok.length ) tok.map( (t) => bibs.tags[t] = `@${t}{${match},\n}` )
|
||||
if( tok.length ) tok.map( (t) => bibs.tags[t] = `@${t}{${match},\n}` )
|
||||
else if( match.substr(-1) == '#' )
|
||||
bibs.tags[match] = `@{${match.replace(/#/,'')}}`
|
||||
else bibs.tags[match] = `@${match}{${match},\n}`
|
||||
|
@ -1148,16 +1158,16 @@ The XR Fragment-compatible browser can let the enduser access visual-meta(data)-
|
|||
return text.replace( bibs.regex, '') + Object.values(bibs.tags).join('\n')
|
||||
},
|
||||
|
||||
decode: (str) => {
|
||||
// bibtex: ↓@ ↓<tag|tag{phrase,|{ruler}> ↓property ↓end
|
||||
decode: (str) => {
|
||||
// bibtex: ↓@ ↓<tag|tag{phrase,|{ruler}> ↓property ↓end
|
||||
let pat = [ /@/, /^\S+[,{}]/, /},/, /}/ ]
|
||||
let tags = [], text='', i=0, prop=''
|
||||
let lines = xrtext.expandBibs(str).replace(/\r?\n/g,'\n').split(/\n/)
|
||||
for( let i = 0; i < lines.length && !String(lines[i]).match( /^@/ ); i++ )
|
||||
for( let i = 0; i < lines.length && !String(lines[i]).match( /^@/ ); i++ )
|
||||
text += lines[i]+'\n'
|
||||
|
||||
bibtex = lines.join('\n').substr( text.length )
|
||||
bibtex.split( pat[0] ).map( (t) => {
|
||||
bibtex.split( pat[0] ).map( (t) => {
|
||||
try{
|
||||
let v = {}
|
||||
if( !(t = t.trim()) ) return
|
||||
|
@ -1166,9 +1176,9 @@ The XR Fragment-compatible browser can let the enduser access visual-meta(data)-
|
|||
if( tag.match( /}$/ ) ) return tags.push({k: tag.replace(/}$/,''), v: {}})
|
||||
t = t.substr( tag.length )
|
||||
t.split( pat[2] )
|
||||
.map( kv => {
|
||||
if( !(kv = kv.trim()) || kv == "}" ) return
|
||||
v[ kv.match(/\s?(\S+)\s?=/)[1] ] = kv.substr( kv.indexOf("{")+1 )
|
||||
.map( kv => {
|
||||
if( !(kv = kv.trim()) || kv == "}" ) return
|
||||
v[ kv.match(/\s?(\S+)\s?=/)[1] ] = kv.substr( kv.indexOf("{")+1 )
|
||||
})
|
||||
tags.push( { k:tag, v } )
|
||||
}catch(e){ console.error(e) }
|
||||
|
@ -1176,8 +1186,8 @@ The XR Fragment-compatible browser can let the enduser access visual-meta(data)-
|
|||
return {text, tags}
|
||||
},
|
||||
|
||||
encode: (text,tags) => {
|
||||
let str = text+"\n"
|
||||
encode: (text,tags) => {
|
||||
let str = text+"\n"
|
||||
for( let i in tags ){
|
||||
let item = tags[i]
|
||||
if( item.ruler ){
|
||||
|
@ -1191,11 +1201,12 @@ The XR Fragment-compatible browser can let the enduser access visual-meta(data)-
|
|||
return str
|
||||
}
|
||||
}
|
||||
]]>
|
||||
</artwork>
|
||||
<t>The above functions (de)multiplexe text/metadata, expands bibs, (de)serialize bibtex and vice versa</t>
|
||||
<blockquote><t>above can be used as a startingpoint for LLVM's to translate/steelman to a more formal form/language.</t>
|
||||
</blockquote>
|
||||
<artwork>str = `
|
||||
<artwork><![CDATA[str = `
|
||||
hello world
|
||||
here are some hashtagbibs followed by bibtex:
|
||||
|
||||
|
@ -1208,14 +1219,15 @@ here are some hashtagbibs followed by bibtex:
|
|||
asdf = {23423}
|
||||
}`
|
||||
|
||||
var {tags,text} = xrtext.decode(str) // demultiplex text & bibtex
|
||||
tags.find( (t) => t.k == 'flap{' ).v.asdf = 1 // edit tag
|
||||
var {tags,text} = xrtext.decode(str) // demultiplex text & bibtex
|
||||
tags.find( (t) => t.k == 'flap{' ).v.asdf = 1 // edit tag
|
||||
tags.push({ k:'bar{', v:{abc:123} }) // add tag
|
||||
console.log( xrtext.encode(text,tags) ) // multiplex text & bibtex back together
|
||||
console.log( xrtext.encode(text,tags) ) // multiplex text & bibtex back together
|
||||
]]>
|
||||
</artwork>
|
||||
<t>This expands to the following (hidden by default) BibTex appendix:</t>
|
||||
|
||||
<artwork>hello world
|
||||
<artwork><![CDATA[hello world
|
||||
here are some hashtagbibs followed by bibtex:
|
||||
|
||||
@{some-section}
|
||||
|
@ -1230,6 +1242,7 @@ here are some hashtagbibs followed by bibtex:
|
|||
@bar{
|
||||
abc = {123}
|
||||
}
|
||||
]]>
|
||||
</artwork>
|
||||
<blockquote><t>when an XR browser updates the human text, a quick scan for nonmatching tags (<tt>@book{nonmatchingbook</tt> e.g.) should be performed and prompt the enduser for deleting them.</t>
|
||||
</blockquote></section>
|
||||
|
@ -1246,7 +1259,7 @@ here are some hashtagbibs followed by bibtex:
|
|||
<blockquote><t>due to the popularity, maturity and extensiveness of HTTP codes for client/server communication, non-HTTP protocols easily map to HTTP codes (ipfs ERR_NOT_FOUND maps to 404 e.g.)</t>
|
||||
</blockquote><t>For example:</t>
|
||||
|
||||
<artwork> +────────────────────────────────────────────────────────+
|
||||
<artwork><![CDATA[ +────────────────────────────────────────────────────────+
|
||||
│ │
|
||||
│ index.gltf │
|
||||
│ │ │
|
||||
|
@ -1258,13 +1271,14 @@ here are some hashtagbibs followed by bibtex:
|
|||
│ │ └ href@400: #clienterrortext │
|
||||
│ │ └ ◻ offlinetext │
|
||||
│ │ │
|
||||
│ └── ◻ embeddedObject <--------- the meshdata inside embeddedObject will (not)
|
||||
│ └── ◻ embeddedObject <--------- the meshdata inside embeddedObject will (not)
|
||||
│ └ src: https://foo.io/bar.gltf │ be flushed when the request (does not) succeed.
|
||||
│ └ src@404: http://foo.io/bar.gltf │ So worstcase the 3D data (of the time of publishing index.gltf)
|
||||
│ └ src@400: https://archive.org/l2kj43.gltf │ will be displayed.
|
||||
│ │
|
||||
+────────────────────────────────────────────────────────+
|
||||
|
||||
]]>
|
||||
</artwork>
|
||||
</section>
|
||||
|
||||
|
@ -1291,31 +1305,68 @@ To filter out non-related objects one could take it a step further using filters
|
|||
</blockquote><t>This makes spatial content multi-purpose, without the need to separate content into separate files, or show/hide things using a complex logiclayer like javascript.</t>
|
||||
</section>
|
||||
|
||||
<section anchor="security-considerations"><name>Security Considerations</name>
|
||||
<t>Since XR Text contains metadata too, the user should be able to set up tagging-rules, so the copy-paste feature can :</t>
|
||||
<section anchor="uri-templates-rfc6570"><name>URI Templates (RFC6570)</name>
|
||||
<t>XR Fragments adopts Level1 URI <strong>Fragment</strong> expansion to provide safe interactivity.<br />
|
||||
|
||||
<ul spacing="compact">
|
||||
<li>filter out sensitive data when copy/pasting (XR text with <tt>tag:secret</tt> e.g.)</li>
|
||||
</ul>
|
||||
The following demonstrates a simple video player:</t>
|
||||
|
||||
<artwork><![CDATA[
|
||||
+─────────────────────────────────────────────+
|
||||
│ │
|
||||
│ foo.usdz │
|
||||
│ │ │
|
||||
│ │ │
|
||||
│ ├── ◻ stopbutton │
|
||||
│ │ ├ #: #-stopbutton │
|
||||
│ │ └ href: #player=stop&-stopbutton │ (stop and hide stop-button)
|
||||
│ │ │
|
||||
│ └── ◻ plane │
|
||||
│ ├ play: #t=l:0,10 │
|
||||
│ ├ stop: #t=0,0 │
|
||||
│ ├ href: #player=play&stopbutton │ (play and show stop-button)
|
||||
│ └ src: cat.mp4#{player} │
|
||||
│ │
|
||||
│ │
|
||||
+─────────────────────────────────────────────+
|
||||
|
||||
|
||||
]]>
|
||||
</artwork>
|
||||
</section>
|
||||
|
||||
<section anchor="security-considerations"><name>Security Considerations</name>
|
||||
<t>The only dynamic parts are <eref target="https://www.w3.org/TR/media-frags/">W3C Media Fragments</eref> and <eref target="https://www.rfc-editor.org/rfc/rfc6570">URI Templates (RFC6570)</eref>.<br />
|
||||
|
||||
The use of URI Templates is limited to pre-defined variables and Level0 fragments-expansion only, which makes it quite safe.<br />
|
||||
|
||||
In fact, it is much safer than relying on a scripting language (javascript) which can change URN too.</t>
|
||||
</section>
|
||||
|
||||
<section anchor="faq"><name>FAQ</name>
|
||||
<t><strong>Q:</strong> Why is everything HTTP GET-based, what about POST/PUT/DELETE HATEOS<br />
|
||||
|
||||
<strong>A:</strong> Because it's out of scope: XR Fragment specifies a read-only way to surf XR documents. These things belong in the application layer (for example, an XR Hypermedia browser can decide to support POST/PUT/DELETE requests for embedded HTML thru <tt>src</tt> values)</t>
|
||||
<t><strong>Q:</strong> Why isn't there support for scripting, while we have things like WASM
|
||||
<t><strong>Q:</strong> Why isn't there support for scripting, URI Template Fragments are so limited compared to WASM & javascript
|
||||
<strong>A:</strong> This is out of scope as it unhyperifies hypermedia, and this is up to XR hypermedia browser-extensions.<br />
|
||||
Historically scripting/Javascript seems to been able to turn webpages from hypermedia documents into its opposite (hyperscripted nonhypermedia documents).<br />
|
||||
In order to prevent this backward-movement (hypermedia tends to liberate people from finnicky scripting) XR Fragments should never unhyperify itself by hardcoupling to a particular markup or scripting language. <eref target="https://xrfragment.org/doc/RFC_XR_Macros.html">XR Macro's</eref> are an example of something which is probably smarter and safer for hypermedia browsers to implement, instead of going full-in with a turing-complete scripting language (and suffer the security consequences later).<br />
|
||||
In order to prevent this backward-movement (hypermedia tends to liberate people from finnicky scripting) XR Fragment uses <eref target="https://www.w3.org/TR/media-frags/">W3C Media Fragments</eref> and <eref target="https://www.rfc-editor.org/rfc/rfc6570">URI Templates (RFC6570)</eref>, to prevent unhyperifying itself by hardcoupling to a particular markup or scripting language. <br />
|
||||
|
||||
XR Fragments supports filtering objects in a scene only, because in the history of the javascript-powered web, showing/hiding document-entities seems to be one of the most popular basic usecases.<br />
|
||||
|
||||
Doing advanced scripting & networkrequests under the hood are obviously interesting endavours, but this is something which should not be hardcoupled with hypermedia.<br />
|
||||
This belongs to browser extensions.<br />
|
||||
Doing advanced scripting & networkrequests under the hood are obviously interesting endavours, but this is something which should not be hardcoupled with XR Fragments or hypermedia.<br />
|
||||
This perhaps belongs more to browser extensions.<br />
|
||||
|
||||
Non-HTML Hypermedia browsers should make browser extensions the right place, to 'extend' experiences, in contrast to code/javascript inside hypermedia documents (this turned out as a hypermedia antipattern).</t>
|
||||
</section>
|
||||
|
||||
<section anchor="authors"><name>authors</name>
|
||||
|
||||
<ul spacing="compact">
|
||||
<li>Leon van Kammen (@lvk@mastodon.online)</li>
|
||||
<li>Jens Finkhäuser (@jens@social.finkhaeuser.de)</li>
|
||||
</ul>
|
||||
</section>
|
||||
|
||||
<section anchor="iana-considerations"><name>IANA Considerations</name>
|
||||
<t>This document has no IANA actions.</t>
|
||||
</section>
|
||||
|
@ -1373,6 +1424,11 @@ Non-HTML Hypermedia browsers should make browser extensions the right place, to
|
|||
<td>something somewhere via someprotocol (<tt>http://me.com/foo.glb</tt>)</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>URN</td>
|
||||
<td>something at some domain (<tt>me.com/foo.glb</tt>)</td>
|
||||
</tr>
|
||||
|
||||
<tr>
|
||||
<td>metadata</td>
|
||||
<td>custom properties of text, 3D Scene or Object(nodes), relevant to machines and a human minority (academics/developers)</td>
|
||||
|
|
|
@ -3,7 +3,7 @@
|
|||
|
||||
|
||||
Internet Engineering Task Force L.R. van Kammen
|
||||
Internet-Draft 5 February 2024
|
||||
Internet-Draft 8 February 2024
|
||||
Intended status: Informational
|
||||
|
||||
|
||||
|
@ -38,7 +38,7 @@ Status of This Memo
|
|||
time. It is inappropriate to use Internet-Drafts as reference
|
||||
material or to cite them other than as "work in progress."
|
||||
|
||||
This Internet-Draft will expire on 8 August 2024.
|
||||
This Internet-Draft will expire on 11 August 2024.
|
||||
|
||||
Copyright Notice
|
||||
|
||||
|
@ -53,7 +53,7 @@ Copyright Notice
|
|||
|
||||
|
||||
|
||||
van Kammen Expires 8 August 2024 [Page 1]
|
||||
van Kammen Expires 11 August 2024 [Page 1]
|
||||
|
||||
Internet-Draft XR Macros February 2024
|
||||
|
||||
|
@ -109,13 +109,13 @@ Table of Contents
|
|||
|
||||
|
||||
|
||||
van Kammen Expires 8 August 2024 [Page 2]
|
||||
van Kammen Expires 11 August 2024 [Page 2]
|
||||
|
||||
Internet-Draft XR Macros February 2024
|
||||
|
||||
|
||||
3. Metadata-values can contain the | symbol to 🎲 roundrobin
|
||||
variable values (!toggleme: fog=0,10|fog=0,1000 e.g.)
|
||||
3. Metadata-values can contain the | symbol to 🎲 roundrobin variable
|
||||
values (!toggleme: fog=0,10|fog=0,1000 e.g.)
|
||||
4. XR Macros acts as simple eventhandlers for URI Fragments: they
|
||||
are automatically published on the (XR Fragments
|
||||
(https://xrfragment.org)) hashbus, to act as events (so more
|
||||
|
@ -165,7 +165,7 @@ Internet-Draft XR Macros February 2024
|
|||
|
||||
|
||||
|
||||
van Kammen Expires 8 August 2024 [Page 3]
|
||||
van Kammen Expires 11 August 2024 [Page 3]
|
||||
|
||||
Internet-Draft XR Macros February 2024
|
||||
|
||||
|
@ -221,7 +221,7 @@ Internet-Draft XR Macros February 2024
|
|||
|
||||
|
||||
|
||||
van Kammen Expires 8 August 2024 [Page 4]
|
||||
van Kammen Expires 11 August 2024 [Page 4]
|
||||
|
||||
Internet-Draft XR Macros February 2024
|
||||
|
||||
|
@ -277,7 +277,7 @@ Internet-Draft XR Macros February 2024
|
|||
|
||||
|
||||
|
||||
van Kammen Expires 8 August 2024 [Page 5]
|
||||
van Kammen Expires 11 August 2024 [Page 5]
|
||||
|
||||
Internet-Draft XR Macros February 2024
|
||||
|
||||
|
@ -333,7 +333,7 @@ click object with (`!clickme`:`!foo|!bar|!flop` e.g.)
|
|||
|
||||
|
||||
|
||||
van Kammen Expires 8 August 2024 [Page 6]
|
||||
van Kammen Expires 11 August 2024 [Page 6]
|
||||
|
||||
Internet-Draft XR Macros February 2024
|
||||
|
||||
|
@ -375,7 +375,7 @@ Internet-Draft XR Macros February 2024
|
|||
| | (games,VR,AR e.g.), should be as high as |
|
||||
| | possible |
|
||||
+---------------+---------------------------------------------------+
|
||||
| ◻ | ascii representation of an 3D object/mesh |
|
||||
| ◻ | ascii representation of an 3D object/mesh |
|
||||
+---------------+---------------------------------------------------+
|
||||
| (un)obtrusive | obtrusive: wrapping human text/thought in |
|
||||
| | XML/HTML/JSON obfuscates human text into |
|
||||
|
@ -389,4 +389,4 @@ Internet-Draft XR Macros February 2024
|
|||
|
||||
|
||||
|
||||
van Kammen Expires 8 August 2024 [Page 7]
|
||||
van Kammen Expires 11 August 2024 [Page 7]
|
||||
|
|
|
@ -282,16 +282,17 @@ Macros also act as events, so more serious scripting languages can react to them
|
|||
<section anchor="event-bubble-flow"><name>Event Bubble-flow</name>
|
||||
<t>click object with (<tt>!clickme</tt>:<tt>AR</tt> or <tt>!clickme</tt>: <tt>!reset</tt> e.g.)</t>
|
||||
|
||||
<artwork> ◻
|
||||
<artwork><![CDATA[ ◻
|
||||
│
|
||||
└── does current object contain this property-key (`AR` or `!reset` e.g.)?
|
||||
└── no: is there any (root)object containing property `AR`
|
||||
└── yes: evaluate its (roundrobin) XR macro-value(s) (and exit)
|
||||
└── no: trigger URL: #AR
|
||||
]]>
|
||||
</artwork>
|
||||
<t>click object with (<tt>!clickme</tt>:<tt>#AR|#VR</tt> e.g.)</t>
|
||||
|
||||
<artwork> ◻
|
||||
<artwork><![CDATA[ ◻
|
||||
│
|
||||
└── apply the roundrobin (rotate the options, value `#AR` becomes `#VR` upon next click)
|
||||
└── is there any object with property-key (`#AR` e.g.)?
|
||||
|
@ -299,6 +300,7 @@ Macros also act as events, so more serious scripting languages can react to them
|
|||
└── yes: apply its value to the scene, and update the URL to `#AR`
|
||||
|
||||
click object with (`!clickme`:`!foo|!bar|!flop` e.g.)
|
||||
]]>
|
||||
</artwork>
|
||||
<t>◻
|
||||
│<br />
|
||||
|
|
42
index.html
42
index.html
File diff suppressed because one or more lines are too long
Loading…
Reference in New Issue