Jump to content
  • Advertisement
Sign in to follow this  
  • entries
  • comments
  • views

Atmospheric Scattering

Sign in to follow this  


Not much to say, I've implemented atmospheric scattering at last. It took me ages to figure out the equations and how you can actually implement them in real time. It looks pretty good though, so I figure it's worth it.

As yet it's totally unoptimised. I've still to get rid of my hacky IM sphere drawing code, and shift to proper VBOs. Then I'm going to see how much of the scattering calculations I can move to a vertex shader. I'm quietly confidant that you can fit most of it in and get a great bonus, since most of it is standard vector operations and lookups - the only problem might be the exp() calls for the attenuation calculation.

Once everything's drawing right, I've decided to get a bit of variety and work on rendering moons, stars, asteroids, nebulae and things like that. After I've got a baseline for the rendering, I'll go back and work in the procedural generation of the textures. On the other hand, there aren't any real sources for pre-made geometry of nebulae, so I'd probably have to do the generation before the rendering. If I remember right, Ysaneya did his nebulae via navier stokes equations - I might have to figure out a less flexible more hacky way since I don't think I'm up to that challenge.
Sign in to follow this  


Recommended Comments

Thanks guys :). Once I've cleaned this up the next task will be moons, which will mean shadow rendering :X.

Share this comment

Link to comment

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
  • Advertisement

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!