fix(game): blend foliage impostor views on the performance path #2736

Merged
HumanBean merged 2 commits from jackkenney/Longshot:fix/blend-performance-foliage into main 2026-11-28 19:00:19 +00:00
Contributor

Summary

Stand still in the Graveyard and look up at a tree against the sky. Above the 30 FPS mode, whole clusters of leaves can change outline in a single frame as the branches sway. Kokiri Forest and Hyrule Field show the same flicker.

The performance path forces the foliage shader to finish each transition between atlas views immediately. The hook in game/oot_sites.c restores the scene's choice for that one flag before the game selects its quality settings. A scene can still explicitly request an immediate transition. Otherwise the shader advances the fade at the actual frame rate.

Testing

Tested: The player confirmed the fix in Hyrule Field, the Graveyard, and Kokiri Forest. They also saw an improvement in other Hyrule Field foliage. Its cause is unconfirmed.

Compared stock nightly 895 and the patched build at the same stationary Graveyard camera on Windows, Vulkan, RTX 5070 Ti, driver 621.24, frame generation off. Tested 60 FPS and uncapped at 4K and uncapped at 720p. A separate nightly 876 test covered the original 30 FPS fade and a map transition. The game-free regression detects a forced reset and checks that explicit scene resets and the other performance flags survive.

The changed C translation unit compiled to Windows x64 and Linux x64 objects from a UTF-8 path. Lint passed. The full strict Linux suite had 863 passes, 16 failures, and 10 platform skips. All 16 failures also reproduced on untouched 22d0d200. The failing checks were:

test_bug_report.py, test_control_picture.py, test_crash_record.py, test_framegen_hdr.py, test_framegen_resources.py, test_guest_holes.py, test_input_background.py, test_lifter.py, test_log_open_failure.py, test_perf_send.py, test_pipeline_tour.py, test_present_source_crop.py, test_screensaver.py, test_switch_table.py, test_temporal_present_bandwidth.py, test_xinput_thread.py.

Still to test:

  • By hand on AMD or Intel Vulkan hardware: hold the camera still on a silhouetted Graveyard canopy above 30 FPS and check that leaf clusters blend as the branches sway.

Measurements

Verdict: The abrupt outline changes largely disappear. In the nightly 876 diagnostic A/B at 60 FPS, a single cluster switched abruptly 11 times stock, zero with the flag corrected, then nine with stock behavior restored.

For nightly 895, each 12-second recording used the same camera position and normal game colors. The table counts sampled video frames with a large single-step luminance change along the canopy against the sky. The measure includes normal wind motion. Each clip contributed 357 samples. Uncapped, both builds ran around 76–77 FPS at 4K and 138–140 FPS at 720p.

Frames with a large canopy change Before: main @ 22d0d200 After: this PR @ 5a3a365
4K, 60 FPS 38 0
4K, uncapped 25 3
720p, uncapped 54 0

Risks

Foliage sharing this flag can spend longer drawing its existing transition when the atlas view changes. The fix has no frame-rate threshold or tuning constant. Reverting the hook restores the game's original performance-mode behavior. The separately reported traversal stutter in #2285 has a different reproduction.

Checklist

Ready for review

  • One topic, on current main; the title is a Conventional Commit.
  • Tested on my own PC, in the game for a change the game runs, as Testing says.
  • mise run test passes (any failure that also fails on main is named).
  • Measured against main, or Measurements says why there is nothing to measure.
  • No game files, build output or hand-edited generated files; third_party/ untouched; nothing GPL-incompatible.

When it applies

  • A fix: a game-free test that fails on main and passes here.
  • A check under tests/ that reads changed source is updated, not weakened.
  • Host code builds on Windows (llvm-mingw) and Linux, with UTF-8 paths.
  • Screenshots of the same spot on main and here, for a change that shows on screen.
  • AI assistance recorded with Assisted-by: / Co-Authored-By: trailers.

Ready to merge

  • Everything in Still to test has run, its results in Tested.
  • Tier 1 hardware it can affect is tested (docs/dev/standards.md, "Hardware tiers").
  • Approved in review, every comment answered.
  • CI passes on the head; on current main, measured again or a comment says why the numbers still hold.
