Page MenuHome

Denoise artifacts with Direct Glossy
Open, Confirmed, MediumPublic


System Information
CentOS 7.4.1708
GNOME 3.22
i7-6850K (8 Threads)

Blender Version
Broken: 2.79 5bd8ac9abfa

When using the denoiser 'Direct Glossy' can cause artifacting. The intensity of the artifact may or may not be influenced (slightly) by SSS.

Exact steps for others to reproduce the error
Create and apply glossy material to object.
Add light(s)
Enable denoiser (with direct glossy)

Based on a (as simple as possible) attached .blend file with minimum amount of steps. Test with and without Direct Glossy. Uses default denoiser settings. If you disable both SSS on the Principled shader and the point light, the artifact shrinks.



Event Timeline

Yeah, I am currently suffering from the same problem. I think it's mainly a problem with the very bright intensities of glossy reflections. At least in my case it doesn't need any SSS to produce the issue, just a rather reflective surface. I am facing this problem mostly with metals in scenes with bright lamps. I think the denoiser somehow tries compensate for the brightness differences between the glossy reflection and the much darker surrounding areas, and by overcompensating that brightness differences it makes the problematic areas black. Or something like that. No idea how to solve that but maybe as a workaround the denoiser could just keep the super bright highlights just white?
Here's the above file but without SSS and point lamp, but with a metal surface, still producing a black artefact.

Perhaps the denoising should work on log(glossy) or some other kind of remapping to bring the extreme values into a smaller range.

Dalai Felinto (dfelinto) triaged this task as Normal priority.

Changing priority to Normal, until @Lukas Stockner (lukasstockner97) confirms that this is a bug.

Perhaps the denoising should work on log(glossy) or some other kind of remapping to bring the extreme values into a smaller range.

I've just tried that, and while it works decently (I used no mapping between 0..1 and log(x)+1 above 1, since just using log(x) causes problems in really dark areas) it's really biased to do the regression in the remapped range and can make noisy images noticeably darker. In this case, the highlight ends up in the 1.7 range even though the original pixels are >40.
I guess making the NLM filter more robust to not overblur the highlight would be the better option here.

Generally, I don't really like any solutions that aren't exposure-invariant, mainly because they feel like a cheap band-aid fix instead of a proper solution...

But yeah, I would consider this a bug since highlights aren't that uncommon.

Dalai Felinto (dfelinto) raised the priority of this task from Normal to Confirmed, Medium.Sep 20 2017, 3:55 PM

I also encountered this problem and found a remedy.

The black artifacts are actually negative results of denoise computation clamped to zero, which almost always appear near fireflies of glossy reflections.
I marked the glossy pass ( + the scatter pass ) as 'noisy' and the other passes ( + the emission and the backgroud pass ) as 'clean', and modified the code to denoise the 'noisy' part and the 'clean' part separately and add the results. I managed to denoise both parts at a single denoise stage since they share the feature data (and the computation for feature extraction and transform too). The artifacts still showed up but became less annoying because they now revealed the pixel values of the (denoised) 'clean' part, not empty black pixels.

Increasing # of samples let the fireflies ( and the black artifacts ) disappear eventually, but it required lots of computation time. Changing the denoising computation from float to double did not affect the artifacts so it is not likely a precision problem.

Hello everybody,

I just stumbled into this myself and I noticed that increasing the "Clamp Direct" value helps reduce the artefact. Here an image (I used the same file uploaded here in discussion, the only value changed is Clamp Direct)

I'm not a developer but hope this helps you guys