O'Reilly logo

Mastering Unity Shaders and Effects by Jamie Dean

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Improving the planet's atmosphere

In the first chapter, we added materials to the spacecraft repair scene using Unity's Standard Shaders. We also created a Standard Specular material for the planet Ridley VI to show its dramatic stormy environment.

At this point, we will write a custom shader to give it more of an atmospheric effect.

Rather than reflecting light in the same way as other solid objects, the layers of gas that surround many planets create a haze around them.

We will create something like this with a custom shader.

Creating the custom planet shader

We will start by creating another shader in the Unity project:

  1. In the Project panel, click on the PACKT_Shaders folder.

    The folder's contents will become visible in the Assets panel.

    The folder ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required