June 2018
Intermediate to advanced
392 pages
8h 57m
English
With the scene prepared, we can now begin the process of experimenting with some of the built-in helper functions included with the UnityCG.cginc file. Double-click on the shader that was created for this scene in order to open it in your IDE of choice and insert the code given in the following steps:
Properties
{
_MainTex ("Base (RGB)", 2D) = "white" {}
_DesatValue ("Desaturate", Range(0,1)) = 0.5
}
We then need to make sure that we create the data connection between our Properties and CGPROGRAM blocks.