Skip to content

fix(playback): correct Android Media3 HLS sample entries - #79

Merged
blurbery merged 1 commit into
mainfrom
fix/android-media3-hls-recipes
Aug 30, 2026
Merged

blurbery merged 1 commit into
mainfrom
fix/android-media3-hls-recipes

Conversation

@blurbery

Copy link
Copy Markdown
Owner

Problem

Related issue: N/A — narrow fix

First-party Android DV7 and DV8 HLS remux plans failed before FFmpeg started with unsupported video sample-entry recipe. The planner emitted hev1 for Android, while the initial transcode allowlist rejected it. Broadly accepting hev1 alone would still leave preserved Dolby Vision Profile 8 on the wrong sample entry.

Approach

  • Admit the protocol-v3 hev1 recipe through the initial allowlist while preserving the downstream HEVC-copy and Dolby Vision mode checks.
  • Identify first-party Android Media3 HLS through either the delivery-scoped native HLS feature or the existing platform plus device-quirks compatibility opt-in.
  • Use hvc1 for ordinary HEVC and DV7 base-layer routes, and dvh1 for preserved DV5/DV8.
  • Keep web hls.js on hev1 and preserve existing Apple native-HLS behavior.
  • Cover Android Auto, Original, and 2160p plans with DV7 and DV8 fixtures.

Validation

  • PASS: focused Android Media3 mapping and planner tests across Auto, Original, and 2160p.
  • PASS: sample-entry validation and FFmpeg argument tests for hev1, hvc1, and dvh1.
  • PASS: GitHub Actions CI run 33303879911, including Go build, gofmt, vet, changed-line lint, generated binding and fixture checks, complete Go tests, web build and tests, and docs hygiene.
  • The complete playback package could not run reliably under the local macOS process sandbox because temporary fake FFmpeg hardware probes were killed. The relevant local tests passed, and the unrestricted Linux CI package suite passed.
  • Real-device playback remains required after deployment to verify startup and smoothness on the affected Samsung phone and Android TV.

Risks

The compatibility fallback is limited to Android clients that opt into the first-party device-quirks protocol. Strict validation still prevents sample entries on encoded or non-HEVC routes and requires dvh1 for preserved Dolby Vision. Apple and web mappings have regression coverage.

AI Disclosure

  • Tool(s): OpenAI Codex desktop
  • Model(s): GPT-5
  • Involvement: AI-assisted
  • Adversarial review: An independent review inspected both server and Android diffs, traced sample-entry selection through final transcode validation, and checked Android, Apple, web, Auto, Original, and 2160p behavior. It found no blocking issue. The remaining risk is real-device acceptance and smoothness, which unit tests cannot prove.

Checklist

  • I read and can explain the complete diff.
  • This pull request addresses one concern.

@blurbery
blurbery merged commit ee0d9a8 into main Aug 30, 2026
6 checks passed
@blurbery
blurbery deleted the fix/android-media3-hls-recipes branch November 6, 2026 00:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant