Compare commits

...

135 Commits

Author SHA1 Message Date
Fabien Benetou ced68409da example of copy/pastying code from doc then execute 1 month ago
Fabien Benetou bc8d3af180 basic mode 1 month ago
Fabien Benetou c279afaa22 bump item up and down, clarified from ratio to step 1 month ago
Fabien Benetou 958acd82f1 moving from ondrop to onreleased, proper UUID on notes 1 month ago
Fabien Benetou 1caa31f9b7 ondrop timing fix 1 month ago
Fabien Benetou 898464c29b session Id to distinguish participants without player name 1 month ago
Fabien Benetou 20dca36947 JSON payload instead of string 2 months ago
Fabien Benetou ac4dc57975 controllers as example of Lynx initial support (via Wolvic own build) 2 months ago
Fabien Benetou 9c9dbb2527 user restart (in other language) and random targets 3 months ago
Fabien Benetou 04d78b7e47 share live event for supervisor 3 months ago
Fabien Benetou 5673d84b3d proper animations 5 months ago
Fabien Benetou fde44fc110 exercise component with animation examples 6 months ago
Fabien Benetou a758ed1b6c win condition 6 months ago
Fabien Benetou 1123a0b6ce working loader with animation and console feedback 6 months ago
Fabien Benetou 6e987e64dd example of backend code 6 months ago
Fabien Benetou 0843d858aa example of writing to glTF then loading back with interpretable code 6 months ago
Fabien Benetou 63d787dc08 animation example 6 months ago
Fabien Benetou 93c1d0ccb0 working example 6 months ago
Fabien Benetou 9dd35eb462 working example 6 months ago
Fabien Benetou 42ef7ff120 a-tube test and cleanup 6 months ago
Fabien Benetou 08084875c9 pull component with example 6 months ago
Fabien Benetou d68922c502 ice ring demo 6 months ago
Fabien Benetou d2cac98d64 bottomless examples 6 months ago
Fabien Benetou 87407c2552 cone change as core feedback mecanics 7 months ago
Fabien Benetou b741848ebb lower geomoetric complexity and faster refresh 7 months ago
Fabien Benetou 4b0026c4ec avoid cluttering 7 months ago
Fabien Benetou eeffe718f7 basic game mechanics 7 months ago
Fabien Benetou 07644a6cd1 example of state per distance 7 months ago
Fabien Benetou 4fc5891c71 playgrou 7 months ago
Fabien Benetou 8d0f5e2756 annotation as component proper 7 months ago
Fabien Benetou 63bc7a02c5 ice map and annotation 7 months ago
Fabien Benetou 3aacf514d5 example with start and end blocks 7 months ago
Fabien Benetou 7a05cb826c example 8 months ago
Fabien Benetou e3e804f30c comments on user facing and post-it drop 9 months ago
Fabien Benetou 08eb53957b add events and right angle example for post it generator 9 months ago
Fabien Benetou 23d7f935df working example of thumb/index pull 9 months ago
Fabien Benetou 6ae4f08e57 example of touching with index to change entity 11 months ago
Fabien Benetou c8b3cb5741 move hands to see the tension 11 months ago
Fabien Benetou ec3fcfe28a draw with index tip preview 12 months ago
Fabien Benetou c43df10bf5 execute graph 12 months ago
Fabien Benetou 6ad5b4c4f0 fixed on editors connections and generateGraphFromEditors() 12 months ago
Fabien Benetou 5a2794401a addConnectorsToCodeEditor() and checkConnectors() 12 months ago
Fabien Benetou 7dbeeed9fd visual basis to start 12 months ago
Fabien Benetou 4418866691 editor prevent reflow and optional width 12 months ago
Fabien Benetou 547423ce17 merging editors 12 months ago
Fabien Benetou 808a7aedc5 hide source editor, might cause pinching conflicts 12 months ago
Fabien Benetou 110282218c split on pinch 12 months ago
Fabien Benetou 4153bccc1e moved editors set 12 months ago
Fabien Benetou 4d83424052 fixed length of sections and added addCodeMultipleEditors() 12 months ago
Fabien Benetou d407058a18 horizontal split with new editors, split full lines and vertical positioning 12 months ago
Fabien Benetou bcd14747c3 bug fix on empty lines (trimmed) causing infinite loop 12 months ago
Fabien Benetou 90050fa547 fixing gutters for code, example with syntax highligting 12 months ago
Fabien Benetou 2ec6f31ac8 synax highlight example on split multiple editor 12 months ago
Fabien Benetou 5240ab9ff9 split 12 months ago
Fabien Benetou b8cdd97aac removed single line testj 12 months ago
Fabien Benetou 6f7eb6b656 caesure 12 months ago
Fabien Benetou b71562cca1 basis 12 months ago
Fabien Benetou a8c55d1e3c rough desc 12 months ago
Fabien Benetou 6b483775e8 pulling element to hand 1 year ago
Fabien Benetou ba8013a38e extending piggybacking on target 1 year ago
Fabien Benetou 0abe363450 basic principle piggybacking on wristattached component 1 year ago
Fabien Benetou 4abc5ea939 fixed wrist attachement with new hand API (1.3 to 1.4) 1 year ago
Fabien Benetou 699dbcd6b9 using the proper name from new hand tracking API for rotation 1 year ago
Fabien Benetou de5c6a41bd rotation fixed, again, somehow (does not seem stable) 1 year ago
Fabien Benetou 4cf9c0b148 optimized model, AFrame version bump with rotation fixed 1 year ago
Fabien Benetou a817d54242 modified for offline mode 1 year ago
Fabien Benetou 841980a10c bringing a-console and shiki locally to better support offline mode 1 year ago
Fabien Benetou b0dbc6579d working code editor but not yet adding text/code in place 1 year ago
Fabien Benetou ebd1fb19ea meshes with physics 1 year ago
Fabien Benetou 1b2fa784e3 directly manipulable meshes 1 year ago
Fabien Benetou f6fb9ae4d1 meshing that can be stopped, restarted and content moved 1 year ago
Fabien Benetou 3b99a58287 meshing 1 year ago
Fabien Benetou 660cacab27 broken 1 year ago
Fabien Benetou a71be51ac5 working principle of showing anchors 1 year ago
Fabien Benetou 9ea1d0a71c example of combining default behaviors 1 year ago
Fabien Benetou 59d3e0c64d scaling continuation and hotfix on refresh from wiki page (throttling) 1 year ago
Fabien Benetou f1c7815557 scaling via left pinch while holding somethinmg 1 year ago
Fabien Benetou 737f36b4e6 periodic refresh of preview image 1 year ago
Fabien Benetou d5bc01251e send and refresh perspective image 1 year ago
Fabien Benetou c9f3e9c3ec updated submit.html with iframe preview and shareable link 1 year ago
Fabien Benetou 65d15d3266 matching room as wiki pages to be able to write from submit.html and read from index.html 1 year ago
Fabien Benetou de42d9be55 rotation centered on user but resetting on new pinch 1 year ago
Fabien Benetou 704b60b293 rotation example, not ideal because not centered on user 1 year ago
Fabien Benetou 834ffb4091 coherence in directions 1 year ago
Fabien Benetou 68b8ee8136 example of faster speed 1 year ago
Fabien Benetou a0bbdcfcd6 forward and sideways 1 year ago
Fabien Benetou aae734a20c moving backward only 1 year ago
Fabien Benetou 20181ae2c1 visual grid 1 year ago
Fabien Benetou 1bb95fa69c from primitive to instance (without instancing proper) 1 year ago
Fabien Benetou 1ce813ebac moving away from text for troika-text 1 year ago
Fabien Benetou 4f72cc08be more examples of nextMovementToPoints() usage 1 year ago
Fabien Benetou 9b776462c6 fixed draw() and works with nextMovementToPoints() 1 year ago
Fabien Benetou c8e2ad2e70 fixed pointsFromMovement and added example 1 year ago
Fabien Benetou 1a7c5a8f11 a-console component for easier feedback in HMD 1 year ago
Fabien Benetou 21c74453f2 drop zone as a sphere 1 year ago
Fabien Benetou 1cb5a25bd3 points from movement 1 year ago
Fabien Benetou cdb241ac8f generalized addBlockCodeExample with position and return element 1 year ago
Fabien Benetou 5ce4daa61e generalized addBlockCodeExample with position and return element 1 year ago
Fabien Benetou 1030436f74 generalized addBlockCodeExample with position and return element 1 year ago
Fabien Benetou a28612d4b7 generalized addBlockCodeExample 1 year ago
Fabien Benetou 1f8026d89c snap ghost preview 1 year ago
Fabien Benetou 407b3b494d next pinch applied (lack of feedback is confusing) 1 year ago
Fabien Benetou b31e925156 apply modifier to class 1 year ago
Fabien Benetou 9b5058389f modifier based on ID selected from last pick 1 year ago
Fabien Benetou 0572fe7294 removeOutlineFromEntity 1 year ago
Fabien Benetou 17afdd7855 addBlockCodeExample (just text for now, no snap) 1 year ago
Fabien Benetou 0e1f297ec0 cloning primitives 1 year ago
Fabien Benetou 89ee270eec snapping sound and fixed sky 1 year ago
Fabien Benetou 3e3e6fa602 refactoring and compound example 1 year ago
Fabien Benetou e6d068922b primitives 1 year ago
Fabien Benetou e3604cc7de snapping suggestions 1 year ago
Fabien Benetou 321f47bca5 merged screenshot, snapping to 10cm (invisible) grid 1 year ago
Fabien Benetou 5dd554f8ee working 1 year ago
Fabien Benetou 73c9a94ec5 being able to dyanmically change asset kits and sequentially load and use multiples 1 year ago
Fabien Benetou a49d200684 higher and lower level asset set considerations 1 year ago
Fabien Benetou 328e6e69ec cleaned up and added shifts 1 year ago
Fabien Benetou 6f8a451b77 event working 1 year ago
Fabien Benetou d71c932e50 grid to snap as searchable datastructure 1 year ago
Fabien Benetou 3327a0e523 Tile generation and scaling 1 year ago
Fabien Benetou 108d178a7d added rotation 1 year ago
Fabien Benetou 3cf9065603 sharing between friends (but without rotation) 1 year ago
Fabien Benetou a92aa271a0 send image and models too 1 year ago
Fabien Benetou f2fbaa2b37 loadFromMastodon() 1 year ago
Fabien Benetou fab5a00f38 higher permission required to create own streams for custom collections 1 year ago
Fabien Benetou fe6383f1f6 event based loading 1 year ago
Fabien Benetou 86b4f3ed9c removed descriptive comments and used code instead with ims() shorthand 1 year ago
Fabien Benetou 1c73d4ecb0 Friends list and message displayed in 3D/XR 1 year ago
Fabien Benetou ac94b9ab3c immers deeper integration 1 year ago
Fabien Benetou 16e72b5a23 Immers setup goals 1 year ago
Fabien Benetou c212277b9a working jxr teleport example but creating bug on pinching (parent pos) 1 year ago
Fabien Benetou ce7eccd0b7 fixed sa shorthand. Example of in VR doc 1 year ago
Fabien Benetou 9b2dd9284c loadCodeFromPage() as example 1 year ago
Fabien Benetou cd56f69d58 next page working 1 year ago
Fabien Benetou 133f0b040e small cleanup 1 year ago
Fabien Benetou 6f6f764063 add page sequence 1 year ago
  1. 1786
      index.html
  2. 144
      index.js
  3. 3772
      jxr.js
  4. 28
      submit.html

