In this multi-part video series, we cover the basics of using ShaderGraph with the ScriptableRenderPipeline from scratch.

Follow this two-hour guide to getting started in ShaderGraph. We begin with a blank project and then build a few ShaderGraphs step-by-step.

Click on each thumbnail below to access the videos.

Getting Started

Let’s begin by setting up a new Unity Project.

Note: this feature is currently in Preview for Unity 2018.3.0. We recommend that you use the High Definition Render Pipeline to follow along with the tutorial with Unity 2018.3.0

In this next episode, we create our first ShaderGraph and color a GameObject with a custom color. Essentially this amounts to the “Hello,world!” of shader writing, but here we learn how to navigate the interface and basic workflow.

Mesh Highlight ShaderGraph

In these videos, we create a simple shader that glows around the edges with the Fresnel effect.

We can make this glow highlight a little more complex by layering it on top of user-defined textures, which we can expose in the Inspector using Properties.

Here’s a basic usage example of our shader. We make a custom script to highlight objects as we hover the mouse over them at runtime.

Finally let’s “refactor” our ShaderGraph using a structure called a SubGraph, packaging several nodes into a small re-usable asset.

Forcefield ShaderGraph

Let’s extend what we learned in the last few videos and create a more advanced ShaderGraph. We can modify the Mesh Highlighter ShaderGraph and create a forcefield shader, complete with animated textures.

You will learn essential usage of common ShaderGraph nodes, including:

the Time node

TextureAsset2D and TextureSampler nodes

basic Math nodes

common Input nodes

Though we have only scratched the surface of what you can do with ShaderGraph, this should build a solid foundation for diving deeper into Unity’s visual shader editor.

Did you enjoy the series? Please let me know if you want to see more videos like this!

Remember to subscribe to the full course, Unity Lighting for Game Development on Udemy (follow the link for a discount)! We will feature some more ShaderGraph examples in addition to covering the fundamentals of CG lighting for game development.

Each month one lucky subscriber will be selected to win a free premium course! Just sign up below to make sure you’re included in the monthly drawing. ﻿