Sign in to follow this  
InvalidPointer

Interesting new GI technique from Crytek

Recommended Posts

I just recently ran across this (Adobe PDF) little number and wasn't sure if anyone else had seen it yet. AFAIK it was shown at SIGGRAPH about a week ago. For those too lazy to read, the idea is to bridge instant-radiosity techniques like reflective shadow maps with spherical harmonic (technically zonal harmonics, which are a subset of the full monty) irradiance volumes by means of some clever upsampling and volume textures. They report framerates around ~110-160FPS on a GTX 280, including direct lighting, etc. Additionally, the technique seems to scale particularly well w.r.t. scene and lighting complexity. You even get glossy indirect reflections for free, if I understood correctly. It could probably be made faster simply because they pigeonhole themselves into using DirectX9 and the subsequent overhead associated with rendering into volume textures, but I (obviously) haven't messed around/experimented with it much. Your thoughts on this? Anyone up for trying to make a sample implementation? I also think this is what Geomerics is using for their GI solution, though I believe they use their much-touted geometric algebra implementation for the propagation process rather than zonal harmonics and blending. I had actually read up on the subject several years ago and had difficulty figuring out how such a math system could could actually be used to implement GI at the framerates they claim, but in hindsight it does seem extremely elegant. The whole hullabaloo placed on the quaternion rotation thing combined with the use of ZH (which also handles this simply) is what tipped me off. It could conceivably be done on the GPU to boot.

Share this post


Link to post
Share on other sites
It's an interesting technique, though it does have some drawbacks. They're not actually using zonal harmonics for the radiance volumes, they're using low order spherical harmonics. They use zonal harmonics as an easy way to convert certain light types into SH coefficients analytically. The most novel part of the technique IMO is the idea of propagating radiance through a volume using an iterative finite element approximation. I haven't seen that done for radiance before.

I'm pretty sure this is not what Geomerics are doing for their GI solution. The Geomerics solution has a geometry dependent pre-processing step whereas the Crytek approach requires no pre-processing. Geomerics' solution is an 'infinite bounce' radiosity solution as well whereas Crytek's only handles the first bounce. Geomerics also take into account occlusion for indirect bounces whereas Crytek ignores it (one of the major limitations of their approach, though I suspect the resulting artifacts will rarely be very obvious).

Glossy indirect reflections aren't really free in Crytek's approach. The information needed is available as a side effect of the approach at no extra cost but actually using it in a shader has a cost, the cost increasing as the surface becomes glossier.

It's good to see a number of developments for approaches to real time GI. I suspect we won't really see widespread adoption of these techniques until the next console generation but the more research and alternative techniques we see in the next few years the better.

Share this post


Link to post
Share on other sites
Quote:
Original post by mattnewportI'm pretty sure this is not what Geomerics are doing for their GI solution. The Geomerics solution has a geometry dependent pre-processing step whereas the Crytek approach requires no pre-processing. Geomerics' solution is an 'infinite bounce' radiosity solution as well whereas Crytek's only handles the first bounce.


I second that.

I'm pretty sure that Geomerics are using an approach such as wavelot radiosity and if not wavelets then some other recursive hierarchical basis function that is precalculated.

I think Crytek's approach is nice because it avoids the preprocess time but it's not the bread & butter of real time GI in my opinion. Their reason for avoiding any solution that has preprocess time is because the needs of teams to produce content demands high iteration. I agree that high iteration is important but,

1) Spawning a process to compute the radiosity solution and then having artists tweak the lighting in real time is already a huge productivity boost. They can start the preprocess build and work on something else while waiting for it to finish.

2) Offline solutions for calculating GI is becoming lightning fast (not real time and requires specific hardware). Siggraph had another demo of calculating GI in interactive rates on a GPU after a small 2 min build process. I could imagine using a farm of the NVidia 8800's and calculating the radiosity solution fairly quickly.

The advantage of a precalculated approach lets the radiosity resolve to an equilibrium (e.g. "infinite" bounces). It also lets you push other calculations into the preprocess. You could put occlusion, glossy reflections, volumetric effects, subsurface scattering or anything else that can be approximated with low frequency. Additionally, wavelets capture a ton of more detail then spherical harmonics can.

Quote:
Geomerics also take into account occlusion for indirect bounces whereas Crytek ignores it (one of the major limitations of their approach, though I suspect the resulting artifacts will rarely be very obvious)


In my opinion when you have radiosity that bleeds too much and lacks occlusion it can make a scene look very unrealistic.

-= Dave

Share this post


Link to post
Share on other sites
Felt this was due for an update/clarification. (especially considering the IOTD is currently showcasing an early implementation of this technique at time of writing)

Quote:
Original post by David Neubelt
Quote:
Original post by mattnewportI'm pretty sure this is not what Geomerics are doing for their GI solution. The Geomerics solution has a geometry dependent pre-processing step whereas the Crytek approach requires no pre-processing. Geomerics' solution is an 'infinite bounce' radiosity solution as well whereas Crytek's only handles the first bounce.


I second that.

I'm pretty sure that Geomerics are using an approach such as wavelet radiosity and if not wavelets then some other recursive hierarchical basis function that is precalculated.

True. I had the Geomerics solution confused with the Fantasy Labs product; just disregard all that. Some research cleared that up, and it appears you are correct with the PRT-based explanation.

Quote:
Original post by David Neubelt
I think Crytek's approach is nice because it avoids the preprocess time but it's not the bread & butter of real time GI in my opinion. Their reason for avoiding any solution that has preprocess time is because the needs of teams to produce content demands high iteration. I agree that high iteration is important but,

1) Spawning a process to compute the radiosity solution and then having artists tweak the lighting in real time is already a huge productivity boost. They can start the preprocess build and work on something else while waiting for it to finish.

2) Offline solutions for calculating GI is becoming lightning fast (not real time and requires specific hardware). Siggraph had another demo of calculating GI in interactive rates on a GPU after a small 2 min build process. I could imagine using a farm of the NVidia 8800's and calculating the radiosity solution fairly quickly.

Perhaps, but I generally value a reasonably high-quality simulation that is entirely dynamic over one that looks a little nicer but is much more static in nature. Iteration times improve drastically, as you mention, but additionally you have much more freedom in terms of environmental interaction. There's also nothing preventing you from precomputing a number of gather points/static lights and then exploiting this framework to apply their influence very cleanly to dynamic models, etc. which is a major shortcoming of lightmaps and related techniques. You can fake it just fine, sure, with convoluted traces and all manner of artistic fudging, but that's hardly free either. This is just a simple lookup into a reasonably small volume texture. If you want to go really nuts, you can precompute a 128x128x128 or even 256x256x256 texture and just use that for (relatively speaking) very high-frequency lighting information. The irradiance volume technique is pretty cool that way.

Quote:
Original post by David Neubelt
The advantage of a precalculated approach lets the radiosity resolve to an equilibrium (e.g. "infinite" bounces). It also lets you push other calculations into the preprocess. You could put occlusion, glossy reflections, volumetric effects, subsurface scattering or anything else that can be approximated with low frequency. Additionally, wavelets capture a ton of more detail then spherical harmonics can.

Quote:
Geomerics also take into account occlusion for indirect bounces whereas Crytek ignores it (one of the major limitations of their approach, though I suspect the resulting artifacts will rarely be very obvious)


In my opinion when you have radiosity that bleeds too much and lacks occlusion it can make a scene look very unrealistic.

-= Dave

They fake it with SSAO, but I think you could use something like the antiradiance approach and handle everything in a somewhat unified way.

[Edited by - InvalidPointer on August 25, 2009 12:38:26 PM]

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this