shader: a comparison sampler replaces the reduction instead of OR-ing into it #2812
No reviewers
Labels
No labels
accessibility
area: build
area: formats
area: gpu
area: loader
area: runtime
area: shader
bug
documentation
duplicate
enhancement
good first issue
gpu: amd
gpu: intel
gpu: nvidia
help wanted
host: wine
invalid
out of scope
question
request
run report
triage: confirmed
triage: has patch
triage: merge candidate
triage: needs info
triage: needs rebase
triage: needs work
triage: proposed close
wontfix
No milestone
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
github/Marvisak--VIctory!2812
Loading…
Reference in a new issue
No description provided.
Delete branch "github-bot/gh-2812"
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?
@spy0eye-beep on GitHub · 2026-11-25 21:14 UTC · original
spy0eye-beep:fix/comparison-sampler-reduction→main· +30 −5 · 2 files · 1 commits · openSplit out of #1483 as requested in review.
D3D12 keeps the reduction in filter bits 7-8 (0 standard, 1 comparison, 2 minimum, 3 maximum). OR-ing 0x80 into a minimum sampler (0x100) produced a maximum one (0x180).
StaticSampler::make_comparisonclears the reduction and sets comparison; both call sites use it, and the existingimmediate_sampler_slots_distinguish_comparison_usesexpectation is updated rather than duplicated.Test:
comparison_replaces_the_reductioncovers standard, minimum and maximum reductions with point, linear and anisotropic filters.🤖 Generated with Claude Code
@fuzeofficlal on GitHub · 2026-11-25 21:33 UTC · original
Verified
333e39c3on Windows 11 (RTX 5090 + WARP + Windows SDK10.0.26100.0dxil.dll):cargo xtask policy: 184 files ok;cargo clippy -p victory-shader --all-targets --locked -- -D warnings(default &--features host): 0 warnings.emit::sampler::+immediate_sampler_slots_distinguish_comparison_uses: 6/6 passed (withdxil.dllvalidation).git merge-treeagainstorigin/main13f91caand #2811.StaticSampler::make_comparison()cleanly masks out bits 7–8 (& !0x180 | 0x80) before setting comparison mode across bothemit_withand the test, cleanly superseding the sampler portion of #1483.@Marvisak on GitHub · 2026-11-26 02:20 UTC · original
Automated triage for the maintainers.
StaticSampler::make_comparison(emit/sampler.rs) clears the reduction bits (7-8) before setting comparison. OR-ing0x80into a minimum sampler (0x100) gave a maximum one (0x180). Both call sites inemit/mod.rsuse it, and the test covers standard/min/max reductions with point, linear and anisotropic filters. It is small and correct by my reading of D3D12'sD3D12_FILTERencoding.CI: passing.
Generated by Claude Code
View command line instructions
Checkout
From your project repository, check out a new branch and test the changes.Merge
Merge the changes and update on Forgejo.