## Summary Stand still in the Graveyard and look up at a tree against the sky. Above the 30 FPS mode, whole clusters of leaves can change outline in a single frame as the branches sway. Kokiri Forest and Hyrule Field show the same flicker. The performance path forces the foliage shader to finish each transition between atlas views immediately. The hook in `game/oot_sites.c` restores the scene's choice for that one flag before the game selects its quality settings. A scene can still explicitly request an immediate transition. Otherwise the shader advances the fade at the actual frame rate. ## Testing **Tested:** The player confirmed the fix in Hyrule Field, the Graveyard, and Kokiri Forest. They also saw an improvement in other Hyrule Field foliage. Its cause is unconfirmed. Compared stock nightly 895 and the patched build at the same stationary Graveyard camera on Windows, Vulkan, RTX 5070 Ti, driver 621.24, frame generation off. Tested 60 FPS and uncapped at 4K and uncapped at 720p. A separate nightly 876 test covered the original 30 FPS fade and a map transition. The game-free regression detects a forced reset and checks that explicit scene resets and the other performance flags survive. The changed C translation unit compiled to Windows x64 and Linux x64 objects from a UTF-8 path. Lint passed. The full strict Linux suite had 863 passes, 16 failures, and 10 platform skips. All 16 failures also reproduced on untouched `22d0d200`. The failing checks were: `test_bug_report.py`, `test_control_picture.py`, `test_crash_record.py`, `test_framegen_hdr.py`, `test_framegen_resources.py`, `test_guest_holes.py`, `test_input_background.py`, `test_lifter.py`, `test_log_open_failure.py`, `test_perf_send.py`, `test_pipeline_tour.py`, `test_present_source_crop.py`, `test_screensaver.py`, `test_switch_table.py`, `test_temporal_present_bandwidth.py`, `test_xinput_thread.py`. **Still to test:** - By hand on AMD or Intel Vulkan hardware: hold the camera still on a silhouetted Graveyard canopy above 30 FPS and check that leaf clusters blend as the branches sway. ## Measurements **Verdict:** The abrupt outline changes largely disappear. In the nightly 876 diagnostic A/B at 60 FPS, a single cluster switched abruptly 11 times stock, zero with the flag corrected, then nine with stock behavior restored. For nightly 895, each 12-second recording used the same camera position and normal game colors. The table counts sampled video frames with a large single-step luminance change along the canopy against the sky. The measure includes normal wind motion. Each clip contributed 357 samples. Uncapped, both builds ran around 76–77 FPS at 4K and 138–140 FPS at 720p. | Frames with a large canopy change | Before: main @ 22d0d200 | After: this PR @ 5a3a365 | |---|---:|---:| | 4K, 60 FPS | 38 | 0 | | 4K, uncapped | 25 | 3 | | 720p, uncapped | 54 | 0 | ## Risks Foliage sharing this flag can spend longer drawing its existing transition when the atlas view changes. The fix has no frame-rate threshold or tuning constant. Reverting the hook restores the game's original performance-mode behavior. The separately reported traversal stutter in #2285 has a different reproduction. ## Checklist ### Ready for review - [x] One topic, on current `main`; the title is a Conventional Commit. - [x] Tested on my own PC, in the game for a change the game runs, as Testing says. - [x] `mise run test` passes (any failure that also fails on `main` is named). - [x] Measured against `main`, or Measurements says why there is nothing to measure. - [x] No game files, build output or hand-edited generated files; `third_party/` untouched; nothing GPL-incompatible. ### When it applies - [x] A fix: a game-free test that fails on `main` and passes here. - [x] A check under `tests/` that reads changed source is updated, not weakened. - [x] Host code builds on Windows (llvm-mingw) and Linux, with UTF-8 paths. - [x] Screenshots of the same spot on `main` and here, for a change that shows on screen. - [x] AI assistance recorded with `Assisted-by:` / `Co-Authored-By:` trailers. ### Ready to merge - [ ] Everything in Still to test has run, its results in Tested. - [ ] Tier 1 hardware it can affect is tested (docs/dev/standards.md, "Hardware tiers"). - [ ] Approved in review, every comment answered. - [ ] CI passes on the head; on current `main`, measured again or a comment says why the numbers still hold.
fix(game): blend foliage impostor views on the performance path
Some checks failed
PR description / Title and description (pull_request_target) Has been cancelled
CI / What the change needs (pull_request) Has been cancelled
CI / Lint (pre-commit, ShellCheck, actionlint) (pull_request) Has been cancelled
CI / Third-party parts and guide screenshots (pull_request) Has been cancelled
CI / Rust (rustfmt, clippy, cargo test, end to end) (pull_request) Has been cancelled
CI / Host C for Windows (llvm-mingw, compile only) (pull_request) Has been cancelled
CI / Renderer build check (Windows, compile --only renderer, without and with FSR 4) (pull_request) Has been cancelled
CI / Renderer build check (Linux, compile --only renderer, without and with FSR 4) (pull_request) Has been cancelled
CI / Game-free checks (run_all.py, part 1/2) (pull_request) Has been cancelled
CI / Game-free checks (run_all.py, part 2/2) (pull_request) Has been cancelled
CI / Website build and checks (pull_request) Has been cancelled
5a3a365b53
Assisted-by: OpenAI Codex
Author
Contributor

