Jump to content

  • Log In with Google      Sign In   
  • Create Account


We have 4 x Pro Licences (valued at $59 each) for 2d modular animation software Spriter to give away in this Thursday's GDNet Direct email newsletter.

Read more in this forum topic or make sure you're signed up (from the right-hand sidebar on the homepage) and read Thursday's newsletter to get in the running!

Frenetic Pony

Member Since 30 Oct 2011
Offline Last Active Yesterday, 10:04 PM

Topics I've Started

Dynamic cubemap relighting (random though)

13 September 2014 - 05:14 PM

This is too long for twitter, and I'm busy pecking away at other things, but.


Cheap idea for relighting the increasingly popular cubemap/image based lighting solution. Just store depth/normal/abedo of each cubemap face, and relight N cubemap faces a frame with the primary light/update the skybox. As long as you store the/apply the baked roughness lookups into the mipmaps, and apply such to the final output cubemaps you use for lighting, you get a dynamically re-lightable image based lighting system.


True you can't use lightmaps (unless you update those separately, perfectly possible) and can't get those pre-computed multiple bounces, but some price has to be paid for dynamic re-lighting, and since you're just re-shading a few 256x256 targets (and very basic shading at that) it's not going to cost much, and you can use whatever pre-computed ambient occlusion you want. If memory is a concern one could compress the albedo and normals down to two channels apiece, I don't see the quality of such being terribly important before lighting is applied.


Just an idea for now, but it seemed promising enough. There's still the other issues of cubemap lighting, parallax projection and light leaking and etc. but that would be solved separately and is needed research anyway.

Voxel GI: Environmental Fill Lights

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.

"Next" Gen Reflections

17 December 2011 - 03:25 PM

So I was thinking about how to do dynamic reflections, and a possible way occurred to me.

If your scene is mostly static you could store multiple environment maps, pulling whatever tricks you like. Corrected projections and etc.

The main point is you not only store albedo, but normal, depth, and a full on material if you want to go that way.

You then throw your environment maps onto your normal geometry, but store the results in a separate g-buffer.

You'd then do a lighting pass on this separate g-buffer, call if a reflection buffer if your like.

Your then resolve your reflection buffer into your normal buffer with whatever bdrf's your using.

There we are, rather expensive but dynamically lit reflections for everything. Of course there would be a lot of weird little glitches and things to consider, how would you cull shadow maps correctly, how would you deal with dynamic objects? Etc. But reflections need to be improved somehow, raytracing is just going to go insane on taking up resources no matter what tricks you pull. That billboard trick Epic pulled with their Samaritan demo did look neat, but I suspect only really looks good when you have a ton of light sources to fill up the screen.

Any thoughts?

Cascaded Point Lights?

26 November 2011 - 12:47 AM

I was thinking about what to do with all that "next gen" power with whatever the new consoles will be called, and one of the things I've always wanted to see was lighting with proper quadratic falloff all the way; or as close as reasonably possible and looks right for whatever game scenario it's in.

But obviously a single shadow map, even if it's a full on cubemap with 8k resolution is still going to come up short and highly aliased at a long enough distance.

Now there's always "focusing", with all the trouble that brings, but has anyone come up with some sort of "cascaded" point light shadow map (such as would be possible)? Or any other way of stretching out a reasonably sized shadow map to some ridiculous amount of distance away?