6. Sprite Sheets

Chapter 5, “Image Rendering,” was large and covered a number of complex concepts. Having done all that hard work, and with the classes in place for representing and rendering images, we can move on to the other components needed in the game engine for Sir Lamorak’s Quest.

As the title suggests, this chapter is all about sprite sheets. If you remember from Chapter 2, “The Three Ts: Terminology, Technology, and Tools,” a sprite sheet is a large image that contains a number of smaller images.

There are two key benefits to using sprite sheet, as follows:

• You reduce the number of times you need to ask OpenGL ES to bind to a new texture, which helps with performance.

• You gain the ability to easily define and reuse image elements ...

Get Learning iOS Game Programming now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.