File diff suppressed because it is too large Load Diff

@ -0,0 +1,144 @@
/* nodejs server to grab the current URL as tridactyl command and serve back page with content */
// mkdir tabs polydata
// autocmd TabEnter .* js fetch("http://localhost:7777/?url="+window.location.href)
// might be interesting to keep track of document.referrer too
// consider instead Firefox Account
const fs = require('fs');
const express = require('express')
const cors = require('cors')
const https = require('https')
const path = require('path')
const {execSync} = require('child_process');
const fetch = require('node-fetch');
const app = express()
app.use(cors())
app.get('/getpoly', function(req, res){
const polypath = "polydata"
const url = "https://static.poly.pizza/"
const extensions = [".glb",".webp"]
const filepath = path.join(__dirname, polypath, req.query.id+extensions[0])
if (!fs.existsSync(filepath)){
execSync("wget "+url+req.query.id+extensions[0], {cwd:path.join(__dirname,polypath)})
execSync("wget "+url+req.query.id+extensions[1], {cwd:path.join(__dirname,polypath)})
}
res.send("received");
});
app.get('/voiceinput', function(req, res){
console.log(req.query.keyword)
sseSend(req.query.keyword)
res.send("received");
});
app.get('/search', async function(req, res){
const response = await fetch('https://api.poly.pizza/v1/search/'+req.query.keyword, {
headers: {'x-auth-token': 'e821ece91d1a43c1ac70299368a72b8a'}
});
const data = await response.json();
res.json(data);
});
app.get('/cabin', function(req, res){
res.sendFile(path.join(__dirname, 'cabin.html'))
});
app.get('/', function(req, res){
res.sendFile(path.join(__dirname, 'index.html'))
});
app.get('/tabs', function(req, res){
res.json({"files":fs.readdirSync("tabs")})
});
// resulting in possibly getting /static/screens/1652811988.png
app.get('/screens', function(req, res){
res.json({"files":fs.readdirSync("screens")})
});
const container = "docker run --rm -e UID=$(id -u) -e GID=$(id -g) "
// could try losing priviledges instead, if possible
fs.watch("cabin.html", (eventType, filename) => {
if (eventType == "change") sseSend(filename+" modified")
})
// SSE to force reload client-side
var connectedClients = []
function sseSend(data){
connectedClients.map( res => {
console.log("notifying client") // seems to be call very often (might try to send to closed clients?)
res.write(`data: ${JSON.stringify({status: data})}\n\n`);
})
}
app.get('/streaming', (req, res) => {
res.setHeader('Cache-Control', 'no-cache');
res.setHeader('Content-Type', 'text/event-stream');
//res.setHeader('Access-Control-Allow-Origin', '*');
// alread handled at the nginx level
res.setHeader('Connection', 'keep-alive');
res.setHeader('X-Accel-Buffering', 'no');
res.flushHeaders(); // flush the headers to establish SSE with client
res.write(`data: ${JSON.stringify({event: "userconnect"})}\n\n`); // res.write() instead of res.send()
connectedClients.push(res)
// If client closes connection, stop sending events
res.on('close', () => {
console.log('client dropped me');
res.end();
});
});
// consider instead CloudInit so that it can be delegated to another machine
// keeping a pool of available machine would start with a single one
// namely that it is possible to run multiple containers on 1 instance, simultaneously or not.
containersSupportedByLanguage = {
bash: "debian ",
julia: "julia julia -E ",
python: "python python -c ",
// avoided file specific languages
// could be done by writing to a file in the container e.g /tmp/file.c then passing it as parameter
}
app.get('/invitereload', function(req, res){
sseSend("reload")
res.json({"res":"reload requested"})
})
app.get('/command', function(req, res){
var req = req.query.command
var foundContainer = containersSupportedByLanguage[req.split(" ")[0]]
var code = req.split(" ").slice(1).join(" ")
if (foundContainer)
res.json({"res":execSync(container+foundContainer+code).toString()})
else
res.json({"res":"language not supported"})
});
// could specify name, it then contiue instance
// ~/.openai-codex-test-xr
// potential alt backend to generate
app.get('/currenturl', function(req, res){
// could instead be the webxr page
let now = + new Date()
fs.appendFile('currentURL.txt', now+" "+req.query.url+" "+req.query.referrer+"\n", function (err) { if (err) throw err; });
// could be JSON instead
res.json({"status":"test"})
});
app.use('/static', express.static(path.join(__dirname, '.')))
// including currentURL.txt
const port = 7777
app.listen(port, () =>
console.log('listening on port', port)
);

