Well, I’ve sent you a pull request https://github.com/fakhirsh/DaisyMark-cc2dx/pull/1 The CCBatchNode hasn’t been used correctly, as I wrote in the pull request.
To be honest, even if Ricardo Quesada improved the API set of batch node in v2.x, it’s still a bit confusing to users.
In the previous code, the error points of using CCBatchNode are:
# CCBatchNode is created from daisy-texture.png, while sprites are created from daisy.png. There’s no relationship between sprites and batchNode in your code.
# You added both batchNode and sprites as children of parent node, while the correct usage is to
* NOTE: This line breaks the batchNode optimisation: parent->addChild(sprite)
I increased the particle number from 700 to 2000, batchNode speed up the rendering correctly on my ipad2. You can have a try.
And you’ve noticed the numbers in the bottom-left corners. Their meanings are:
1 <--- How many times of draw calls in one frame
0.016 <--- How long (in seconds) per frame
59.8 <--- FPS
The draw call is 1 if you use batch node properly here, while it will equal to
DaisyTest::numParticles if the batch node doesn’t take its job.