mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2025-12-20 17:26:01 +08:00
[starling] Fixed two color tint.
This commit is contained in:
parent
966ed65465
commit
647d124361
Binary file not shown.
@ -29,6 +29,7 @@
|
||||
*****************************************************************************/
|
||||
|
||||
package spine.starling {
|
||||
import starling.styles.MeshStyle;
|
||||
import spine.attachments.ClippingAttachment;
|
||||
import spine.SkeletonClipping;
|
||||
import spine.Bone;
|
||||
@ -170,9 +171,9 @@ package spine.starling {
|
||||
if (clipper.isClipping()) {
|
||||
clipper.clipTriangles(worldVertices, indices, indices.length, uvs);
|
||||
|
||||
// Need to create a new mesh here, see https://github.com/EsotericSoftware/spine-runtimes/issues/1125
|
||||
// Need to create a new mesh here, see https://github.com/EsotericSoftware/spine-runtimes/issues/1125
|
||||
mesh = new SkeletonMesh(mesh.texture);
|
||||
if (_twoColorTint) mesh.setStyle(mesh.style);
|
||||
if (_twoColorTint) mesh.setStyle(new TwoColorMeshStyle());
|
||||
indexData = mesh.getIndexData();
|
||||
|
||||
verticesCount = clipper.clippedVertices.length >> 1;
|
||||
@ -223,7 +224,6 @@ package spine.starling {
|
||||
if (indexData.numIndices > 0 && vertexData.numVertices > 0) {
|
||||
painter.state.blendMode = blendModes[slot.data.blendMode.ordinal];
|
||||
painter.batchMesh(mesh);
|
||||
painter.finishMeshBatch();
|
||||
}
|
||||
|
||||
clipper.clipEndWithSlot(slot);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user