Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use WebTransport instead of WebSocket #107

Open
Zubnix opened this issue Oct 18, 2022 · 5 comments
Open

Use WebTransport instead of WebSocket #107

Zubnix opened this issue Oct 18, 2022 · 5 comments
Assignees
Labels

Comments

@Zubnix
Copy link
Collaborator

Zubnix commented Oct 18, 2022

Compositor-proxy currently uses WebSockets to communicate application [video] frame data. This has well known drawbacks for use in real-time communication as it's essentially a TCP connection. Instead we should use WebTransport which offers UDP semantics which is far better suited for real-time communication.

Initial preparing work has already been completed by switching to the uwebsocketjs library which will eventually support WebTransport

@ehfd
Copy link

ehfd commented Oct 18, 2022

Thanks for the information! Looking forward for its maturation.

@Zubnix
Copy link
Collaborator Author

Zubnix commented Mar 16, 2023

fyi webrtc data-channels have been implemented and subsequently dropped for being too slow because of the SCTP congestion control overhead. That is, on a 300Mbit connection with zero packet loss, you'd get 30Mbit throughput which is unacceptably slow.

So we patiently await the support and arrival of WebTransport.

@ehfd
Copy link

ehfd commented Aug 4, 2023

https://caniuse.com/webtransport

https://caniuse.com/webcodecs

All major browsers other than Safari now support WebTransport. Firefox is working on WebCodecs.

@ehfd
Copy link

ehfd commented Nov 11, 2023

selkies-project/selkies-gstreamer#48 (comment)

We've been investigating WebTransport but there are a few catches outlined above (requiring valid HTTPS certificates and other issues).

But overall, the web browser stack is ready.

More references:
https://gitlab.freedesktop.org/gstreamer/gstreamer/-/issues/1571
https://github.com/kixelated/moq-rs
https://github.com/wanjohiryan/warp
https://github.com/wanjohiryan/Arc3dia

@ehfd
Copy link

ehfd commented Nov 11, 2023

fyi webrtc data-channels have been implemented and subsequently dropped for being too slow because of the SCTP congestion control overhead. That is, on a 300Mbit connection with zero packet loss, you'd get 30Mbit throughput which is unacceptably slow.

We (https://github.com/selkies-project/selkies-gstreamer) use WebRTC DataChannels for passing user input and clipboard, and use the native WebRTC MediaStreams for video and video. It's relatively inflexible but more usable than using DataChannels for everything.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
Greenfield development
  
Awaiting triage
Development

No branches or pull requests

2 participants