3772
jxr.js

File diff suppressed because it is too large Load Diff

@ -18,6 +18,12 @@ Examples, tap to add, optionally modify and send :
<li><a onclick=replaceWithThisText(this)>jxr toggleVisibilityEntitiesFromClass('fot')</a></li>
</ul>
Share this URL to the browser using e.g <a id="shareablelink" href="https://hmd.link">hmd.link</a> on the same WiFi network.
<hr>
<iframe width="100%" id="pastcommands"></iframe>
<hr>
Remote preview, if available :<br/>
<img height="400px" id="remotepreview" />
<hr>
<br>
Documentation as :
@ -29,13 +35,33 @@ Documentation as :
<li>open-source <a href=https://git.benetou.fr/utopiah/text-code-xr-engine/issues>code repository</a> of the code and to make your own suggestions via issues. </li>
<li><a href=qrcode.png>QRcode</a> of this page to share with others also on mobile.</li>
<li><a href=https://fabien.benetou.fr/pub/home/future_of_text_demo/engine/?background=../content/future_of_text_symposium/HORN-2001-FutureOfHumanCognomeCL.png&fontcolor=lightgray>background</a> as URL parameter. Feel free to use your own content.</li>
<li>to create a room to work together in, add or change the ?roomname=<b>YourRoomName</b> in the browser URL
</ul>
<script>
function replaceWithThisText(element){
document.querySelector("textarea").value = element.innerText
}
const url = 'https://fabien.benetou.fr/PIMVRdata/FoT?action='
let pagename
const queryString = window.location.search
const urlParams = new URLSearchParams(queryString)
let = forcedPagename = urlParams.get('roomname')
forcedPagename?pagename=forcedPagename:pagename='FoT'
const baseURL = 'https://fabien.benetou.fr/PIMVRdata/'+pagename
const url = baseURL+'?action='
document.getElementById("pastcommands").src = baseURL+'?action=source'
document.getElementById("shareablelink").href = "https://hmd.link/?https://fabien.benetou.fr/pub/home/future_of_text_demo/engine/?roomname="+pagename
function refreshPreview(){
document.getElementById("remotepreview").src = "https://fabien.benetou.fr/uploads/PIMVRdata/"+pagename+".jpg#"+Date.now()
}
// seems to get cached properly, i.e only transferring when update
setInterval( _ => refreshPreview(), 1000)
function sendtovr(cabin){
text = document.querySelector("textarea").value
document.querySelector("textarea").value = ''

Loading…
Cancel
Save