Tested in game: Windows, Vulkan, RTX 5070 Ti, driver 621.24. Compared stock nightly 895 with the patch in the Graveyard at 60 FPS and uncapped up to about 138 FPS. The abrupt leaf-cluster switches subsided. The player independently confirmed the fix in Hyrule Field, the Graveyard, and Kokiri Forest.

Tested in game: Windows, Vulkan, RTX 5070 Ti, driver 621.24. Compared stock nightly 895 with the patch in the Graveyard at 60 FPS and uncapped up to about 138 FPS. The abrupt leaf-cluster switches subsided. The player independently confirmed the fix in Hyrule Field, the Graveyard, and Kokiri Forest.
Member

Possibly related, for context:

  • issue #2634 Game: Simulated turf grass blades flicker with camera distance on Intel Arc A770 — Reports foliage flicker in Hyrule Field, but describes distance-dependent simulated-turf grass on Intel Arc; distinct symptom.
Possibly related, for context: - issue #2634 Game: Simulated turf grass blades flicker with camera distance on Intel Arc A770 — Reports foliage flicker in Hyrule Field, but describes distance-dependent simulated-turf grass on Intel Arc; distinct symptom.
Author
Contributor

Same stationary Graveyard camera at 60 base FPS, with frame generation off. Watch the outline of the leaf cluster against the sky. Stock nightly 895 is on the left and the fix is on the right.

graveyard-canopy.webp

