GPU: add opt-in host D3D12 occlusion queries (VICTORY_REAL_OCCLUSION=1) #167
No reviewers
Labels
No labels
accessibility
bug
documentation
duplicate
enhancement
good first issue
help wanted
invalid
question
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/fxceless--victory-fork!167
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-167"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
@HailLucifer666 on GitHub · 2026-11-24 22:06 UTC · original
HailLucifer666:perf/real-occlusion-queries→main· +295 −16 · 2 files · 2 commits · closed without mergingProblem
BeginQueryandEndQueryare no-ops andResolveQueryDataalways writes synthetic visible counts (1 << 20forOCCLUSION,1forBINARY_OCCLUSION), preventing the title from occlusion-culling hidden geometry.Fix
VICTORY_REAL_OCCLUSION=1(off by default, matching other experimental switches):ID3D12QueryHeap(D3D12_QUERY_HEAP_TYPE_OCCLUSION) inquery.rs.BeginQueryandEndQueryforOCCLUSION(0) andBINARY_OCCLUSION(1) inlist.rs.Shadowbuffer withrefresh()+gpu_writes()copy-back tracking and checked bounds.Verification
resolve_range_valid_rejects_empty_and_overflowandocclusion_query_type_maps_only_occlusion_kinds.cargo clippy --workspace --all-targets --locked -- -D warningscargo clippy --workspace --all-targets --all-features --locked -- -D warningscargo test -p victory-gpu query::tests --locked(2/2 passed)cargo test -p xtask --locked(4/4 passed)23e576b5ddtoc14d27fb88@HailLucifer666 on GitHub · 2026-11-26 14:28 UTC · original
Rebased onto
maina20809de; head is nowc14d27fb(no conflicts). Verified:victory-gpu occlusion::2 passed, 0 failed (the WARP occlusion test included);clippy -D warningson victory-gpu clean. Still opt-in (VICTORY_REAL_OCCLUSION=1), as the description says.@HailLucifer666 on GitHub · 2026-11-26 14:33 UTC · original
Superseded by
58de9bf4onmain, which lands host-GPU occlusion queries asVICTORY_OCCLUSION=1|alt(after upstream #3138): the query heap,BeginQuery/EndQueryon the host, and results resolved from it. That is the feature this PR proposed asVICTORY_REAL_OCCLUSION=1, written against the currentlist.rs/query.rs(the same files this branch edits, hence the conflict). Closing as already implemented rather than rebasing a duplicate. One piece may still be worth porting separately: this branch had a WARP test that resolves a host occlusion query into a COPY_DEST shadow buffer; if the landed implementation has no equivalent, it can be offered as a small test-only follow-up.Pull request closed