I have seen references to a new 'auto batching' feature in Cocos2d-x 3.0, and even saw somewhere that they no longer recommending using SpriteBatchNodes. So how do I batch draw calls without using BatchNodes?
I can't find anything in the documentation but the vaguest references to this feature. - https://docs.google.com/document/d/17zjC55vbP_PYTftTZEuvqXuMb9PbYNxRFu0EGTULPK8/edit#heading=h.3ssqg87hovgw
I tried simply getting rid of my SpriteBatchNode and creating my Sprites using files but the number of draw calls went up by about 1 per sprite :)
I think I have solved this, and it's pretty simple. I just changed all of my SpriteBatchNodes to Nodes and preloaded my atlases with
SpriteFrameCache* spriteFrameCache = SpriteFrameCache::sharedSpriteFrameCache();
spriteFrameCache->addSpriteFramesWithFile("spritesheets/xxx.plist");
The number of draw calls didn't change compared to what it was with SpriteBatchNode.
This new architecture is way more flexible than SpriteBatchNode. For example, the calls are properly batched if you do Node -> Node -> Sprite where you could never do SpriteBatchNode -> Node -> Sprite because SpriteBatchNode could have only Sprites as children.