浏览代码

HDREnderLoop: fix an issue

/main
Sebastien Lagarde 8 年前
当前提交
2a400360
共有 1 个文件被更改,包括 6 次插入5 次删除
  1. 11
      Assets/ScriptableRenderLoop/HDRenderLoop/Material/LayeredLit/Editor/LayeredLitUI.cs

11
Assets/ScriptableRenderLoop/HDRenderLoop/Material/LayeredLit/Editor/LayeredLitUI.cs


SetKeyword(material, "_EMISSIVE_COLOR_MAP", material.GetTexture(kEmissiveColorMap));
SetKeyword(material, "_LAYER_MASK_VERTEX_COLOR", material.GetFloat(kLayerMaskVertexColor) != 0.0f);
// We have to check for each layer if the UV3 is needed.
SetKeyword(material, "_REQUIRE_UV2", false);
SetKeyword(material, "_REQUIRE_UV3", false);
// We have to check for each layer if the UV2 or UV3 is needed.
bool UV2orUV3needed = false;
for (int layer = 0; layer < numLayer; ++layer)
{
string uvBase = string.Format("{0}{1}", kUVBase, layer);

((LayerUVBaseMapping)material.GetFloat(uvBase) == LayerUVBaseMapping.UV3)
)
{
SetKeyword(material, "_REQUIRE_UV2_OR_UV3", true);
break;
UV2orUV3needed = true;
break;
SetKeyword(material, "_REQUIRE_UV2_OR_UV3", UV2orUV3needed);
}
void SetupLayersKeywords(Material material)

正在加载...
取消
保存