mercredi 13 avril 2016

atmospheric scattering on GPU

I just began to implement atmospheric scattering for my procedural planets. I started by trying to port on GPU my old CPU atmospheric scattering inspired from S.O'Neil samples, using a precomputed lookup table, which is here provided as a vertex texture.

Unfortunately this is a failure, it doesn't work at all ! After some reasearch on google I came quickly on an example of GPU implementation of this atmospheric scattering, by S.O'Neil himself. 

The main advantage of this is that the author added some mathematical simplification to his model, which involves that there's no more need of the precomputed lookup table. More generally, the code is simpler than my atmosphere scattering CPU to GPU port. Last but no least, once adapted to my engine framework, this new one works ! Here are some screengrabs bellow :





Aucun commentaire:

Enregistrer un commentaire