Skip to content

feat(rtx): add maxSampledLights to Interactive renderer#340

Merged
jeffamstutz merged 1 commit into
NVIDIA:next_releasefrom
tarcila:rtx-add-interactive-max-sampled-lights
Jul 15, 2026
Merged

feat(rtx): add maxSampledLights to Interactive renderer#340
jeffamstutz merged 1 commit into
NVIDIA:next_releasefrom
tarcila:rtx-add-interactive-max-sampled-lights

Conversation

@tarcila

@tarcila tarcila commented Jul 15, 2026

Copy link
Copy Markdown
Collaborator

Interactive summed direct lighting over ALL light instances per hit (one shadow ray each), so many-light scenes were O(N) and slow.

Add a maxSampledLights renderer param (int, default 8, <=0 => all): when the scene has more light instances than the cap, importance-sample that many via the world Pick-Power CDF instead of looping all of them.

This gives back performances and predictability on low lights count scenes -- more common sci-viz case -- while preserving correctness on many lights scenes, still at the expense of more convergences frames.

Interactive summed direct lighting over ALL light instances per hit
(one shadow ray each), so many-light scenes were O(N) and slow. Add a
maxSampledLights renderer param (uint, default 8, <=0 = all): when the
scene has more light instances than the cap, importance-sample that many
via the world Pick-Power CDF and reweight by 1/(K*pPick) instead of
looping all of them. E[stochastic] == the all-lights sum, so the
accumulated image converges; small scenes keep the exact deterministic
loop. HDRI MIS is unchanged (escape side stays deterministic, so
pLight=envPdf with the reweight is MIS-consistent). Uniform-pick
fallback when total Pick Power is zero.
@tarcila
tarcila requested a review from jeffamstutz July 15, 2026 19:46
@jeffamstutz
jeffamstutz merged commit 010975c into NVIDIA:next_release Jul 15, 2026
8 checks passed
@tarcila
tarcila deleted the rtx-add-interactive-max-sampled-lights branch July 15, 2026 23:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants