Most of our shaders written in code will start with the declaration of the Shader, then its path in the Unity Inspector and finally the name that we assign to it (e.g. Shader “shader inspector path/shader name”).
Both the properties such as the SubShader and the Fallback are written inside the “Shader” field in ShaderLab declarative language.
Shader “InspectorPath / shaderName”
{
// Write ShaderLab code here
}
Since USB_simple_color has been declared as “Unlit/USB_simple_color” by default, if we want to assign it to a material, then we will have to go to the Unity Inspector, look for the Unlit path and then select “USB_simple_color”.
Both the path and the name of the shader can be changed as needed by the project organisation.
// default value
Shader “Unlit / USB_simple_color”
{
// write ShaderLab code here
}
// customized path to USB (Unity Shader Bible)
Shader “USB / USB_simple_color”
{
// write ShaderLab code here
}