Minor update.

This commit is contained in:
NathanSweet 2013-09-27 09:38:10 +02:00
parent 8674909fab
commit 86f8c564a4

View File

@ -158,10 +158,10 @@ void CCSkeleton::draw () {
}
}
textureAtlas = regionTextureAtlas;
if (textureAtlas->getCapacity() == textureAtlas->getTotalQuads() &&
!textureAtlas->resizeCapacity(textureAtlas->getCapacity() * 2)) return;
int quadCount = textureAtlas->getTotalQuads();
if (textureAtlas->getCapacity() == quadCount && !textureAtlas->resizeCapacity(textureAtlas->getCapacity() * 2)) return;
RegionAttachment_updateQuad(attachment, slot, &quad, premultipliedAlpha);
textureAtlas->updateQuad(&quad, textureAtlas->getTotalQuads());
textureAtlas->updateQuad(&quad, quadCount);
}
if (textureAtlas) {
textureAtlas->drawQuads();