Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 5 additions & 6 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 3 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ default-members = [
"rs/moq-transcode",
"rs/moq-uring",
"rs/moq-v4l",
"rs/moq-vaapi",
"rs/moq-video",
"rs/moq-webrtc",
"rs/qmux",
Expand Down Expand Up @@ -172,9 +173,9 @@ moq-uring = { version = "0.0.12", path = "rs/moq-uring", default-features = fals
# `capture` and `v4l2` need no libclang or kernel headers. Linux only; an empty
# stub elsewhere.
moq-v4l = { version = "0.1.0", path = "rs/moq-v4l" }
# Standalone crate (moq-dev/vaapi); vendored from cros-libva + cros-codecs.
# In-tree fork of cros-libva + cros-codecs with the libva bindings checked in.
# dlopen's libva at runtime (no libva-dev at build, no NEEDED libva in the binary).
moq-vaapi = "0.2.0"
moq-vaapi = { version = "0.2.1", path = "rs/moq-vaapi" }
# `default-features = false` is here for `capture` (V4L2, libclang), which the
# cross-compiled Python, Swift, Kotlin, and Go builds have no use for: adding
# `features = ["capture"]` to a consumer that ships in those bindings pulls the
Expand Down
1 change: 1 addition & 0 deletions doc/lib/rs/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ missing required CPU feature before starting transport cryptography.
| [moq-archive](https://docs.rs/moq-archive) | [Record and serve broadcasts](/concept/archives) on any `object_store` backend. |
| [moq-video](/lib/rs/moq-video) | Native capture, hardware encode/decode (Apple, Windows, NVIDIA, VAAPI, V4L2, Android), and GPU rendering. |
| [moq-v4l](https://docs.rs/moq-v4l) | Safe Video4Linux 2 bindings. |
| [moq-vaapi](https://docs.rs/moq-vaapi) | VA-API H.264 and H.265 hardware encode and decode, loading libva at runtime. |
| [moq-audio](/lib/rs/moq-audio) | Microphone and speaker, Opus/PCM/AAC codecs, echo cancellation. |
| [moq-transcode](https://docs.rs/moq-transcode) | Just-in-time rendition ladders, GPU-resident on NVIDIA. |
| [moq-auth](/lib/rs/moq-auth) | Relay authorization: JWT signing and verification, and the auth server contract. |
Expand Down
1 change: 0 additions & 1 deletion quest/m1/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@ moves what remains of them once their claims merge.
- [Push-to-talk's press-to-audible latency fits a budget on the defaults](/quest/m1/push-to-talk-latency.md) - press to audible on the browser defaults, excluding device output, stays under a kixtop-measured budget that `just test push-to-talk` enforces
- [TS fidelity and recovery](/quest/m1/ts-reliability/README.md) - both modes have explicit profiles, automated validation, loss tests, and a dedicated guide
- [MoQ on rind](/quest/m1/rind/README.md) - every MoQ crate takes its crypto from rind, a pure-Rust graviola fork, so no build compiles C crypto
- [VA-API encode is correct on radeonsi](/quest/m1/vaapi-radeonsi.md) - AMD's VA-API H.264 encode decodes, once moq takes moq-vaapi 0.2.1
- [Tests run on a mocked clock](/quest/m1/mock-clock-tests/README.md) - about 300 tests stop proving nothing happened by waiting, sleeping to settle, or asserting on elapsed time
- [moq-mux reads only the base layer's H.265 SPS](/quest/m1/h265-base-layer-sps.md) - a layered MV-HEVC or SHVC stream imports as its base layer instead of misreading an enhancement-layer SPS, which still reaches the track
- [A cancelled dispatch lane stops its phase promptly](/quest/m1/dispatch-cancel-race.md) - a TERM landing just before a lane forks its phase's command still stops that command, instead of waiting out the phase
Expand Down
39 changes: 0 additions & 39 deletions quest/m1/vaapi-radeonsi.md

This file was deleted.

3 changes: 1 addition & 2 deletions quest/m3/audit-deps.md
Original file line number Diff line number Diff line change
Expand Up @@ -124,8 +124,7 @@ Most duplicates still come from upstream ecosystem transitions: RustCrypto's
older generation through rsa/jsonwebtoken/STUN/SRT; retina's h264-reader 0.8
and bitstream-io 2; srt-tokio's older rand/socket2/derive_more; rustls-acme's
rcgen 0.13 and web client; winit's older platform stack; and libspa's
system-deps 7 beside GStreamer's 9. moq-vaapi still holds bindgen 0.70,
libloading 0.8 and thiserror 1; mp4-atom also holds thiserror 1. Do not treat
system-deps 7 beside GStreamer's 9. mp4-atom still holds thiserror 1. Do not treat
all 117 extras as locally removable without checking those consumers.

Bun's same-major duplicates can persist until a parent re-resolves.
Expand Down
4 changes: 1 addition & 3 deletions quest/m3/h265-min-width.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,7 @@ is 320 wide for a 4:3 source), and a failed rung probe must fail only that
rung: today `Pipeline::new` propagates it and aborts the whole transcode.

Decided 2026-11-06 (maintainer, /quest-unblock): ✅ an S quest in m3. Not
chosen: folding it into [the radeonsi quest](/quest/m1/vaapi-radeonsi.md),
or dropping it.
chosen: folding it into the radeonsi quest (since completed), or dropping it.

Decided 2026-11-07 (maintainer, /quest-complete): ✅ narrowed to the
capture encode (`moq import capture --codec h265`), an S in m3, with H.265
Expand All @@ -43,5 +42,4 @@ none.

## Related

- [VA-API encode is correct on radeonsi](/quest/m1/vaapi-radeonsi.md) - the same AMD hardware run
- [Vulkan Video encode on AMD](/quest/m3/vulkan-encode.md) - may report a different minimum
4 changes: 2 additions & 2 deletions quest/m3/vendor-sync/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
## Goal

Once per release cycle, every library vendored into moq-dev/moq, plus
moq-dev/vaapi and the UniFFI generator forks, is compared against its upstream
the UniFFI generator forks, is compared against its upstream
from the last checked commit. Useful fixes and features are ported or planned,
each library records the newest upstream commit checked, and code vendored
since the last run gets its own child.
Expand Down Expand Up @@ -76,7 +76,7 @@ behavior follows quinn's fixes.
- [moq-rtmp's rml has every upstream fix it needs](/quest/m3/vendor-sync/rml.md) - rust-media-libs fixes to rml_rtmp and rml_amf0 are ported or ruled out
- [moq-v4l has every libv4l-rs fix it needs](/quest/m3/vendor-sync/v4l.md) - libv4l-rs fixes are ported or ruled out
- [moq-nvenc has every upstream fix it needs](/quest/m3/vendor-sync/nvenc.md) - nvidia-video-codec-sdk fixes and NVIDIA SDK releases are ported or ruled out
- [moq-vaapi has every ChromeOS fix it needs](/quest/m3/vendor-sync/vaapi.md) - cros-libva and cros-codecs fixes are ported, released, and adopted
- [moq-vaapi has every ChromeOS fix it needs](/quest/m3/vendor-sync/vaapi.md) - cros-libva and cros-codecs fixes are ported or ruled out
- [UniFFI generator forks are current](/quest/m3/vendor-sync/uniffi.md) - the four `kixelated/uniffi-*` forks carry the upstream fixes moq's bindings need

## Related
Expand Down
35 changes: 8 additions & 27 deletions quest/m3/vendor-sync/vaapi.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,41 +2,22 @@

## Goal

[moq-dev/vaapi](https://github.com/moq-dev/vaapi) carries every fix that
`rs/moq-vaapi` carries every fix that
[chromeos/cros-libva](https://github.com/chromeos/cros-libva) and
[chromeos/cros-codecs](https://github.com/chromeos/cros-codecs) have landed
since the last check, for the code it vendors, each ported with its test or
recorded as not applying, and released to crates.io if anything changed, with
moq's `moq-vaapi` dependency bumped to that release.
recorded as not applying.

## Plan

Recurring child of the [vendor sync](/quest/m3/vendor-sync/README.md), which
says how each run works and recurs. moq-vaapi lives in its own repository and
ships from crates.io for build reasons; its README's `Upstream` section is the
record.
says how each run works and recurs. The crate's README `Upstream` section is
the record: the Discord baselines it forked from, the ChromeOS heads last
checked, and what was ruled out. Track the ChromeOS default branches against
those diverged baselines, without undoing Discord's additions.

moq-vaapi vendors Discord's forks: cros-libva branch `discord-0.0.13`
([`896a248e`](https://github.com/discord/cros-libva/commit/896a248e003caae7a7120812f7eaa423c93a920d))
and cros-codecs branch `discord-0.0.5`
([`9cdecb19`](https://github.com/discord/cros-codecs/commit/9cdecb192ee3682950d02bd80a7f106163531b76)).
Track the ChromeOS default branches against these diverged baselines, without
undoing Discord's additions.

Last checked (2026-10-31), per [moq-vaapi 0.1.1's Upstream
audit](https://github.com/moq-dev/vaapi/blob/v0.1.1/README.md#upstream):
cros-libva through
[`59384456`](https://github.com/chromeos/cros-libva/commit/59384456ac2ae78c0c3e5515f41ef1efd9b802cf)
and cros-codecs through
[`a050c6cd`](https://github.com/chromeos/cros-codecs/commit/a050c6cde530e563197ee9e3e72ab01f48a0c41f).
That cycle ported the `log/release_max_level_debug` removal
([moq-dev/vaapi#5](https://github.com/moq-dev/vaapi/pull/5)), made the repo's
CI read-only ([moq-dev/vaapi#6](https://github.com/moq-dev/vaapi/pull/6)),
and moq adopted `moq-vaapi 0.1.1`. Ruled out: protected-content headers and
borrowed input buffers have no consumer; the VP9 wrapper already zero-fills
libva 2.23's fields. Advisory checks cover both ChromeOS repositories, both
Discord forks, and the global Rust advisories for `cros-libva` and
`cros-codecs`.
The crate moved in-tree from moq-dev/vaapi after its 0.2.1 release; the
previous cycle's audit lives in that README unchanged.

## Required

Expand Down
13 changes: 13 additions & 0 deletions rs/moq-vaapi/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Changelog

All notable changes to this project will be documented in this file.

The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased]

### Changed

- Moved into [moq-dev/moq](https://github.com/moq-dev/moq) from [moq-dev/vaapi](https://github.com/moq-dev/vaapi), whose history covers 0.2.1 and earlier.
- Logs through `tracing` instead of `log`.
31 changes: 31 additions & 0 deletions rs/moq-vaapi/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
[package]
name = "moq-vaapi"
version = "0.2.1"
edition = "2021"
license = "BSD-3-Clause"
rust-version.workspace = true

description = "(AI GENERATED) VA-API H.264/H.265 hardware encoder and decoder, forked from discord/cros-libva and discord/cros-codecs with libva dlopen'd at runtime"
authors = ["The ChromiumOS Authors", "Discord", "Luke Curley <kixelated@gmail.com>"]
repository = "https://github.com/moq-dev/moq"
readme = "README.md"

keywords = ["vaapi", "h264", "encoder", "decoder", "hardware"]
categories = ["multimedia::encoding", "hardware-support", "external-ffi-bindings"]

# Only bindgen.sh reads the headers; the bindings it generates are checked in.
exclude = ["bindgen.sh", "libva/", "libva-wrapper.h"]

[dependencies]
anyhow = { workspace = true }
bitflags = { workspace = true }
# dlopen libva at runtime: the bindings' `Va` struct is built on libloading.
libloading = { workspace = true }
thiserror = { workspace = true }
tracing = { workspace = true }

[dev-dependencies]
workspace-hack = { path = "../workspace-hack" }

[lints]
workspace = true
26 changes: 26 additions & 0 deletions rs/moq-vaapi/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
Copyright 2022 The ChromiumOS Authors

Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:

1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.

2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.

3. Neither the name of the copyright holder nor the names of its contributors
may be used to endorse or promote products derived from this software without
specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26 changes: 26 additions & 0 deletions rs/moq-vaapi/LICENSE.cros-codecs
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
Copyright 2022 The ChromiumOS Authors

Redistribution and use in source and binary forms, with or without modification,
are permitted provided that the following conditions are met:

1. Redistributions of source code must retain the above copyright notice, this
list of conditions and the following disclaimer.

2. Redistributions in binary form must reproduce the above copyright notice,
this list of conditions and the following disclaimer in the documentation
and/or other materials provided with the distribution.

3. Neither the name of the copyright holder nor the names of its contributors
may be used to endorse or promote products derived from this software without
specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
19 changes: 19 additions & 0 deletions rs/moq-vaapi/LICENSE.libva
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
Permission is hereby granted, free of charge, to any person obtaining a
copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sub license, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:

The above copyright notice and this permission notice (including the
next paragraph) shall be included in all copies or substantial portions
of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT.
IN NO EVENT SHALL PRECISION INSIGHT AND/OR ITS SUPPLIERS BE LIABLE FOR
ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
5 changes: 5 additions & 0 deletions rs/moq-vaapi/MIGRATE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# Migrating moq-vaapi

How to update your code for each breaking change, newest first.

## Unreleased
Loading
Loading