FSR 3 frame generation: make the swap chain with FidelityFX SDK 2.3.0's DLLs too (API 3.1.7) #3728

Open
kc01-8 wants to merge 1 commit from upstream-pr/3728 into main
kc01-8 commented 2026-11-30 05:12:31 +00:00 (Migrated from github.com)

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by kc01-8 on 2026-11-30T05:12:31Z.


CI: the check job is red on main itself (84bd61e2c) with four clippy errors: loop_caps never read (victory-shader/src/emit/lower.rs), copystat::mb and Shadow::ranged never used, and a manual .is_multiple_of() in host.rs. This PR adds no clippy error and no failing test: I checked by running the workflow's steps on this PR merged into main and on main itself. Under Wine, two tests fail now and then on main as well (xmem::a_title_thread_goes_on_using_the_rest_of_a_view, crash::concurrent_crash_records_stay_together).

What: FSR 3 frame generation now also starts with FidelityFX SDK 2.3.0's DLLs. Today it doesn't.

Why:

  • fsr.rs asks FidelityFX's frame interpolation swap chain for API 4.0.0, SDK 2.4.0's version.
  • The swap chain refuses any version newer than its own with ERROR_PARAMETER before it makes anything (Fsr3FrameGenerationSwapChainParseVersion in the SDK's source).
  • SDK 2.3.0's swap chain only takes 3.1.5 to 3.1.7.
  • So anyone whose fidelityfx folder (or VICTORY_FIDELITYFX_DIR) holds 2.3.0 DLLs gets no frame generation, just the "FidelityFX did not make the swap chain" warning.
  • This isn't Linux-specific: the same DLLs fail the same way on Windows.

The change: when the swap chain refuses with ERROR_PARAMETER, it is asked once more with 3.1.7. The structures we fill in are identical between the two SDK versions. The 2.4.0 path is unchanged, and so is FSR 4's: its provider ships only in 2.4.0, so it still asks for 4.0.0 only.

Tested on an RTX 3080 Ti under Proton Experimental 11.0-20261123b, with SDK 2.3.0's signed DLLs (loader 2.3.0.2740, frame generation 4.0.1.2740).

  • A test program doing what fsr.rs does:
    • API 4.0.0: the swap chain is refused with ERROR_PARAMETER, and nothing is made.
    • API 3.1.7: the swap chain (provider 3.1.7) and the frame generation context (provider 3.1.6, frame generation API 4.0.2 accepted) are made.
  • A full run in the VIctoryNVIDIALINUX fork with this change: frame generation on for every present from the first DLSS frame, no prepare failures. The swap chain's present count shows twice the rendered frames (292 shown in 10.5 s, 146 of them generated).
  • This tree: cargo clippy -p victory-gpu clean, and the streamline:: unit tests pass under Wine.

Context: this came out of getting the title running at speed on an RTX 30 card under Linux/Proton, https://github.com/kc01-8/VIctoryNVIDIALINUX (branch kc/foxhound). There the patched wineserver (ValveSoftware/wine#384) took the opening's slow minutes from 1–4 fps to 9–16. With DLSS performance and FSR 3 frame generation, play renders at 16.7–18.3 fps and shows about twice that.

🤖 Generated with Claude Code

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:issue:5559413638 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/pull/3728). Originally posted by [kc01-8](https://github.com/kc01-8) on 2026-11-30T05:12:31Z. --- **CI:** the `check` job is red on `main` itself (84bd61e2c) with four clippy errors: `loop_caps` never read (`victory-shader/src/emit/lower.rs`), `copystat::mb` and `Shadow::ranged` never used, and a manual `.is_multiple_of()` in `host.rs`. This PR adds no clippy error and no failing test: I checked by running the workflow's steps on this PR merged into `main` and on `main` itself. Under Wine, two tests fail now and then on `main` as well (`xmem::a_title_thread_goes_on_using_the_rest_of_a_view`, `crash::concurrent_crash_records_stay_together`). **What:** FSR 3 frame generation now also starts with FidelityFX SDK 2.3.0's DLLs. Today it doesn't. **Why:** - `fsr.rs` asks FidelityFX's frame interpolation swap chain for API 4.0.0, SDK 2.4.0's version. - The swap chain refuses any version newer than its own with `ERROR_PARAMETER` before it makes anything (`Fsr3FrameGenerationSwapChainParseVersion` in the SDK's source). - SDK 2.3.0's swap chain only takes 3.1.5 to 3.1.7. - So anyone whose `fidelityfx` folder (or `VICTORY_FIDELITYFX_DIR`) holds 2.3.0 DLLs gets no frame generation, just the "FidelityFX did not make the swap chain" warning. - This isn't Linux-specific: the same DLLs fail the same way on Windows. **The change:** when the swap chain refuses with `ERROR_PARAMETER`, it is asked once more with 3.1.7. The structures we fill in are identical between the two SDK versions. The 2.4.0 path is unchanged, and so is FSR 4's: its provider ships only in 2.4.0, so it still asks for 4.0.0 only. **Tested** on an RTX 3080 Ti under Proton Experimental 11.0-20261123b, with SDK 2.3.0's signed DLLs (loader 2.3.0.2740, frame generation 4.0.1.2740). - A test program doing what `fsr.rs` does: - API 4.0.0: the swap chain is refused with `ERROR_PARAMETER`, and nothing is made. - API 3.1.7: the swap chain (provider 3.1.7) and the frame generation context (provider 3.1.6, frame generation API 4.0.2 accepted) are made. - A full run in the VIctoryNVIDIALINUX fork with this change: frame generation on for every present from the first DLSS frame, no prepare failures. The swap chain's present count shows twice the rendered frames (292 shown in 10.5 s, 146 of them generated). - This tree: `cargo clippy -p victory-gpu` clean, and the `streamline::` unit tests pass under Wine. Context: this came out of getting the title running at speed on an RTX 30 card under Linux/Proton, https://github.com/kc01-8/VIctoryNVIDIALINUX (branch `kc/foxhound`). There the patched wineserver (ValveSoftware/wine#384) took the opening's slow minutes from 1–4 fps to 9–16. With DLSS performance and FSR 3 frame generation, play renders at 16.7–18.3 fps and shows about twice that. 🤖 Generated with [Claude Code](https://claude.com/claude-code)
This pull request cannot be merged automatically due to conflicts.
Merge manually to resolve the conflicts.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u origin 'upstream-pr/3728:upstream-pr/3728'
git switch 'upstream-pr/3728'

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch 'main'
git merge --no-ff 'upstream-pr/3728'
git switch 'upstream-pr/3728'
git rebase 'main'
git switch 'main'
git merge --ff-only 'upstream-pr/3728'
git switch 'upstream-pr/3728'
git rebase 'main'
git switch 'main'
git merge --no-ff 'upstream-pr/3728'
git switch 'main'
git merge --squash 'upstream-pr/3728'
git switch 'main'
git merge --ff-only 'upstream-pr/3728'
git switch 'main'
git merge 'upstream-pr/3728'
git push origin 'main'
Sign in to join this conversation.
No reviewers
No labels
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.

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