mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-03-07 11:16:53 +08:00
[unity] Fixed false warning issued on URP 2D shaders. Closes #1767.
This commit is contained in:
parent
ac60110629
commit
9bfe314aeb
@ -67,7 +67,7 @@ namespace Spine.Unity {
|
|||||||
if (renderer.zSpacing == 0) {
|
if (renderer.zSpacing == 0) {
|
||||||
isProblematic |= IsZSpacingRequired(material, ref errorMessage);
|
isProblematic |= IsZSpacingRequired(material, ref errorMessage);
|
||||||
}
|
}
|
||||||
if (IsURPMaterial(material) && !AreShadowsDisabled(material) && renderer.addNormals == false) {
|
if (IsURP3DMaterial(material) && !AreShadowsDisabled(material) && renderer.addNormals == false) {
|
||||||
isProblematic = true;
|
isProblematic = true;
|
||||||
errorMessage += kAddNormalsRequiredMessage;
|
errorMessage += kAddNormalsRequiredMessage;
|
||||||
}
|
}
|
||||||
@ -177,8 +177,8 @@ namespace Spine.Unity {
|
|||||||
material.IsKeywordEnabled(ALPHAPREMULTIPLY_ON_KEYWORD);
|
material.IsKeywordEnabled(ALPHAPREMULTIPLY_ON_KEYWORD);
|
||||||
}
|
}
|
||||||
|
|
||||||
static bool IsURPMaterial (Material material) {
|
static bool IsURP3DMaterial (Material material) {
|
||||||
return material.shader.name.Contains("Universal Render Pipeline");
|
return material.shader.name.Contains("Universal Render Pipeline/Spine");
|
||||||
}
|
}
|
||||||
|
|
||||||
static bool AreShadowsDisabled (Material material) {
|
static bool AreShadowsDisabled (Material material) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user