Getting ready

To get started with this recipe, you will need to have Unity running and must have a project opened. As mentioned before, there will also be a Unity project included with this cookbook, so you can use that one as well and simply add your own custom shaders to it as you step through each recipe. With this completed, you are now ready to step into the wonderful world of real-time shading!

Before getting into our first shader, let's create a small scene for us to work with:

  1. Let's create a scene by navigating to File | New Scene.
  2. Once you create the scene, create a plane to act as the ground by going to GameObject | 3D Objects | Plane in the Unity editor. Next, select the object in the Hierarchy tab and then go into the Inspector ...

Get Unity 2018 Shaders and Effects Cookbook now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.