mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2025-12-20 17:26:01 +08:00
[cocos2d-objc] Fixed calculation of bounding box.
This commit is contained in:
parent
a578557934
commit
c8867a98c4
@ -279,8 +279,8 @@ static bool handlerQueued = false;
|
||||
minY = MIN(vertices[i+1], minY);
|
||||
maxY = MAX(vertices[i+1], maxY);
|
||||
}
|
||||
GLKVector2 center = GLKVector2Make((maxX - minX) / 2, (maxY - minY) / 2);
|
||||
GLKVector2 extents = GLKVector2Make((maxX - minX), (maxY - minY));
|
||||
GLKVector2 center = GLKVector2Make(minX + (maxX - minX) / 2, minY + (maxY - minY) / 2);
|
||||
GLKVector2 extents = GLKVector2Make((maxX - minX) / 2, (maxY - minY) / 2);
|
||||
isVisible = CCRenderCheckVisbility(transform, center, extents);
|
||||
}
|
||||
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user