I am quite new to shaders and have been searching for a full list of Unity shader properties. I haven’t found any such documentation. What I found was Unity - Manual: ShaderLab: defining material properties. Where can I find a full list of properties and their functions?
UPDATE
An example was given in above link showing the list of properties for a water shader namely, _WaveScale, _Fresnel, _BumpMap and so on. Knowing these specific properties make it easier to arrive at a solution. I recently tried coding something similar to a stroke before I found out about the following properties.
There’s no “full list” as the properties names are completely arbitrary. “_Stroke” could be named “_MyFriendBob” or “_WaveScale” and still do the same thing as long as the shader code used that property to drive the stroke width.
Example of a very basic shader:
Shader "Solid Color Example 1"
{
Properties
{
// define color property
_Color("Color", Color) = (1.0, 1.0, 1.0, 1.0)
}
SubShader
{
Pass
{
CGPROGRAM
#pragma vertex vert_img
#pragma fragment frag
#include "UnityCG.cginc"
// declare color property as a variable shader cares about
float4 _Color;
float4 frag(v2f_img i) : SV_Target
{
// tell shader to use color as what is drawn on the screen
return _Color
}
ENDCG
}
}
}
And here’s another shader that works exactly the same, but with the property renamed:
Shader "Solid Color Example 2"
{
Properties
{
// define color property
_Supercalifragilisticexpialidocious("Something quite atrocious!", Color) = (1.0, 1.0, 1.0, 1.0)
}
SubShader
{
Pass
{
CGPROGRAM
#pragma vertex vert_img
#pragma fragment frag
#include "UnityCG.cginc"
// declare color property as a variable shader cares about
float4 _Supercalifragilisticexpialidocious;
float4 frag(v2f_img i) : SV_Target
{
// tell shader to use color as what is drawn on the screen
return _Supercalifragilisticexpialidocious
}
ENDCG
}
}
}
So to know what properties a shader has you need to look at the shader. And what those properties do (if anything at all!) is determined by the shader code itself.