Developing a Simple Game of Air Hockey Using C and OpenGL ES 2 for Android, iOS, and the Web

Some of you have been curious about what the air hockey game from the book would be like if we brought it over to other platforms. I would like to find out, myself. 🙂 In the spirit of my last post about cross-platform development, I want to port the air hockey project over to a native cross-platform code base that can be built for Android and iOS, and even the web by using emscripten and WebGL. Everything will be open-source and available on GitHub.

Here are some of the things that we’ll have to figure out and learn along the way:

  • Setting up a simple build system for each platform.
  • Initializing OpenGL.
  • Adding support for basic touch and collision detection.

In the next post, we’ll take a look at setting up a simple build system to initialize OpenGL across these different platforms. Here are all of the posts for the series so far:

Setting up a simple build system

Adding support for PNG loading into a texture

Adding a 3d perspective, mallets, and a puck

Adding touch events and basic collision detection

The code is available on Github, with each section organized by tags.

About the book

Android is booming like never before, with millions of devices shipping every day. In OpenGL ES 2 for Android: A Quick-Start Guide, you’ll learn all about shaders and the OpenGL pipeline, and discover the power of OpenGL ES 2.0, which is much more feature-rich than its predecessor.

It’s never been a better time to learn how to create your own 3D games and live wallpapers. If you can program in Java and you have a creative vision that you’d like to share with the world, then this is the book for you.


8 thoughts on “Developing a Simple Game of Air Hockey Using C and OpenGL ES 2 for Android, iOS, and the Web”

  1. I’m very much looking forward to this series!

    If an eBook (preferably non-DRM ePub) came of it, I’d almost certainly be interested in that, as well, if for no other reason than as a way to provide some financial support for the information you’re sharing.

Leave a Reply

Your email address will not be published. Required fields are marked *