Jump to content

  • Log In with Google      Sign In   
  • Create Account

Voxel GI: Environmental Fill Lights


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
7 replies to this topic

#1 Frenetic Pony   Members   -  Reputation: 1318

Like
0Likes
Like

Posted 23 October 2012 - 05:06 PM

So everyone's really excited about voxel cone tracing, a realtime raytracing alike that EPIC is attempting to make work in Unreal Engine 4: http://www.unrealengine.com/files/misc/The_Technology_Behind_the_Elemental_Demo_16x9_%282%29.pdf

Right now everyone that's tried this, Nvidia and Epic, have only used it for tracing bounce lighting. But what you're doing is tracing the entire environment, and since you're already doing that, why not use the rest of the information you're getting as well?

Now I know that you can do ambient occlusion with this, but I was wondering why you wouldn't just replace an ambient term (assuming you had one) with an environmental one? Have the entire environment cast light onto itself, you'd get directional colored lighting for free! Turns out Pixar was ahead of me: http://graphics.pixar.com/library/PointBasedGlobalIlluminationForMovieProduction/Slides.pdf

They already use this for their GI, calling them "fill lights". Basically each voxelized point would act as if it was transmitting light, regardless of whether it was being directly hit by a light source (which you also add to the luminance). But you don't actually show this luminance in your final render. Instead you'd then cone trace into this and gather as normal, gathering luminance from everything, giving you free colored, directional light instead of only bounce light.

For a specular hack you could just have your specular cone gather the direct "radiated" color/luminance, maybe desaturated for the fill light value to emulate the reflection coming from bounced lighting.

Sponsor:

#2 Butabee   Members   -  Reputation: 236

Like
0Likes
Like

Posted 23 October 2012 - 08:28 PM

i've been messing around with the same idea as in that Pixar doc. It's a little modified but it's the same idea. I'm using a simple BRDF of leaving light/incoming light, along with adding up directly lit colors.

I don't have any complex scenes to show but here's a sample version.

This is done on the GPU.



Also, here's the same scene turned into meta balls. lol.



#3 Hodgman   Moderators   -  Reputation: 30389

Like
0Likes
Like

Posted 23 October 2012 - 08:39 PM

Basically each voxelized point would act as if it was transmitting light, regardless of whether it was being directly hit by a light source (which you also add to the luminance). But you don't actually show this luminance in your final render. Instead you'd then cone trace into this and gather as normal, gathering luminance from everything, giving you free colored, directional light instead of only bounce light

Doesn't the Epic demo do this? They can just paint an emitting light source onto a wall, and it generates direct light and bounce light for the scene.

#4 Frenetic Pony   Members   -  Reputation: 1318

Like
0Likes
Like

Posted 23 October 2012 - 10:14 PM


Basically each voxelized point would act as if it was transmitting light, regardless of whether it was being directly hit by a light source (which you also add to the luminance). But you don't actually show this luminance in your final render. Instead you'd then cone trace into this and gather as normal, gathering luminance from everything, giving you free colored, directional light instead of only bounce light

Doesn't the Epic demo do this? They can just paint an emitting light source onto a wall, and it generates direct light and bounce light for the scene.


Well yes, but only standard glow map stuff; fire, lava, neon lights, energy producing stuff that you'd just normally get standard glow from. What this is, is to do that for everything, every solid surface is considered to be light emitting according to whatever artist defined level you want, but only for the purposes of cone tracing, you don't actually add this to the final target directly.

Instead you only consider it when you are cone tracing, and you are then picking up light from every surface, this creates a minimum amount of light for the final rendered image, assuming everything isn't black, much like an ambient term. But unlike an ambient term you are getting directional, colored information on everything, and with the hack mentioned specular reflections from every surface.

It's not physically based, at all, certainly. But then again neither is ambient occlusion really. Think of it kind of like the inverse of that actually. Ambient, environment based lighting.

Edited by Frenetic Pony, 24 October 2012 - 03:14 AM.


#5 Ashaman73   Crossbones+   -  Reputation: 7525

Like
0Likes
Like

Posted 24 October 2012 - 03:50 AM

Instead you only consider it when you are cone tracing, and you are then picking up light from every surface, this creates a minimum amount of light for the final rendered image, assuming everything isn't black, much like an ambient term. But unlike an ambient term you are getting directional, colored information on everything, and with the hack mentioned specular reflections from every surface.

Well, this already happens in the demo, doesn't it ? I'm refereing to the part of the animated hand where you can acutally see the hand reflection on the floor (=specular reflection).

The issue is, that voxels are really memory hungry (LVP with 3 LODs of standard voxel maps) or more calculation expensive and still memory hungry (sparse voxel in U4), therefore the resolution would be quite small for everything like a direct light term. We can currently calcualte the direct lit surfaces perfectly, so no need to take a step back, direct lit shadows are also ok, the current most missing feature are indirect light bounces which are approached by CE & U4.

#6 MJP   Moderators   -  Reputation: 11384

Like
0Likes
Like

Posted 24 October 2012 - 12:19 PM

Sounds pretty hacky. IMO a better approach is to feed back the results of your GI solve from the previous frame into the solve for the current frame. If you do this you can effectively get "unlimited bounces", and will look good as long as your solve actually converges. However it's probably too expensive for a voxel cone-tracing set up, since you use a different representation of your scene for rendering and tracing.

#7 Frenetic Pony   Members   -  Reputation: 1318

Like
0Likes
Like

Posted 24 October 2012 - 12:31 PM


Instead you only consider it when you are cone tracing, and you are then picking up light from every surface, this creates a minimum amount of light for the final rendered image, assuming everything isn't black, much like an ambient term. But unlike an ambient term you are getting directional, colored information on everything, and with the hack mentioned specular reflections from every surface.

Well, this already happens in the demo, doesn't it ? I'm refereing to the part of the animated hand where you can acutally see the hand reflection on the floor (=specular reflection).

The issue is, that voxels are really memory hungry (LVP with 3 LODs of standard voxel maps) or more calculation expensive and still memory hungry (sparse voxel in U4), therefore the resolution would be quite small for everything like a direct light term. We can currently calcualte the direct lit surfaces perfectly, so no need to take a step back, direct lit shadows are also ok, the current most missing feature are indirect light bounces which are approached by CE & U4.


Not as far as I know. From the hand demo, the original NVIDIA stuff, it's a double light bounce as I understand it. But maybe they did? I suppose you'd have to ask them. I know it's not done in the "Elemental" UE4 demo.

Sounds pretty hacky. IMO a better approach is to feed back the results of your GI solve from the previous frame into the solve for the current frame. If you do this you can effectively get "unlimited bounces", and will look good as long as your solve actually converges. However it's probably too expensive for a voxel cone-tracing set up, since you use a different representation of your scene for rendering and tracing.


It IS pretty hacky. But as you pointed out "Unlimited" bounces is going to be far, far too expensive for realtime. This on the other hand is essentially free. And hey, if it's good enough for Pixar, arguably the maker of the most gorgeous CG cartoons out their, then it's good enough for a game. Especially that "free" if you're doing the rest already part.

Edited by Frenetic Pony, 24 October 2012 - 12:32 PM.


#8 Butabee   Members   -  Reputation: 236

Like
0Likes
Like

Posted 24 October 2012 - 04:39 PM

I think some more testing should be done with this. I don't want to spam this thread with my videos but I've fixed some problems with my version, and it looks pretty good.

I should be able to process GI from about 16k points for the roughly the same cost as 2k since I can process points from more than one constant buffer in one loop.




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS