Version: 2019.2
public Color GetColor (string name);
public Color GetColor (int nameID);


nameID Shader.PropertyToID によって検索されるプロパティーの nameID



多くのシェーダーでは複数の色を使用します。GetColor によりプロパティー名( propertyName )から色を取得します。

Common color names used by Unity's builtin shaders:
"_Color" is the main color of a material. This can also be accessed via color property.
"_SpecColor" is the specular color of a material (used in specular/glossy/vertexlit shaders).
"_EmissionColor" is the emissive color of a material (used in vertexlit shaders).
"_ReflectColor" is the reflection color of the material (used in reflective shaders).

See Also: color property, SetColor, Shader.PropertyToID.