c-frame / aframe-gltf-model-plus

gltf-model-plus component to load glb file with hubs extensions
https://c-frame.github.io/aframe-gltf-model-plus/
Mozilla Public License 2.0
10 stars 4 forks source link

Easily run a multi-users experience up to 30 users from a GitHub repo #28

Open vincentfretin opened 2 months ago

vincentfretin commented 2 months ago

Easily load a hubs scene stored on a public repo on https://allocola.com to have the UI, realistic avatars, audio, camera and screen share with the janus sfu, up to 10 users for my $10/month sponsors. See my comment about sponsorship and shared server https://github.com/c-frame/aframe-gltf-model-plus/issues/5#issuecomment-2002386160

The idea is to have the following url working https://allocola.com/gh/username/repo

For example with the outdoor festival scene stored in this repo https://github.com/c-frame/outdoor-festival with the elements.json file at the root of the repository referencing the scene glb and extras aframe entities to create (documentation), the url would be https://allocola.com/gh/c-frame/outdoor-festival and jsdelivr cdn would be used to get the assets from the github repository (I commented about it in #18)

You can also force the experience to be run as solo user, it's an option in the json configuration.

jywarren commented 2 months ago

I think i remember you mentioning possibly a p2p solution for a smaller # of users. I've used PeerJS before for realtime server-less multiplayer. Is this issue for a more complex setup? Thank you, exciting!

vincentfretin commented 2 months ago

Yes it's for running an experience on my hosting platform with a bigger number of users and additional features. For a small number of users, you can run it on glitch, I made two examples https://github.com/networked-aframe/naf-nametag-solidjs with basic sphere avatars, chat and audio and https://github.com/networked-aframe/naf-valid-avatars with realistic avatars but no chat and audio, but you can easily add the code for it by comparing the two repositories. Those examples and this repo were code I wrote for my platform that host several customer projects I did, that I open sourced to reusable components. For the UI part, I'm searching a good way to implement reusable components, see the issue https://github.com/networked-aframe/networked-aframe/issues/423

vincentfretin commented 2 months ago

So yeah for glitch, it's using a nodejs process that run easyrtc to do p2p webrtc connection to support audio and video.

My platform is using janus sfu, meaning you send your voice and video only once to the server and it is then broadcasted to the other participants in the room.

With easyrtc, you upload you audio/video n times, to each participant, that's why it doesn't scale well, generally you have issues around 8 users because you don't have the bandwidth to upload so many data.

jywarren commented 1 month ago

Oh wow that's amazing. I would have been fine using Zoom for audio/video and just having synchronous avatar movement in the space, but this is great to hear. Ty!