Sign in to follow this  

Volumetric LightRays

This topic is 4337 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm trying to find some resources on how to do nice realtime Volumetric lightrays (and not just extruded geometry with additive blending). Unfortunately, I've been unable to find any good resources. Anything on the web or in a book would be nice. This thread: http://www.gamedev.net/community/forums/topic.asp?topic_id=120983 has some cool stuff, but never any indication of how to do the volumetric lightrays (I actually kind of understand the explanation for making the volumetric shadows, but don't know how to do the actualy lightrays themself).

Share this post


Link to post
Share on other sites
I don't really remember the exact technique I used for the shots on that thread (I think it was still partially CPU assisted back then), I modified our light shaft rendering system countless times. But in essence, it always boils down to a volumetric visualization technique.

On todays hardware, you would probably use a slicing technique. You basically render multiple geometric slices through the shaft volume, orientated in parallel to the current camera plane. The slices are textured according to some 3D function - be it a 3D texture, a noise function, some pixel shader simulating a falloff cone, whatever. You then multiply with a projected shadowmap comparison (from the light point of view) to get volumetric shadows. Multiplying the result with an animated Perlin noise function simulates floating particles in the air, like dust or mist.

What effect exactly would you like to reproduce ?

Share this post


Link to post
Share on other sites
I was just wanting to do lightrays in general. Rays coming through a window, or rays shooting off of a spotlight, etc... Basically, what you demonstrated in the screenshots in that thread (nice stuff btw...)

My artists have been clamoring for some nice engine assited lightrays (currently doing the extruded geometry with additive blending, which they are unhappy with). Having the shadows in the lightrays is just a bonus (though the technique you describe seems fairly straight forward).

I need to read the explanation you just give a bit more, to try and digest it... still having trouble visualizing the technique :p

But thanks, it's giving me something to think about.

Share this post


Link to post
Share on other sites

This topic is 4337 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

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