Finally, we use a configurable extra-terrestrial solar irradiance with 3 constants [5]. We multiply 3 spectrum samples L(λr), L(λg), and L(λb) by these 3 constants to get the RGB color. This gives us a relatively accurate approximation compared to spectral rendering with a large number of wavelengths [6]. See the difference between before and after in Figure 9.

* In computer graphics, spectral rendering is a technique in which a scene's light transport is modelled with actual wavelengths [7].

**Future improvements**

The next iteration aims to add multiple scattering, and some parameter values (such as the thickness of the atmosphere) may be adjusted. We also plan to extend the method to support non-opaque objects (transparent, volumetric, etc.).

For the challenges/features we see in the future, we need to think about how to integrate the weather with atmospheric scattering on our planet. I assume this step will be challenging.

If you are interested in joining us to tackle these challenges or even invent an entirely novel solution, then check out our career page.

**Reference**

[1] Nishita 1993, Display of The Earth Taking into Account Atmospheric Scattering -

http://nishitalab.org/user/nis/cdrom/sig93_nis.pdf

[2] O’Neil, Accurate Atmospheric Scattering - https://developer.nvidia.com/gpugems/gpugems2/part-ii-shading-lighting-and-shadows/chapter-16-accurate-atmospheric-scattering

[3] Bruneton & Neyret 2008, Precomputed Atmospheric Scattering - https://hal.inria.fr/inria-00288758/document

[4] Angular Diameter - https://www.astronomy.swin.edu.au/cosmos/A/Angular+Diameter

[5] Precomputed Atmospheric Scattering: a New Implementation - https://ebruneton.github.io/precomputed_atmospheric_scattering/

[6] A Qualitative and Quantitative Evaluation of 8 Clear Sky Models - https://arxiv.org/pdf/1612.04336.pdf

[7] Spectral rendering - Spectral rendering

**Appendix A**

Reconstruct position from UV and depth

` ````
```

**Appendix B**

Calculate the Rayleigh constant

` ````
```

Calculate the Rayleigh scattering coefficient

` ````
```

**Appendix C**

Ray sphere intersection

` ````
```

**Appendix D**

Get the path to ray march on the 1st ray

` ````
```

**Appendix E**

Get optical depth along the light direction

` ````
```

**Appendix F**

Phase function

` ````
```

**Appendix G**

Combine everything and get the final scattering result

` ````
```

**Appendix H**

Generate lookup table

` ````
```