浏览代码

Added check to propertly assign _MetallicSpecGlossMap when upgrading from Standard/StandardSpecular.

/RenderPassXR_Sandbox
Felipe Lira 7 年前
当前提交
c9ed078e
共有 1 个文件被更改,包括 12 次插入3 次删除
  1. 15
      ScriptableRenderPipeline/LightweightPipeline/Editor/ShaderGUI/LightweightStandardShaderGUI.cs

15
ScriptableRenderPipeline/LightweightPipeline/Editor/ShaderGUI/LightweightStandardShaderGUI.cs


}
material.SetFloat("_Mode", (float)blendMode);
// TODO: material.HasKeyword()?
material.SetFloat("_WorkflowMode", (float)WorkflowMode.Specular);
{
material.SetFloat("_WorkflowMode", (float) WorkflowMode.Specular);
Texture texture = material.GetTexture("_SpecGlossMap");
if (texture != null)
material.SetTexture("_MetallicSpecGlossMap", texture);
}
material.SetFloat("_WorkflowMode", (float)WorkflowMode.Metallic);
{
material.SetFloat("_WorkflowMode", (float) WorkflowMode.Metallic);
Texture texture = material.GetTexture("_MetallicGlossMap");
if (texture != null)
material.SetTexture("_MetallicSpecGlossMap", texture);
}
MaterialChanged(material);
}

正在加载...
取消
保存