Fix XMA packet starts and final sample skips #4275

Open
github-bot wants to merge 1 commit from github-bot/gh-4274 into main AGit
Owner

@⁠invismann on GitHub · 2026-11-30 18:02 UTC · original
invismann:fix/xma-packet-playback → main · +92 −21 · 2 files · 1 commits · open

Split from #4255.

What it changes

  • Follow XMA packet skip links when a fresh input buffer starts with a continuation-only packet.
  • Apply any remaining sample skips when the decoder flushes its final overlap.

Ported from a236443f6 on cool-fox-rtx.

How it was tested

  • Before: Both XMA regressions failed on 84bd61e2c with the tests applied. The continuation case produced zero frames, and skipping five subframes left 256 samples where 128 were expected.

  • After: The Windows victory-formats XMA and victory-hle audio tests passed on this branch, including both regressions with synthetic packets. The staged asset-policy check passed.

  • Startup smoke: The combined branch in #4255 ran on Windows with an RTX 4090, Series X at 2560×1440 SDR, and DLSS, frame generation, and hardware ray tracing disabled. It reached at least 1,024 presented frames.

  • CI baseline: The workspace Clippy run on #4255 failed on existing warnings in the shader and GPU crates. CI log

Checked for overlap

  • Searched open PRs for XMA, packet continuation, final sample skips, and audio changes. Found no matching proposal.
**@⁠invismann** on GitHub · 2026-11-30 18:02 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4274) `invismann:fix/xma-packet-playback` → `main` · +92 −21 · 2 files · 1 commits · open Split from #4255. ## What it changes - Follow XMA packet skip links when a fresh input buffer starts with a continuation-only packet. - Apply any remaining sample skips when the decoder flushes its final overlap. Ported from `a236443f6` on `cool-fox-rtx`. ## How it was tested - **Before:** Both XMA regressions failed on `84bd61e2c` with the tests applied. The continuation case produced zero frames, and skipping five subframes left 256 samples where 128 were expected. - **After:** The Windows `victory-formats` XMA and `victory-hle` audio tests passed on this branch, including both regressions with synthetic packets. The staged asset-policy check passed. - **Startup smoke:** The combined branch in #4255 ran on Windows with an RTX 4090, Series X at 2560×1440 SDR, and DLSS, frame generation, and hardware ray tracing disabled. It reached at least 1,024 presented frames. - **CI baseline:** The workspace Clippy run on #4255 failed on existing warnings in the shader and GPU crates. [CI log](https://github.com/trustno1-coder/VIctory-NVIDIA/actions/runs/46477555760/job/142055706089) ## Checked for overlap - [x] Searched open PRs for XMA, packet continuation, final sample skips, and audio changes. Found no matching proposal.
Follow the stream's packet chain when the first packet only holds a
continuation. Apply remaining sample skips to the decoder's final overlap.

Ported-from: a236443f6 (cool-fox-rtx)
github-bot locked as GitHub sync and limited conversation to collaborators 2026-11-30 18:09:51 +00:00
github-bot force-pushed github-bot/gh-4274 from 1048436228 to 89d2eb173c 2026-12-01 06:09:22 +00:00 Compare
Author
Owner

@⁠Alilou92 on GitHub · 2026-12-01 18:32 UTC · original

Tested on Windows 11, Intel Core Ultra 7 265KF, RTX 5070, merged onto main 5fabb46e (no in-game test, I don't have the game).

  • cargo test -p victory-formats xma: 15 passed, 4 ignored (benchmarks and tests that need files outside the repository). Same result on Linux.
  • cargo test -p victory-hle --lib xma: 6 passed, including the two new tests and xma2_voices_play_through_the_host.
**@⁠Alilou92** on GitHub · 2026-12-01 18:32 UTC · [original](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/4274#issuecomment-7321102500) Tested on Windows 11, Intel Core Ultra 7 265KF, RTX 5070, merged onto main 5fabb46e (no in-game test, I don't have the game). - `cargo test -p victory-formats xma`: 15 passed, 4 ignored (benchmarks and tests that need files outside the repository). Same result on Linux. - `cargo test -p victory-hle --lib xma`: 6 passed, including the two new tests and `xma2_voices_play_through_the_host`. -
This pull request can be merged automatically.
This branch is out-of-date with the base branch
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin '+refs/pull/4275/head:github-bot/gh-4274'
git switch 'github-bot/gh-4274'

Merge

Merge the changes and update on Forgejo.
git switch 'main'
git merge --no-ff 'github-bot/gh-4274'
git switch 'github-bot/gh-4274'
git rebase 'main'
git switch 'main'
git merge --ff-only 'github-bot/gh-4274'
git switch 'github-bot/gh-4274'
git rebase 'main'
git switch 'main'
git merge --no-ff 'github-bot/gh-4274'
git switch 'main'
git merge --squash 'github-bot/gh-4274'
git switch 'main'
git merge --ff-only 'github-bot/gh-4274'
git switch 'main'
git merge 'github-bot/gh-4274'
git push origin 'main'
This discussion has been locked. Commenting is limited to contributors.
No reviewers
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
github/trustno1-coder--VIctory-NVIDIA!4275
No description provided.