Skip to content

Image variant with H.264 and H.265 (proprietary codecs) - #17

Merged
LeeO86 merged 3 commits into
mainfrom
feat/proprietary-codecs
Nov 5, 2026
Merged

LeeO86 merged 3 commits into
mainfrom
feat/proprietary-codecs

Conversation

@LeeO86

@LeeO86 LeeO86 commented Nov 4, 2026

Copy link
Copy Markdown
Owner

The normal image uses the CEF project's build, which has only royalty-free codecs (VP8, VP9, AV1). Pages that play H.264 or H.265 stay black in it, for example the WebRTC previews of other media functions (RTCRtpReceiver.getCapabilities('video') lists no H264).

This adds an image variant, <version>-codecs, with a CEF build of the same version (144.0.21) that also decodes H.264 and H.265 in software. The function's own code is unchanged.

Licensing warning. H.264 and H.265 are covered by patents. Whoever deploys the variant is responsible for any licences that apply. The normal image stays as it is.

What changes

  • docker/Dockerfile: new ARG CEF_URL (empty = the CEF project's build, as before).
  • docker/cef-codecs/: the three Chromium patches (media HEVC, FFmpeg HEVC configuration, WebRTC H.265 software decoder) and cef.env with the URL and SHA-1 of the build.
  • .github/workflows/container-codecs.yaml: a tag codecs-<version> builds that commit with the CEF build and pushes <version>-codecs and codecs. Normal v*.*.* releases are not touched.
  • docs/proprietary-codecs.md (how it is built, what was tested), README section, CHANGELOG, tests/codecs/codecs.html.

Tested (local image from this branch with the new CEF, software rendering), tests/codecs/codecs.html: all OK.

  • canPlayType and MSE: H.264 and H.265.
  • Playback of 1280x720 H.264 and H.265, direct and through MSE.
  • WebRTC: H264 and H265 in the receive capabilities; H.264 loopback inside the page, 98 frames decoded.
  • WebRTC H.265 not tested end to end (no H.265 encoder in the build, and my GStreamer test sender did not work, also not for H.264).

Before the workflow can run, the CEF build (144 MB, SHA-1 01be7c32bca594271a83b73410ee3de607d1288e) has to be attached to a release cef-144.0.21-codecs of this repository under the name in cef.env.

🤖 Generated with Claude Code

https://claude.ai/code/session_017ybuzgBaGxuB5UiaE8dRa4

LeeO86 and others added 3 commits November 4, 2026 20:44
A second image, <version>-codecs, uses a CEF build of the same version
with H.264 and H.265 software decoding (video, MSE, WebRTC receive). The
Dockerfile takes CEF_URL; docker/cef-codecs holds the Chromium patches and
the build's URL and SHA-1; a tag codecs-<version> builds and pushes the
variant. Licensing is the user's responsibility (docs/proprietary-codecs.md).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017ybuzgBaGxuB5UiaE8dRa4
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017ybuzgBaGxuB5UiaE8dRa4
WebRTC H.265 could not be tested end to end, so the build no longer offers
it (H.265 stays for video and MSE, tested). New CEF build r2.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_017ybuzgBaGxuB5UiaE8dRa4
@LeeO86
LeeO86 merged commit d4a455f into main Nov 5, 2026
4 checks passed
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