mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-02-28 20:51:38 +08:00
Merge branch '4.1' into 4.2-beta
This commit is contained in:
commit
302af378c0
@ -261,7 +261,7 @@ namespace Spine.Unity.Editor {
|
|||||||
EditorGUILayout.LabelField(SpineInspectorUtility.TempContent("This mesh uses multiple atlas pages or blend modes.\n" +
|
EditorGUILayout.LabelField(SpineInspectorUtility.TempContent("This mesh uses multiple atlas pages or blend modes.\n" +
|
||||||
"You need to enable 'Multiple Canvas Renderers'\n" +
|
"You need to enable 'Multiple Canvas Renderers'\n" +
|
||||||
"for correct rendering. Consider packing\n" +
|
"for correct rendering. Consider packing\n" +
|
||||||
"attachments to a single atlas page if possible.", Icons.warning), GUILayout.Height(60), GUILayout.Width(340));
|
"attachments to a single atlas page if possible.", Icons.warning), GUILayout.Height(60), GUILayout.Width(380));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -160,10 +160,15 @@ namespace Spine.Unity.Editor {
|
|||||||
newTransform.position = isUI ? data.spawnPoint : RoundVector(data.spawnPoint, 2);
|
newTransform.position = isUI ? data.spawnPoint : RoundVector(data.spawnPoint, 2);
|
||||||
|
|
||||||
if (isUI) {
|
if (isUI) {
|
||||||
|
SkeletonGraphic skeletonGraphic = ((SkeletonGraphic)newSkeletonComponent);
|
||||||
if (usedParent != null && usedParent.GetComponent<RectTransform>() != null) {
|
if (usedParent != null && usedParent.GetComponent<RectTransform>() != null) {
|
||||||
((SkeletonGraphic)newSkeletonComponent).MatchRectTransformWithBounds();
|
skeletonGraphic.MatchRectTransformWithBounds();
|
||||||
} else
|
} else
|
||||||
Debug.Log("Created a UI Skeleton GameObject not under a RectTransform. It may not be visible until you parent it to a canvas.");
|
Debug.Log("Created a UI Skeleton GameObject not under a RectTransform. It may not be visible until you parent it to a canvas.");
|
||||||
|
if (skeletonGraphic.HasMultipleSubmeshInstructions() && !skeletonGraphic.allowMultipleCanvasRenderers)
|
||||||
|
Debug.Log("This mesh uses multiple atlas pages or blend modes. " +
|
||||||
|
"You need to enable 'Multiple Canvas Renderers for correct rendering. " +
|
||||||
|
"Consider packing attachments to a single atlas page if possible.", skeletonGraphic);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!isUI && usedParent != null && usedParent.transform.localScale != Vector3.one)
|
if (!isUI && usedParent != null && usedParent.transform.localScale != Vector3.one)
|
||||||
|
|||||||
@ -222,6 +222,13 @@ fixed4 fragAdd(VertexOutput input) : SV_Target
|
|||||||
|
|
||||||
ALPHA_CLIP(texureColor, input.color)
|
ALPHA_CLIP(texureColor, input.color)
|
||||||
|
|
||||||
|
// previous fragBase pass was zwrite pass, so overlapping regions require
|
||||||
|
// full alpha applied since they are applied only once.
|
||||||
|
#if defined(_ALPHAPREMULTIPLY_ON)
|
||||||
|
texureColor.rgb /= texureColor.a == 0 ? 1 : texureColor.a;
|
||||||
|
#endif
|
||||||
|
texureColor.a = 1.0;
|
||||||
|
|
||||||
//Get normal direction
|
//Get normal direction
|
||||||
fixed3 normalWorld = calculateNormalWorld(input);
|
fixed3 normalWorld = calculateNormalWorld(input);
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user