Add hevc.js sample for HEVC playback in browsers without native support#5028
Open
privaloops wants to merge 1 commit into
Open
Add hevc.js sample for HEVC playback in browsers without native support#5028privaloops wants to merge 1 commit into
privaloops wants to merge 1 commit into
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Per discussion in #5018, this adds a reference sample for hevc.js, an HEVC software fallback plugin for dash.js.
The sample shows how to play HEVC (H.265) DASH streams in dash.js on browsers without native HEVC support (Firefox, Chrome on Linux/Windows, etc.). The @hevcjs/dashjs-plugin package patches MSE so that HEVC samples are transcoded to H.264 inside a Web Worker (WASM H.265 decoder + WebCodecs H.264 encoder). The underlying
<video>element keeps playing a standard H.264 stream, so ABR, audio sync, and seeking all work unchanged.A new
hevc.jssection is added tosamples.json(alongside the existing LCEVC section). The sample HTML is self-contained and pulls the plugin from esm.sh (ESM, no build step) plus the WASM / Worker assets from unpkg.cc @dsilhavy