[cpp] Initialize minX/minY correctly in Skeleton::getBounds

This commit is contained in:
Mario Zechner 2022-11-17 19:10:38 +01:00
parent 187808d543
commit a66218cb14

View File

@ -425,8 +425,8 @@ PathConstraint *Skeleton::findPathConstraint(const String &constraintName) {
void Skeleton::getBounds(float &outX, float &outY, float &outWidth, float &outHeight, Vector<float> &outVertexBuffer) {
float minX = FLT_MAX;
float minY = FLT_MAX;
float maxX = FLT_MIN;
float maxY = FLT_MIN;
float maxX = -FLT_MAX;
float maxY = -FLT_MAX;
for (size_t i = 0; i < _drawOrder.size(); ++i) {
Slot *slot = _drawOrder[i];