Apply uStreamer workarounds on a more granular level

Open
#802 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
2/5
Estimated time
1-3 hours
Newbie friendliness
50/100
Issue type
Feature
Clarity
Clearly specified
Activity status
Stale
Tech stack
javascript
Domain
frontend

Research direction

Start in app/templates/custom-elements/remote-screen.html, especially the remote-screen element and its current /stream?advance_headers=1 source. Add browser-based source selection matching the Firefox, Chrome, and Safari cases in the issue, then verify that each browser receives only its specified workaround.

Written by the indexing model from the issue text.

Description

enhancement medium

Several browsers have bugs that prevent them from rendering MJPEG properly, and uStreamer has two separate workarounds:

We're currently applying the advance_headers workaround regardless of what browser the user is running. We briefly added a second workaround in #796 but reverted it in #801.

We should use JavaScript to detect the client's browser and only apply the specific workaround for that browser. So we'd dynamically generate the src attribute for remote-screen <img> element depending on the browser:

Firefox

/stream (no workarounds)

Chrome

/stream?advance_headers=1

Safari

/stream?dual_final_frames=1

Dominant language
Python
Stars
3.5k
Forks
291
PR merge metrics
No merged PRs in 30d

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from tiny-pilot/tinypilot

All issues in tiny-pilot/tinypilot

Similar issues

More Python issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.