Shader code cleanupand bug fix.
This commit is contained in:
@@ -72,7 +72,16 @@ namespace Misaki.HdrpToon.Editor
|
||||
|
||||
editor.ShaderProperty(Properties.cullMode, Styles.cullingModeText);
|
||||
editor.ShaderProperty(Properties.shadingMode, Styles.shadingModeText);
|
||||
EditorGUI.BeginChangeCheck();
|
||||
editor.ShaderProperty(Properties.materialType, Styles.materialTypeText);
|
||||
if (EditorGUI.EndChangeCheck())
|
||||
{
|
||||
foreach (var material in editor.GetMaterials())
|
||||
{
|
||||
material.SetShaderPassEnabled(UtsShaderPassName.HAIR_SHADOW_CASTER_PASS_NAME, Properties.materialType.GetEnumValue<MaterialType>() == MaterialType.FrontHair);
|
||||
}
|
||||
}
|
||||
|
||||
editor.ShaderProperty(Properties.pbrMode, Styles.pbrModeText);
|
||||
|
||||
EditorGUI.BeginChangeCheck();
|
||||
|
||||
Reference in New Issue
Block a user