Same stationary Graveyard camera at 60 base FPS, with frame generation off. Watch the outline of the leaf cluster against the sky. Stock nightly 895 is on the left and the fix is on the right. ![graveyard-canopy.webp](https://git.magicbean.dev/attachments/196af24b-c962-48d5-bdd3-f3913cd49cfa)
jackkenney changed title from WIP: fix(game): blend foliage impostor views on the performance path to fix(game): blend foliage impostor views on the performance path 2026-11-28 11:49:05 +00:00
Owner
@review
BeanBot left a comment

Recommendation: Approve. The reported runs show a substantial reduction in visible foliage switching on NVIDIA, but the frame-time cost and Tier 1 AMD and Steam Deck behavior remain unmeasured. The regression test also unnecessarily requires Clang instead of honoring the selected C compiler. Nothing blocking is left: what remains is for the author before merging (below). Recommend approval; not approved on the forge.

The hook preserves the scene’s foliage transition choice on the performance path, allowing impostor views to blend. It adds an always-on guest hook and can extend transition rendering, so its performance cost still needs measurement.

Should fix (1): not blocking, but worth doing before merging.

  • L1 tests/test_foliage_impostor_flags.py:9: The test requires Clang even though its fixture is ordinary C and does not link a Clang-built object. (more on the line) Do: Use the runner’s {cc} selection and make the fixture compilation honor supported compiler commands, including their arguments.

Testing before merging (2) (runs on the systems it can change; it doesn't hold the recommendation)

  • L2 game/oot_sites.c:765: The cost of keeping foliage transitions active and calling the new hook has not been measured in frame times. (more on the line) Do: Compare repeated interleaved base and head runs in the Graveyard and a foliage-heavy area, reporting average and 1% low FPS and frame-time distributions on representative hardware.
  • L3 game/sites/sites.toml:1410: The rendering change has not been checked on the other affected Tier 1 systems. (more on the line) Do: Run the foliage reproduction and check for rendering and pacing regressions on AMD Windows and Linux and Steam Deck, plus NVIDIA Linux, with results recorded before merge.

@fix can do L1.

Checks: Cancelled on this head (no result): PR description / Title and description (pull_request_target). Still running: 10 checks.

More: does it help, other systems, switches, what was read

Does it help: Yes, for the reported visual symptom: the PR reports large canopy changes falling from 38 to 0 at 4K/60, 25 to 3 at 4K uncapped, and 54 to 0 at 720p uncapped on an RTX 5070 Ti. The player also confirmed improvement in three areas; the performance cost is unproven.

Other systems: The hook runs on worker threads and changes guest foliage flags independently of GPU vendor and OS. NVIDIA Windows was tested; AMD Windows and Linux, Steam Deck, and NVIDIA Linux remain unverified. The callback uses only the supplied guest context and adds no shared mutable state. No save, audio, input, or renderer API changes were found.

Switches: None added, changed, or removed.

Reviewed: 5a3a365b53 against 22d0d20098: Read the repository rules, PR template, applicable standards and hook documentation, the complete diff and commit, the new test and its harness, and the changed code and nearby site entries. Skimmed the remaining entries in the large site tables and unrelated callbacks; no recorded runs, translations, or generated files were changed. The neighboring Tooling checkout and docs/review-checklist.md were absent.; nothing run (a code review).

Checked and fine:

  • The callback preserves all other performance flag bits and carries the scene’s explicit reset bit through.
  • The new callback has no shared state or allocations, and its unsigned bit operations avoid signed overflow.
  • The commit includes an Assisted-by trailer; no switch, generated shader, third-party file, or renderer API was changed.
  • The test exercises both scene reset values and would fail if the callback stopped correcting the forced bit.

Testing: Read-only review; no code, tests, or project scripts were run. The author reports Windows and Linux object compilation, game testing on NVIDIA Windows, and 16 strict-suite failures reproduced on the base. CI is still running.

Overlaps and merge order: Not checked; network access is closed.


Automated code review by BeanBot (gpt-6.1-terra), asked for by HumanBean. Nothing was run; a maintainer decides.

**Recommendation: Approve.** The reported runs show a substantial reduction in visible foliage switching on NVIDIA, but the frame-time cost and Tier 1 AMD and Steam Deck behavior remain unmeasured. The regression test also unnecessarily requires Clang instead of honoring the selected C compiler. Nothing blocking is left: what remains is for the author before merging (below). Recommend approval; not approved on the forge. The hook preserves the scene’s foliage transition choice on the performance path, allowing impostor views to blend. It adds an always-on guest hook and can extend transition rendering, so its performance cost still needs measurement. **Should fix (1)**: not blocking, but worth doing before merging. - **L1** `tests/test_foliage_impostor_flags.py:9`: The test requires Clang even though its fixture is ordinary C and does not link a Clang-built object. (more on the line) **Do:** Use the runner’s {cc} selection and make the fixture compilation honor supported compiler commands, including their arguments. **Testing before merging (2)** (runs on the systems it can change; it doesn't hold the recommendation) - **L2** `game/oot_sites.c:765`: The cost of keeping foliage transitions active and calling the new hook has not been measured in frame times. (more on the line) **Do:** Compare repeated interleaved base and head runs in the Graveyard and a foliage-heavy area, reporting average and 1% low FPS and frame-time distributions on representative hardware. - **L3** `game/sites/sites.toml:1410`: The rendering change has not been checked on the other affected Tier 1 systems. (more on the line) **Do:** Run the foliage reproduction and check for rendering and pacing regressions on AMD Windows and Linux and Steam Deck, plus NVIDIA Linux, with results recorded before merge. `@fix` can do L1. **Checks:** Cancelled on this head (no result): `PR description / Title and description (pull_request_target)`. Still running: 10 checks. <details> <summary>More: does it help, other systems, switches, what was read</summary> **Does it help:** Yes, for the reported visual symptom: the PR reports large canopy changes falling from 38 to 0 at 4K/60, 25 to 3 at 4K uncapped, and 54 to 0 at 720p uncapped on an RTX 5070 Ti. The player also confirmed improvement in three areas; the performance cost is unproven. **Other systems:** The hook runs on worker threads and changes guest foliage flags independently of GPU vendor and OS. NVIDIA Windows was tested; AMD Windows and Linux, Steam Deck, and NVIDIA Linux remain unverified. The callback uses only the supplied guest context and adds no shared mutable state. No save, audio, input, or renderer API changes were found. **Switches:** None added, changed, or removed. **Reviewed:** 5a3a365b5363 against 22d0d20098d6: Read the repository rules, PR template, applicable standards and hook documentation, the complete diff and commit, the new test and its harness, and the changed code and nearby site entries. Skimmed the remaining entries in the large site tables and unrelated callbacks; no recorded runs, translations, or generated files were changed. The neighboring Tooling checkout and docs/review-checklist.md were absent.; nothing run (a code review). **Checked and fine:** - The callback preserves all other performance flag bits and carries the scene’s explicit reset bit through. - The new callback has no shared state or allocations, and its unsigned bit operations avoid signed overflow. - The commit includes an Assisted-by trailer; no switch, generated shader, third-party file, or renderer API was changed. - The test exercises both scene reset values and would fail if the callback stopped correcting the forced bit. **Testing:** Read-only review; no code, tests, or project scripts were run. The author reports Windows and Linux object compilation, game testing on NVIDIA Windows, and 16 strict-suite failures reproduced on the base. CI is still running. **Overlaps and merge order:** Not checked; network access is closed. </details> --- <sub>Automated code review by BeanBot (gpt-6.1-terra), asked for by HumanBean. Nothing was run; a maintainer decides.</sub>
game/oot_sites.c Outdated
@ -761,0 +762,4 @@
/* The performance path forces every change of impostor view to finish in one
update. Restore the scene's choice for that bit before the game selects its
quality flags. This also preserves an explicit request to skip the fade. */
int hos_site_foliage_impostor_flags(Ctx *A64_NOESC c) {
Member

L2 (should fix): The cost of keeping foliage transitions active and calling the new hook has not been measured in frame times.

When: In foliage-heavy scenes, transitions can remain active longer and the hook adds guest-context synchronization and a call; the reported approximate uncapped FPS does not show whether average or low frame rates and frame pacing change.

Do: Compare repeated interleaved base and head runs in the Graveyard and a foliage-heavy area, reporting average and 1% low FPS and frame-time distributions on representative hardware.

**L2** (should fix): The cost of keeping foliage transitions active and calling the new hook has not been measured in frame times. *When:* In foliage-heavy scenes, transitions can remain active longer and the hook adds guest-context synchronization and a call; the reported approximate uncapped FPS does not show whether average or low frame rates and frame pacing change. **Do:** Compare repeated interleaved base and head runs in the Graveyard and a foliage-heavy area, reporting average and 1% low FPS and frame-time distributions on representative hardware.
@ -1407,1 +1407,4 @@
args = ["x20:ptr:box"]
[[site]]
name = "foliage.impostorFlags"
Member

L3 (should fix): The rendering change has not been checked on the other affected Tier 1 systems.

When: The same foliage flags reach rendering on AMD and Steam Deck as well as NVIDIA, but the only reported patched run is Windows on NVIDIA, leaving their visual behavior and performance unknown.

Do: Run the foliage reproduction and check for rendering and pacing regressions on AMD Windows and Linux and Steam Deck, plus NVIDIA Linux, with results recorded before merge.

**L3** (should fix): The rendering change has not been checked on the other affected Tier 1 systems. *When:* The same foliage flags reach rendering on AMD and Steam Deck as well as NVIDIA, but the only reported patched run is Windows on NVIDIA, leaving their visual behavior and performance unknown. **Do:** Run the foliage reproduction and check for rendering and pacing regressions on AMD Windows and Linux and Steam Deck, plus NVIDIA Linux, with results recorded before merge.
@ -0,0 +6,4 @@
sys.path.insert(0, str(Path(__file__).resolve().parent))
from sitecheck import callback, engine_fn, run, site # noqa: E402
RUN_ALL_ARGS = ["--cc", "{clang}"]
Member

L1 (should fix): The test requires Clang even though its fixture is ordinary C and does not link a Clang-built object.

When: On a supported Linux development setup with GCC selected through CC and no Clang installed, run_all skips this regression test, or fails it in strict mode, despite having a working C compiler.

Do: Use the runner’s {cc} selection and make the fixture compilation honor supported compiler commands, including their arguments.

**L1** (should fix): The test requires Clang even though its fixture is ordinary C and does not link a Clang-built object. *When:* On a supported Linux development setup with GCC selected through CC and no Clang installed, run_all skips this regression test, or fails it in strict mode, despite having a working C compiler. **Do:** Use the runner’s {cc} selection and make the fixture compilation honor supported compiler commands, including their arguments.
Owner
@fix
BeanBot force-pushed fix/blend-performance-foliage from 5a3a365b53
Some checks failed
PR description / Title and description (pull_request_target) Has been cancelled
CI / What the change needs (pull_request) Has been cancelled
CI / Lint (pre-commit, ShellCheck, actionlint) (pull_request) Has been cancelled
CI / Third-party parts and guide screenshots (pull_request) Has been cancelled
CI / Rust (rustfmt, clippy, cargo test, end to end) (pull_request) Has been cancelled
CI / Host C for Windows (llvm-mingw, compile only) (pull_request) Has been cancelled
CI / Renderer build check (Windows, compile --only renderer, without and with FSR 4) (pull_request) Has been cancelled
CI / Renderer build check (Linux, compile --only renderer, without and with FSR 4) (pull_request) Has been cancelled
CI / Game-free checks (run_all.py, part 1/2) (pull_request) Has been cancelled
CI / Game-free checks (run_all.py, part 2/2) (pull_request) Has been cancelled
CI / Website build and checks (pull_request) Has been cancelled
to 85cb18ca4e
Some checks failed
PR description / Title and description (pull_request_target) Successful in 16s
CI / What the change needs (pull_request) Successful in 16s
CI / Renderer build check (Windows, compile --only renderer, without and with FSR 4) (pull_request) Has been skipped
CI / Renderer build check (Linux, compile --only renderer, without and with FSR 4) (pull_request) Has been skipped
CI / Third-party parts and guide screenshots (pull_request) Successful in 23s
CI / Lint (pre-commit, ShellCheck, actionlint) (pull_request) Failing after 28s
CI / Host C for Windows (llvm-mingw, compile only) (pull_request) Successful in 2m17s
CI / Rust (rustfmt, clippy, cargo test, end to end) (pull_request) Failing after 3m22s
CI / Website build and checks (pull_request) Failing after 34s
CI / Game-free checks (run_all.py, part 1/2) (pull_request) Failing after 31m14s
CI / Game-free checks (run_all.py, part 2/2) (pull_request) Failing after 43m57s
2026-11-28 18:59:52 +00:00
Compare
BeanBot left a comment

Recommendation: Approve. The code is ready: only testing is left. The player reports and canopy measurements show a substantial reduction in abrupt foliage changes. Frame-time cost and behavior on the other affected Tier 1 systems remain unmeasured. Recommend approval; not approved on the forge.

What @fix changed
I changed this pull request: the new head is 85cb18ca4e. I rebased it onto main (0a124fb900).

Changed

  • Compiler selection in tests/test_foliage_impostor_flags.py:10: The test uses the runner’s C compiler selection and honors CC when run directly. tests/sitecheck.py:244 parses compiler commands and their arguments using the suite’s shared parser. Tests and builds were not run, as requested.

Nothing was built or run: the checks run again on the new head.

The hook preserves the scene’s foliage fade choice on the performance path, reducing visible outline changes. The regression test now uses the selected C compiler; the runtime cost of longer transitions remains unknown.

Testing before merging (2) (runs on the systems it can change; it doesn't hold the recommendation)

  • L2 game/oot_sites.c:765: The cost of keeping foliage transitions active and calling the new hook has not been measured in frame times. When: In foliage-heavy scenes, transitions can remain active longer and the hook adds guest-context synchronization and a call; the reported approximate uncapped FPS does not show whether average or low frame rates and frame pacing change. Do: Compare repeated interleaved base and head runs in the Graveyard and a foliage-heavy area, reporting average and 1% low FPS and frame-time distributions on representative hardware.
  • L3 game/sites/sites.toml:1410: The rendering change has not been checked on the other affected Tier 1 systems. When: The same foliage flags reach rendering on AMD and Steam Deck as well as NVIDIA, but the only reported patched run is Windows on NVIDIA, leaving their visual behavior and performance unknown. Do: Run the foliage reproduction and check for rendering and pacing regressions on AMD Windows and Linux and Steam Deck, plus NVIDIA Linux, with results recorded before merge.

Checks: they run again on this head; a failure shows on the pull request.

More: does it help, other systems, switches, what was read

Does it help: Yes for the reported visual defect: the PR reports large canopy changes falling from 38 to 0 at 4K 60 FPS, 25 to 3 at 4K uncapped, and 54 to 0 at 720p uncapped, using 357 video samples per clip. Frame-time cost has not been measured.

Other systems: The hook affects foliage using this flag across rendering systems. The reported game runs cover Windows Vulkan on an RTX 5070 Ti; AMD or Intel Vulkan and other affected Tier 1 systems remain untested.

Switches: None.

Reviewed: 85cb18ca4e against 0a124fb900: Read the fix diff, full foliage regression test and compiler parser, and the changed hook and site declarations in the diff. Skimmed compiler-selection callers, repository rules, the PR template, and the reported runs; the larger changed code and site tables were not read in full.; nothing run (a code review).

Checked and fine:

  • The hook preserves the scene’s skip-fade bit and leaves the other performance flag bits intact.
  • The compiler fix retains the foliage regression test and does not route around the game change.

Testing: No commands that build or run tests were executed. The PR reports game testing, object compilation and lint; CI has not run on this head.

Overlaps and merge order: Not checked; network access is closed.


Automated code review by BeanBot (gpt-6.1-terra), asked for by BeanBot, after its fix. Nothing was run; a maintainer decides.

**Recommendation: Approve.** The code is ready: only testing is left. The player reports and canopy measurements show a substantial reduction in abrupt foliage changes. Frame-time cost and behavior on the other affected Tier 1 systems remain unmeasured. Recommend approval; not approved on the forge. **What `@fix` changed** I changed this pull request: the new head is 85cb18ca4e43. I rebased it onto `main` (0a124fb90063). **Changed** - **Compiler selection in tests/test_foliage_impostor_flags.py:10**: The test uses the runner’s C compiler selection and honors CC when run directly. tests/sitecheck.py:244 parses compiler commands and their arguments using the suite’s shared parser. Tests and builds were not run, as requested. Nothing was built or run: the checks run again on the new head. The hook preserves the scene’s foliage fade choice on the performance path, reducing visible outline changes. The regression test now uses the selected C compiler; the runtime cost of longer transitions remains unknown. **Testing before merging (2)** (runs on the systems it can change; it doesn't hold the recommendation) - **L2** `game/oot_sites.c:765`: The cost of keeping foliage transitions active and calling the new hook has not been measured in frame times. *When:* In foliage-heavy scenes, transitions can remain active longer and the hook adds guest-context synchronization and a call; the reported approximate uncapped FPS does not show whether average or low frame rates and frame pacing change. **Do:** Compare repeated interleaved base and head runs in the Graveyard and a foliage-heavy area, reporting average and 1% low FPS and frame-time distributions on representative hardware. - **L3** `game/sites/sites.toml:1410`: The rendering change has not been checked on the other affected Tier 1 systems. *When:* The same foliage flags reach rendering on AMD and Steam Deck as well as NVIDIA, but the only reported patched run is Windows on NVIDIA, leaving their visual behavior and performance unknown. **Do:** Run the foliage reproduction and check for rendering and pacing regressions on AMD Windows and Linux and Steam Deck, plus NVIDIA Linux, with results recorded before merge. **Checks:** they run again on this head; a failure shows on the pull request. <details> <summary>More: does it help, other systems, switches, what was read</summary> **Does it help:** Yes for the reported visual defect: the PR reports large canopy changes falling from 38 to 0 at 4K 60 FPS, 25 to 3 at 4K uncapped, and 54 to 0 at 720p uncapped, using 357 video samples per clip. Frame-time cost has not been measured. **Other systems:** The hook affects foliage using this flag across rendering systems. The reported game runs cover Windows Vulkan on an RTX 5070 Ti; AMD or Intel Vulkan and other affected Tier 1 systems remain untested. **Switches:** None. **Reviewed:** 85cb18ca4e43 against 0a124fb90063: Read the fix diff, full foliage regression test and compiler parser, and the changed hook and site declarations in the diff. Skimmed compiler-selection callers, repository rules, the PR template, and the reported runs; the larger changed code and site tables were not read in full.; nothing run (a code review). **Checked and fine:** - The hook preserves the scene’s skip-fade bit and leaves the other performance flag bits intact. - The compiler fix retains the foliage regression test and does not route around the game change. **Testing:** No commands that build or run tests were executed. The PR reports game testing, object compilation and lint; CI has not run on this head. **Overlaps and merge order:** Not checked; network access is closed. </details> --- <sub>Automated code review by BeanBot (gpt-6.1-terra), asked for by BeanBot, after its fix. Nothing was run; a maintainer decides.</sub>
HumanBean deleted branch fix/blend-performance-foliage 2026-11-28 19:00:22 +00:00
Sign in to join this conversation.
No reviewers
No milestone
No project
No assignees
3 participants
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
MagicBeanDev/Longshot!2736
No description provided.