cocos2d / cocos2d-x

Cocos2d-x is a suite of open-source, cross-platform, game-development tools utilized by millions of developers across the globe. Its core has evolved to serve as the foundation for Cocos Creator 1.x & 2.x.

Home Page:https://www.cocos.com/en/cocos2d-x

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Crash when drawNumberOfQuads

stubma opened this issue · comments

commented

branch master-v2

for following code, if comment out first drawNumberOfQuads, then second drawNumberOfQuads will crash.
CCSpriteBatchNode* sheet = ...;
CCTextureAtlas* atlas = sheet->getTextureAtlas();
atlas->drawNumberOfQuads(1, 0);
atlas->drawNumberOfQuads(1, 1); // crash when previous call is commented out

or, if I insert a getQuads before second drawNumberOfQuads, it will crash also.
CCSpriteBatchNode* sheet = iter;
CCTextureAtlas
atlas = sheet->getTextureAtlas();
atlas->drawNumberOfQuads(1, 0);
atlas->getQuads();
atlas->drawNumberOfQuads(1, 1); // crash

Please, could you open a bug in redmine in future? We are in process of migrating all the issues to redmine and github issue won't be available after August. The issue is migrated to http://www.cocos2d-x.org/issues/2637