O'Reilly logo

Unity Shaders and Effects Cookbook by Kenny Lammers

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

GUI and transparency

Now that we have covered the basics of creating transparent Shaders and learned how we can control the order in which objects are drawn, let's take a look at a practical production scenario in which we would need to use transparency and have control over the order in which the transparent objects are drawn.

Creating GUIs for Unity is definitely a huge task. One could use the Built-in OnGUI() function to create their GUI using a bunch of 2D images with alpha, and let Unity draw the images to the screen. Or, one could create an actual 3D GUI system in which you can actually see your GUI elements in the scene view, inside the Unity editor. We are going to take a look at this last approach. We need to be able to use a sheet of ...

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