Giter Club home page Giter Club logo

brunetons-improved-atmospheric-scattering's Introduction

Brunetons-Improved-Atmospheric-Scattering

This a port to Unity of a updated and improved version of Brunetons atmospheric scatter published in 2017. The original was published in 2008 so is a bit old now.

The new version contains the follow improvements.

  • More descriptive function and variable names and extensive comments.

  • Improved texture coordinate mapping which removes the horizon artifact in the previous version.

  • Provides a option to store the single Mie scatter in the alpha channel (Rayleigh is in the rgb) or in the rgb of a separate texture.

  • Provides a example of how to combine with light shafts.

  • Converts the spectral radiance values to RGB luminance values as described in A Qualitative and Quantitative Evaluation of 8 Clear Sky Models (section 14.3)

  • Or precomputes luminance values instead of spectral radiance values, as described in Real-time Spectral Scattering in Large-scale Natural Participating Media (section 4.4). The precomputation phase is then slower than with the above option, but uses the same amount of GPU memory.

  • Adds support for the ozone layer, and for custom density profiles for air molecules and aerosols.

The demo uses a image effect shader as a example of how to use the scattering. The sphere rendered and its light shafts are hard coded into the shader as its just a example. Some work would be needed to convert this into a practical implementation

See home page for Unity package download.

AtmosphericScatter0

AtmosphericScatter1

AtmosphericScatter2

AtmosphericScatter3

AtmosphericScatter4

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.