# Realtime Dynamic GI + Reflections + AO + Emissive - AHR

**URL:** <https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923>\
**Category:** Game Development\
**Tags:** unreal-engine\
**Created:** [September 24, 2014, 1:58am UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923 "2014-09-24T01:58:17Z")\
**Posts on this page:** 20\
**Page:** 56

<div class="post-metadata">

**Author:** ![ErinE2](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@ErinE2](https://forums.unrealengine.com/u/ErinE2)\
**Post date:** [November 4, 2015, 2:59am UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1115 "2015-11-04T02:59:38Z")

</div>

The link to get to the public release doesn’t seem to work anymore. Would love to be able to try out! It’s a really interesting technique.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_bcf66e2c](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_bcf66e2c](https://forums.unrealengine.com/u/anonymous_user_bcf66e2c)\
**Post date:** [November 4, 2015, 3:33am UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1116 "2015-11-04T03:33:58Z")

</div>

> [@ErinE2;413595](#):
>
> The link to get to the public release doesn’t seem to work anymore. Would love to be able to try out! It’s a really interesting technique.

Make sure you are logged into your account and its linked to your UE4 account. As the link will show a 404 error otherwise.

---

<div class="post-metadata">

**Author:** ![RyanTorant](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@RyanTorant](https://forums.unrealengine.com/u/RyanTorant)\
**Post date:** [November 9, 2015, 12:41am UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1117 "2015-11-09T00:41:54Z")

</div>

Sorry for the radio silence people.  
The roughness based reflections turned out to be more complex than expected, so that’s on hold. Nevertheless, not everything is bad news!  
Next commit, that should be up tomorrow, will have two important changes:  
a) The blur is stage is now about twice as fast. Good news for the ones on low end!  
b) Removed most of the flickering when moving bounds or objects, so now the movable bounds are actually useful! Really excited about one, as it opens new possibilities for AHR, makes it much more flexible.  
There are other small changes, mainly two new settings, one to tweak the emissive intensity in the voxel grid, and the other to control (or disable) adding albedo to the voxel grid.  
Will give you people a heads up when it’s on

---

<div class="post-metadata">

**Author:** ![DylserX](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/dylserx/32/755714_2.png) [@DylserX](https://forums.unrealengine.com/u/DylserX)\
**Post date:** [November 9, 2015, 3:11am UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1118 "2015-11-09T03:11:03Z")

</div>

Ahh sucks about the reflections, but oh my god the movable bounds and tweakables sound , that will allow me test with my full game map 😃  
Great work !

---

<div class="post-metadata">

**Author:** ![Keiyentai](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Keiyentai](https://forums.unrealengine.com/u/Keiyentai)\
**Post date:** [November 9, 2015, 3:20am UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1119 "2015-11-09T03:20:45Z")

</div>

Ooh new additions. Looks like I will have to DL/ReCompile. I noticed the flickering my self on a couple things but thought it was due to the current nVidia Driver being odd since people on the NVidia and EvGa forums reporting “flickering” in games/apps. Off I go.

---

<div class="post-metadata">

**Author:** ![RyanTorant](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@RyanTorant](https://forums.unrealengine.com/u/RyanTorant)\
**Post date:** [November 9, 2015, 11:41am UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1120 "2015-11-09T11:41:35Z")

</div>

> [@Keiyentai;416531](#):
>
> Ooh new additions. Looks like I will have to DL/ReCompile. I noticed the flickering my self on a couple things but thought it was due to the current nVidia Driver being odd since people on the NVidia and EvGa forums reporting “flickering” in games/apps. Off I go.

Just a warning, is not on yet.

---

<div class="post-metadata">

**Author:** ![RyanTorant](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@RyanTorant](https://forums.unrealengine.com/u/RyanTorant)\
**Post date:** [November 10, 2015, 2:21am UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1121 "2015-11-10T02:21:30Z")

</div>

Ok, it’s up now.  
Will get a commit up in a few days that will improve a bit voxelization performance on the data copy stage, cause I added a voxel filter stage (just a blur actually) but it was a lazy implementation, just wanted to check if it worked. Will have it fixed in a few days.  
Another thing to keep in mind is that only the objects inside the bounds are voxelized. can be problematic, and specially with movable bounds, as you can have an object that casts shadows to some part of the scene, and affects the GI, but it’s not on the voxelization volume. Need to add a visibility test for the shadow map rendering stage.  
Like I said, will give it more polish week.

---

<div class="post-metadata">

**Author:** ![RyanTorant](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@RyanTorant](https://forums.unrealengine.com/u/RyanTorant)\
**Post date:** [November 10, 2015, 2:31am UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1122 "2015-11-10T02:31:12Z")

</div>

Oh, btw, to solve the flickering I had to clamp the positions to per voxel increments (for the voxelization only, didn’t changed the position you see), but that might require re-tweaking some objects positions

---

<div class="post-metadata">

**Author:** ![starseeker](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@starseeker](https://forums.unrealengine.com/u/starseeker)\
**Post date:** [November 10, 2015, 12:05pm UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1123 "2015-11-10T12:05:14Z")

</div>

thread is .

---

<div class="post-metadata">

**Author:** ![starseeker](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@starseeker](https://forums.unrealengine.com/u/starseeker)\
**Post date:** [November 10, 2015, 12:08pm UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1124 "2015-11-10T12:08:51Z")

</div>

> [@Denny;409040](#):
>
> Great work so far ! I still think you deserve some monetary reward for , it is professional level stuff after all. 🙂

Agree, but better is made it as part of the engine, & Epic to pay you, or we can pay you as a community (people who will use it of course)

---

<div class="post-metadata">

**Author:** ![Keiyentai](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Keiyentai](https://forums.unrealengine.com/u/Keiyentai)\
**Post date:** [November 10, 2015, 11:35pm UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1125 "2015-11-10T23:35:39Z")

</div>

Sweet will recompile it again thought it seemed the same lol. Might do a clean install. Once again amazing work .

---

<div class="post-metadata">

**Author:** ![RyanTorant](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@RyanTorant](https://forums.unrealengine.com/u/RyanTorant)\
**Post date:** [November 12, 2015, 12:34am UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1126 "2015-11-12T00:34:00Z")

</div>

Guys, 4.10 update is up on . It was a painless merge tbh. time run setup.bat after downloading, as I think some dependencies changed.  
EDIT: Also pushed a small commit that ensures all objects that can cast a shadow in the bounds are rendered in the shadow maps, even if the objects themselves are outside the bounds.

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_ff2d5873](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_ff2d5873](https://forums.unrealengine.com/u/anonymous_user_ff2d5873)\
**Post date:** [November 12, 2015, 12:13pm UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1127 "2015-11-12T12:13:53Z")

</div>

Aw gawd i love you, i’ve been making wombo combo semi handmade patches these days to take your changes to the latest vanilla Unreal Engine source code in order to build it…  
Now i can study your work with ease! Thanks!!!

EDIT: Btw man, you should try to find out how to remove that 2 - 3 commits that you added the test scene in the past.  
It really blew off your commit history, and cloning your repo gets heavy by the excess data that you don’t need…

---

<div class="post-metadata">

**Author:** ![RyanTorant](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@RyanTorant](https://forums.unrealengine.com/u/RyanTorant)\
**Post date:** [November 12, 2015, 12:41pm UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1128 "2015-11-12T12:41:19Z")

</div>

> [@agorg\_louk;418844](#):
>
> Aw gawd i love you, i’ve been making wombo combo semi handmade patches these days to take your changes to the latest vanilla Unreal Engine source code in order to build it…  
> Now i can study your work with ease! Thanks!!!
> 
> EDIT: Btw man, you should try to find out how to remove that 2 - 3 commits that you added the test scene in the past.  
> It really blew off your commit history, and cloning your repo gets heavy by the excess data that you don’t need…

What! That’s still there? Thought I had removed it. Will check it out

---

<div class="post-metadata">

**Author:** ![ImmortalEmperor](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/immortalemperor/32/466268_2.png) [@ImmortalEmperor](https://forums.unrealengine.com/u/ImmortalEmperor)\
**Post date:** [November 12, 2015, 10:58pm UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1129 "2015-11-12T22:58:00Z")

</div>

Hey , big fan of your work, been following thread for a while.

> [@;409352](#):
>
> Tricky question. Will talk about AHR, as I have no idea about VXGI limits. Technically, you could have as much distance as you want, it’s just making the bounds as large as the entire scene and having a high sample count. In reality, there are limitations, for example, you wont get 1km long rays at a 1 cm voxel size, it’s all on finding the balance between sample count, voxel size and bounds size.  
> Let’s do some math. Given that you mentioned large scenes, I’ll say you need to use a movable bound. Let’s say 100m by 100m by 20 m(up), which I think it’s about what you’ll need in most scenes, as you can’t really see so much detail after 100 m. I suggest to add an ambient cubemap to fill in the rest.  
> Also lets say a voxel size of 0.25 m and a sample count of 32. 25 cm precision on a 100m sounds like enough, but you could go even lower, to say 20 or 15, just remember that memory usage is cubic with the number of voxels. With a that settings, the voxel grids will take about 40 mb for t( there’s a few of them, but at most we are talking about 50 mb. The math is simpy SizeX/VoxSize \* SizeY/VoxSize \* SizeZ/VoxSize, and then multiply by 4 for the emissive grid, and divide by 8 for the binary grid), and the 32 samples gives us a range of 8 m.  
> The idea behind all talk is that for most uses, range should be enough, but will require tweaking the settings.

I’m a little curious and probably missed the explanation earlier but are you voxelizing everything in the bounds at run-time? or are the bounds fetching pre-voxelized static geometry and running a union with anything dynamic?

---

<div class="post-metadata">

**Author:** ![RyanTorant](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@RyanTorant](https://forums.unrealengine.com/u/RyanTorant)\
**Post date:** [November 12, 2015, 11:04pm UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1130 "2015-11-12T23:04:38Z")

</div>

> [@ImmortalEmperor;419191](#):
>
> Hey , big fan of your work, been following thread for a while.
> 
> I’m a little curious and probably missed the explanation earlier but are you voxelizing everything in the bounds at run-time? or are the bounds fetching pre-voxelized static geometry and running a union with anything dynamic?

Voxelizing everything inside the bounds every frame. I used to only voxelize static, back when I was using RSM for lighting and the voxels only stored the albedo. It’s possible to do that separation, but it requires some rework of the algorithms, mainly injecting light directly into the voxels instead of rendering the lighting in the voxelization pass. Will see if I do that eventually.

---

<div class="post-metadata">

**Author:** ![ImmortalEmperor](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/immortalemperor/32/466268_2.png) [@ImmortalEmperor](https://forums.unrealengine.com/u/ImmortalEmperor)\
**Post date:** [November 12, 2015, 11:28pm UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1131 "2015-11-12T23:28:51Z")

</div>

> [@;419193](#):
>
> Voxelizing everything inside the bounds every frame. I used to only voxelize static, back when I was using RSM for lighting and the voxels only stored the albedo. It’s possible to do that separation, but it requires some rework of the algorithms, mainly injecting light directly into the voxels instead of rendering the lighting in the voxelization pass. Will see if I do that eventually.

Cool haven’t had much time -to much university work- to get into the Unreal back end but I’ll be looking to poke around the engine and your code in the coming holidays 🙂

---

<div class="post-metadata">

**Author:** ![anonymous\_user\_648a10e3](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@anonymous\_user\_648a10e3](https://forums.unrealengine.com/u/anonymous_user_648a10e3)\
**Post date:** [November 13, 2015, 10:28pm UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1132 "2015-11-13T22:28:07Z")

</div>

Hey, I’ve got a problem downloading any version beyond 4.5 apparently. The cadviz/AHRUnrealEngine link appears to have older versions on it only, and the link on the first page gives a 404 despite my having an account. I think I’m doing something wrong. ;(

---

<div class="post-metadata">

**Author:** ![RyanTorant](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@RyanTorant](https://forums.unrealengine.com/u/RyanTorant)\
**Post date:** [November 13, 2015, 10:52pm UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1133 "2015-11-13T22:52:29Z")

</div>

> [@StrokeMeGoat;419789](#):
>
> Hey, I’ve got a problem downloading any version beyond 4.5 apparently. The cadviz/AHRUnrealEngine link appears to have older versions on it only, and the link on the first page gives a 404 despite my having an account. I think I’m doing something wrong. ;(

Not sure what “cadviz” link you mean. In any case, the link is : https://.com//UnrealEngine , and you have to make sure you are logged in first, and that your Unreal Engine account is linked to your Git Hub account.

---

<div class="post-metadata">

**Author:** ![DennG](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@DennG](https://forums.unrealengine.com/u/DennG)\
**Post date:** [November 15, 2015, 4:24pm UTC](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923/1134 "2015-11-15T16:24:36Z")

</div>

Hi ,

is AHR already stable enough to use it for a real project?  
Could you please put the setup instructions in the first post? Or tell my where I can find it.

All the best  
Dennis

[Previous page](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923.md?page=55)

[Next page](https://forums.unrealengine.com/t/realtime-dynamic-gi-reflections-ao-emissive-ahr/11923.md?page=57)
