Book Image

Learning iPhone Game Development with Cocos2D 3.0

By : Kirill Muzykov
Book Image

Learning iPhone Game Development with Cocos2D 3.0

By: Kirill Muzykov

Overview of this book

Table of Contents (19 chapters)
Learning iPhone Game Development with Cocos2D 3.0
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Understanding debug FPS labels


Now, when we know that the frame rate is important, let's have a look once again at those debug labels that are displayed in the left bottom corner. Refer to the following screenshot:

The following explains each numbered line shown in the preceding screenshot:

  1. The number of OpenGL draw calls per frame: Each call to the OpenGL draw function has a performance cost. We have four objects in our scene: background, bird, hunter's torso, and his legs. This gives us four OpenGL draw calls. If you add one more bird to the scene, this number will increase to five and so on. Soon, I will show you how to draw several objects in one call and increase performance.

  2. Time required to render one frame.

  3. The average framerate (FPS) the game is currently running.

    Note

    You should try to keep the FPS around 60.0 when testing on actual device. Don't worry if you get a lower FPS when running on the simulator; this might only mean that you should test on an actual device, as the simulator...