Screen Space Global Illumination for Eevee

I’ve added a second layer to SSR in a modified build so it’s possible to do both diffuse and specular reflections on the same pixel.

Doube Layer SSR:

Since diffuse reflections tend to be low frequency in details I wonder if a simple box blur ( via texture lod bias) on the diffuse reflections component would work well enough to clean up the noise.

Haven’t looked at the material side integration in depth yet (hopefully it’s possible without extra nodes without bigger changes). In addition there’s few bugs that I haven’t managed to track down.

Either way that’s going to take time, so I’ve also fixed the issues with the how the current released addon works with small changes to the default blender build. So world lighting works mostly as expected. Needs additional testing though.

Custom build with only fixes for the addon version -
Fixed interaction with world HDRI probe, so no more inverted colors:


22 Likes

I’ve tested the 1.3 version and I am having issues with it with bright albedo colors that accumulates bounces and creates energy, but also negative (purple) colors even with a darker green.


eevee_sky.blend (1.8 MB)

1 Like

Apologies if it wasn’t clear from the previous post - all the fixes there are only with modified blender build + addon as there isn’t enough control over Eevees rendering with only nodes.

Oh, sorry I missed that info. Any ETA on when we could get our hands on that custom build?
Thanks!

I’m aiming to get some version out at the end of this year / beginning of the next one. Although I’m currently mostly focusing on the double layer version at first and then moving appropriate changes back to the single layer one.

I’d like to get some form of occlusion to probe/HDRI lighting in the single layer SSR version before releasing publicly, as updating blender builds in addition to addon is way more hassle on the users side.

As far as I’ve currently tested the single layer SSR version works good enough for diffuse reflections, but with low roughness screen space reflections the lack of occlusion on probes gives too glowy results in addition to light leaks with intense probe lighting.

7 Likes

Progress update:

I’m focusing only on the standalone build version and dropping the addon + build version completley as the workarounds to get it working were taking too much time for a visually compromised result.

The current standalone build has finished basic principled and diffuse material support without any extra nodes or addons and separate diffuse and specular layers.

I didn’t have as much time as I expected to work on this so I’m bit behind and still need to clean up the ssr shader and fix mix shader node breaking my ssr input before I consider releasing this.

There’s also some issues in the addon only version that I became aware of. Fixing those should reduce some of the lighting that gets blown out with the addon.

26 Likes

Functional version done of the Native SSGI build, works as intended with all the test cases so far, with some occasional mostly minor artifacts. The result can be pretty noisy at times so looking into better filtering (currently only relying on firefly filter) is the planned next step.

Some examples from testing, rendered with 64 or 128 samples on a GTX 1060 with some other things going on in the background. There might be some overhead with even with the diffuse bounces disabled compared to default blender due to some changes I had to make that won’t get disabled with the SSGI disabled, but the random variance in render time was big enough that I coudn’t get a actual number for it:

On:

Off:

On (high intensity):

Off:

On:

Off:

On:

Off:

On with badly placed irradiance volume, cubemap and world lighting:

Off with irradiance volume, cubemap and world lighting:

Cycles:

On:

Off:

On without AO multiplied over it + looser filter treshhold:

On:

Off:

33 Likes

The results are fantastic! :smile:

1 Like

I’m amazed with this add-on.
Congrats 0451! and thank you for letting us enjoy it.

The latest version I’ve found is 0.1.3 but it doesn’t show the same options I can see here.
I’m looking forward to test 0.1.4 version with all these new stuff.

1 Like

also very much looking forward to the update!

1 Like

This is great, thanks for your impressive work. Will your goal be to offer this for inclusion in the main Blender builds? That would definitely push Eevee’s potential as a Cycles replacement.

9 Likes

@Metin_Seven
That would be ideal, but the current version definitely wouldn’t pass review, neither in naming conventions nor some of the overall methods used to implement this. My focus has been on getting this to work at all, so even if the general method (extension to SSR fragment shader using the same screen space raytracing functions) was approved then it would still need some major revisions to the way it’s done that would be huge potential time sinks that I currently don’t have the free time for.
I’m also not sure if with hardware triangle raytracing slowly being on the horizon that something like this would be considered suitable at all for Eevee.

I already have way too many Blender builds that I switch between so I’d love to keep this as a addon (if Blender had enough flexibility for a decent implementation) or add native implementation to master, but the latter I believe is not feasible for me at the moment with the time I have, so doing a custom build is it for now.

@Toribio @Binke
For clarity - the latest updates are for a custom build of blender with the functionality natively implemented and the addon version will receive only minor fixes. I want to get additional filtering step in before releasing the initial version of native implementation. Figuring out some steps for it is taking a bit longer than I expected and I might just release it as is without additional filtering step if I can’t make significant progress in the upcoming weekend.

12 Likes

@0451 Thanks for your comment. What you’ve done yet is of great use for me so anything furtherr would be a dream.

1 Like

I uploaded a Windows build and a untested Linux build to gumroad (can’t really test it in a virtual machine).

No additional denoising unfortunately as Eevee got a pretty big code refactor that breaks a lot of the additions in the custom build and I’d rather focus on fixing that so I can sync it back up with current master.

Current know issues with Native build:

  • Haloing - Mostly unnoticable, but can be clearly visible in some cases.
  • Diffuse ray hits take samples from final render buffer so specular highlights that move depending on the viewpoint contribute to the diffuse layer.
  • Noise - can stay in acceptable range in some scenes, but can be a issues since it requires higher sample counts and from certain point onwards higher sample counts won’t help resolve into noise free image.
  • Diffuse bounce lighting gets added to specular diffuse render pass, while the pass is still masked only by specular input.
  • Hard crash with baking probes - new issue as older pre release builds worked fine. Will try to fix ASAP (Update: It’s a official Blender alpha build bug - will add a fix for it when it becomes available https://developer.blender.org/T85603)

Edit:
Reuploaded the Linux build, shoudn’t be an empty folder anymore.

14 Likes

just testing quickly…very cool stuff

1 Like

Hi.

I’ve noticed you have a custom build with this, I don’t like the Addon version because it modifies materials and I don’t want that, but I like the idea of having this as part of Blender.

Is there a patch in developer.blender.org or a git branch somewhere to take a look?

It looks awesome in a branch :slight_smile:

10 Likes

I agree, the native build is incredible and really nicely integrated. it would be wonderful to have something like this in master. Where is this code hosted to take a look?

4 Likes

Also curious that author not have any thread about this not on Devtalk not have any patch/task/designs on developer.blender.org :thinking:

1 Like

Hi! On Ubuntu 18.04 LTS linux Build doesn’t work

/lib/x86_64-linux-gnu/libc.so.6: version 'GLIBC_2.28' not found

Is it possible to make build on glibc 2.27? Damn I’m not ready to migrate on 20.04 LTS.

3 Likes

damn this looks good (accidentally found this tweet)
https://twitter.com/Yokohara_h/status/1361699018091290626?s=20

13 Likes