web: force WebTransport-only moq-watch sessions
This commit is contained in:
parent
305ea39828
commit
66ce78e82d
2 changed files with 30 additions and 0 deletions
|
|
@ -161,6 +161,13 @@ function mountPlayer(relayUrl, name) {
|
|||
// Support both @moq/watch attribute variants across minor versions.
|
||||
watch.setAttribute("name", name);
|
||||
watch.setAttribute("path", name);
|
||||
watch.setAttribute("volume", "1");
|
||||
|
||||
// Force WebTransport in-browser; websocket fallback has shown degraded
|
||||
// media behavior (especially audio) against public relay paths.
|
||||
if (watch.connection && typeof watch.connection === "object") {
|
||||
watch.connection.websocket = { enabled: false };
|
||||
}
|
||||
|
||||
// A canvas enables video rendering. Without it, only audio is played.
|
||||
const canvas = document.createElement("canvas");
|
||||
|
|
|
|||
|
|
@ -0,0 +1,23 @@
|
|||
# ECP-0076: WebTransport-Only Browser Watcher Path
|
||||
|
||||
## Context
|
||||
|
||||
The browser watcher (`@moq/watch`) races WebTransport against WebSocket fallback by default. In production relay sessions this fallback path correlates with degraded playback behavior (frequent stream resets and unreliable audio despite active subscription).
|
||||
|
||||
## Decision
|
||||
|
||||
In `apps/web/app.js`, configure each `<moq-watch>` instance to disable WebSocket fallback before connect:
|
||||
|
||||
- `watch.connection.websocket = { enabled: false }`
|
||||
|
||||
Also set default watcher volume to full (`volume="1"`) to avoid low-volume false negatives during validation.
|
||||
|
||||
## Rationale
|
||||
|
||||
- Aligns browser transport with the intended relay mode (WebTransport MoQ).
|
||||
- Removes fallback-induced variability from live playback behavior.
|
||||
- Keeps implementation local to web app wiring without forking upstream packages.
|
||||
|
||||
## Reversibility
|
||||
|
||||
- Remove the connection override to restore default fallback behavior.
|
||||
Loading…
Add table
Add a link
Reference in a new issue