浏览代码

Another attempt to fix shaders for URP & HDRP

/keypoint_self_occlusion
Steve Borkman 3 年前
当前提交
508a7943
共有 1 个文件被更改,包括 8 次插入8 次删除
  1. 16
      com.unity.perception/Editor/GroundTruth/ShaderPreprocessor.cs

16
com.unity.perception/Editor/GroundTruth/ShaderPreprocessor.cs


#if HDRP_PRESENT || URP_PRESENT
#if HDRP_PRESENT
var keyword = new ShaderKeyword(shader, "HDRP_ENABLED");
var enabled = new ShaderKeyword(shader, "HDRP_ENABLED");
var disabled = new ShaderKeyword(shader, "URP_ENABLED");
var keyword = new ShaderKeyword(shader, "HDRP_DISABLED");
#endif
var enabled = new ShaderKeyword(shader, "URP_ENABLED");
var disabled = new ShaderKeyword(shader, "HDRP_ENABLED");
#endif
if (!data[i].shaderKeywordSet.IsEnabled(keyword))
continue;
data[i].shaderKeywordSet.Disable(keyword);
data[i].shaderKeywordSet.Enable(enabled);
data[i].shaderKeywordSet.Disable(disabled);
}
#endif
}
正在加载...
取消
保存