Guide to Global Illumination

[FONT=Arial Black]Ultimate Guide to Global Illumination

Note: this thread is here to overview all realtime GI solutions that are currently accessible to everyone. Lightmass will not be discussed in depth, and, as of this writing, enlighten will also not be talked about, because it isn’t freely available, though it may be referenced. Same goes for SVOGI; it may be referenced because we still have footage of it, but it has been cancelled, and will not be discussed.

Since the announcement of UE4, many were excited to see the power of a fully realtime lighting engine. Unfortunately, the existing tech that was to be used didn’t scale properly and was deemed unusable in realistic gaming scenarios, causing the engine to go back to it’s powerful, though static system, known as lightmass. Lightmass does what It’s meant to do very well, but it isn’t a perfect solution. It’s poor for massive worlds, slows development time greatly, and is a general pain for those who are new to lightmapping especially. However, there are a few Realtime GI solutions that are currently available for UE4 users to use. This thread focuses on these solutions, documents what we know about them, and is meant for us to discuss Realtime GI as a whole instead of just discussing one solution out of context from others. I’ve taken to testing all of these solutions a solid amount, and would like to share what I, and several other community members, have found. I have also created remakes of the ArchVis demo from Epic showcasing each one visually. For reference, here is the scene in realtime with no GI and one directional light. (All of the scenes only use one directional light except DFGI, which I will discuss later. Also note that static lighting is completely disabled.)

No Global Illumination


There’s not much to say about this. It’s simply what direct light looks like in engine. Nothing special about it.

Light Propagation Volumes


Light propagation volumes is the first GI solution available for UE subscribers to use. It’s quick and dirty, but all the same it works. It was added into the engine for reasons involving Fable Legends, and then was heavily polished by Lionhead for their game. The version of LPV’s we have is essentially version 0.1. It’s unfinished, slow compared to other LPV solutions, and it can be difficult to set up. LPV’s have been used in games before with much success, most notably in Cryengine, and are a novel way of attacking GI. However, even a polished LPV system, such as Crytek’s, is notorious for suffering from light leaking, low accuracy, and an inability to scale well. They only support GI from a single directional light, one bounce of lighting, and in some cases allow for emission from materials and area lights. It is unknown if progress will continue on LPV’s in UE4, but most people are doubtful of this happening. Epic is already working on another solution, which has shown far better results.

Distance Field GI


DFGI is Epic’s new solution to solve GI. It piggybacks off of Distance Field Ambient Occlusion and requires a skylight to work (which is why the back of the room is lit), and for the most part has very good results. In the image above there is noticeable graininess where light is being bounced, but that is being polished, and only happens in interiors currently. Also note that this screenshot was taken using a post-effect version of DFGI that can be found in version 4.7.x of the engine with the command “r.DistanceFieldGI 1” if you have distance fields enabled. This version is already less-than accurate to how DFGI performs. In the 4.7.x version, it supports emissive materials, point lights, spotlights, and directional lights. In 4.8, it is actually 2 GI systems, Heightfield GI, which is used for terrain, and Surfel GI, which is what is currently implemented. Future versions of DFGI plan to have better interior results, multiple bounces of light, and 4x better performance than what it currently has. DFGI is slower than LPVs, and is considered a “high end” feature, but isn’t nearly as resource intensive as SVOGI or Nvidia’s new solution, VXGI.



I’ve seen a lot of negative comments about Nvidia Gameworks, so to keep everyone from inferring random **** about this I’m going to start with the cons and go straight for the facts. First off VXGI shaders currently take about 5 minutes each to compile. So for every material you see in that room, add 5, and that’s how long it took me to set it up. It is most certainly resource intensive, but is still usable in an actual game. It only works on windows due to a DX11 dependency. It’s also still in beta 0.9, and suffers some crashes. But beyond that, it’s a fantastic CARD AGNOSTIC system that runs on ANY DX11/12 CARD. Unlike the previous 2 examples, it also has full specular tracing, allowing for incredible glossy reflections. It can even be used purely to generate ambient occlusion, which produces significantly better results than either HBAO+ or SSAO, and the AO is even plausible for use on PS4 and Xbox One. If you havent used it yet, it’s worth a shot.
You can find more information here:
Checkout the Github page here: (note you must be signed into Github to view the page or else you will get a 404 error)

Approximate Hybrid Ratracing (AHR)


This one deserves special attention. It was developed entirely by community member RyanTorant, and supports Diffuse Tracing, Specular Tracing, and Ambient Occlusion. It’s surprisingly fast, excels at tracing reflections, and is altogether a promising solution. As for upcoming features, point light support will be added, and RyanTorant’s recent posts indicate that he may be getting close to multiple bounces, and could possibly be the first one to have a multi-bounce solution.
Checkout his forum thread here:

Have any comments or questions? Please feel free to post them! I would like to know what people think about these compared to each other, which is something that isn’t found on each solution’s respective thread.

Great thread man, it deserves more views! I like that you put together each GI solution in UE4.

Would be very interested in seeing these done in an outdoors scene, or maybe one partly outdoors and partly indoors. Oddly enough, of the examples here so far, the LPVs, while not the greatest (or probably latest) implementation, seem to get the best results, minus the lack of AO. The problem with doing tests like this indoors however is that you rarely actually have a need for dynamic GI in an indoors environment (unless you have a massive level solely dynamically lit). Also of course, having scenes that are outdoors with overhanging ceilings, or maybe a damaged building where you can still see outside, etc is where you’ll see problems like light leaking come up the worst since you can’t just put a giant cube in the way to block the leaking without the player seeing.

Also for reference, could you post the framerates you were getting in each example? Of course it’ll vary depending on how you set things up, but performance is something to consider when comparing the systems.

Nice thread!
But I believe HFGI should have separate category =] It works regardless of DFGI, has differrent implementation and focused on GI for terrain only.

Also, LPV is developed by Lionhead studios and they pushed updates to LPV in UE4 implementation in last 2 months, so progress is right here :stuck_out_tongue:

Thanks for this! I really like me some dynamic GI, given I build my levels with BPs and can’t bake. I had only tried LPV


Super interesting thread…

They did? I thought we were stuck on the same version since it got discovered. Thanks for the update :smiley:

Anyways, nice thread and good overview.
You might want to update a few things. AHR now supports PBR and VXGI got multiple bounces in the most recent version ^^


Huh, must have missed that commit. Do you know around when it was, or what they changed with it? Would be very interested to know what changed since the initial release.

Here we go!

Oh wow, that was very recent. Seems like 4.8/4.9 are going to be very GI heavy releases at this rate.

You should add new image for AHR , is much better now.

Also there should be a image with Distance Field AO + GI, since there’s AO in VXGI.

bump. would love to see this updated

Newest AHR Image :slight_smile:

Shouldn’t this topic be clearly flagged as being completely obsolete?

That why ?

Should hevedy not post his GI technique?

Maybe not completely obsolete, but it would be nice to update the OP to reflect the recent changes like VXGI’s multi-bounce, AHR’s PBR, DFGI’s hiatus…
While those things were mentioned by others in the topic, some people might just read the original guide and not pay attention to the comments talking about the updtes.

Yeah that’s indeed my fear too.

-VXGI has seen many updates since this post. Also, it doesn’t nearly cost 5 min per material compile anymore. It’s totally workable now.
-Didn’t RyanB comment on Surfel GI development being shelved? Could probably come in handy to know that.
-LPV updates Yes/No. If it used to depend on Lionhead studios than future looks very grim.

Up to last month anyway (Feb), it seems there are occasional updates…