-<p>You wouldn't pay for 4K Netflix and...</p><p><a href=https://www.da.vidbuchanan.co.uk/blog/netflix-on-asahi.html>Source: David Buchanan, The Quest for Netflix on Asahi Linux</a></p></figcaption></figure><h2 id=openh264---lawyers-love-this-one-h264-trick>OpenH264 - Lawyers love this one H.264 trick</h2><p>In tangentially related news, certain moving picture compression standards (e.g. H.264/H.265) are encumbered with vociferously defended patents, so Fedora cannot legally ship them. marcan takes pride in Asahi’s seamless out-of-the-box experience, and H.264 being video people’s JPEG or the “fallback codec”, out-of-the-box H.264 support was imperative. Fedora does support H.264 via OpenH264 from Cisco, which is an open source H.264 implementation that is distributed as a pre-compiled binary. Cisco Systems covers the appropriate licensing royalties, as long as the binary is downloaded and installed directly from their repository. Traditionally, this means that users have had to manually install OpenH264 after installing Fedora Linux.</p><p>Since our Asahi Linux installer happens to install directly from the Internet anyway, we added support for pre-downloading these codec packages directly from Cisco’s servers as part of the installation process. A little script then takes care of immediately installing them on first boot, and the result is that Fedora Asahi Remix is the first Fedora spin to ship with H.264 straight out of the box, fully lawyer-approved.</p><p>Users who wish to use other patent-encumbered codecs under their own resposibility may choose to install them from third-party repositories, such as the <code>libavcodec-freeworld</code> package in <a href=https://docs.fedoraproject.org/en-US/quick-docs/rpmfusion-setup/>RPM Fusion</a>. Note that RPM Fusion is not affiliated with Fedora nor Asahi Linux.</p><h1 id=work-in-progress>Work In Progress…</h1><p>Now for some tricks we have up our sleeves. These may or may not arrive sometime in 2024.</p><h2 id=hardware-video-decode>Hardware Video Decode</h2><p>OpenH264 may decode H.264 by definition, but it cannot decode H.265/HEVC, which is basically H.264 cranked up including the licensing part. OpenH264 could also be faster: it has very little SIMD code, and even less ARM64 SIMD (Janne would know..). The release of speaker support has heightened the need for fast, high-quality, and power-efficent video decoding. While software decode on the M-series cores is faster than some hardware decoders, some users report their laptop battery converts to released heat at a noticeably faster rate than macOS. We want to at least match macOS efficiency numbers.</p><p>The Apple Video Decoder is a multiformat programmable hardware driven by a custom instruction set specialized for decoding video. AVD, despite its complexity, oddly enough lacks a firmware handling the low-level decode logic, so we have to RE literally every bit ourselves (side effect, the entire driver/firmware stack will be fully open-source). And video codec standards being 880-page manual beasts, it’s not the easiest effort. Eileen’s <a href=https://github.com/eiln/avd>avd repo</a> currently boasts H.264 High Profile, High 4:2:2 Profile, High 10 Profile, and High 10 4:2:2 Profile, so that beats openh264 in features alone. HEVC is nearing conformancy. A VP9 proof-of-concept exists.</p><figure class=captioned>
0 commit comments