Page MenuHome

Light threshold broke branched path tracer
Closed, ResolvedPublic

Description

System Information

Linux Debian Jessie, 64bit, core i7 something. Should not really matter.

Blender Version

Current git rBbcd0d85.

Short description of error

The image is too noisy. Very too much noisy.

Exact steps for others to reproduce the error

Just hit Shit-Z in

@Brecht Van Lommel (brecht) says it's really a bug.

Event Timeline

Sergey Sharybin (sergey) lowered the priority of this task from 90 to 50.
Sergey Sharybin (sergey) created this task.

I've just tested the file, and there indeed is a huge difference when disabling the light termination.
However, the same seems to happen for regular PT (which makes sense, since there's only one light source).
Here are my renders (with Color Management exposure at 3):

BPT, Termination 0.05:


BPT, No Termination:

PT, also 4 Samples, Termination 0.05:

PT, also 4 Samples, No Termination:

The main problem is that this scene is pretty dark (even the bright checker squares only get up to 0.05), so the default termination value is too high here. That is a problem in general - the threshold should be relative to the area's brightness, but you don't know that before rendering...

If such optimization leads to a more noisy image in dark areas then i'm not fully convinced in default value for it picked up correctly: you optimized per-sample time but required to have more samples to clear up the dark areas?

Perhaps when we have adaptive sampling we can do some kind of brightness estimation and adaptively change the threshold. Currently I suggest to lower the default threshold to 0.01.

I noticed the result with 1 sample the shadows look really different. This correlation problem is not new, it's the same as rBe1e247a99b48. Adding the extra hash for every RNG dimension solves it but slows down rendering, ideally we'd find a faster way to do this hashing.

Will simpler hash combine function work?

For example, default Boost's hash_combine will be expanded to something like result ^= dimension + 0x9e3779b9 + (result << 6) + (result >> 2) for the case of integer dimension and hash result. Seems to be way simpler than cmj_hash() but can't test ATM whether it solves the correlation artifact.