OpenGL ES 1.1 Demo

Not too much to say about this: It’s an OpenGL ES 1.1 demo. It draws and animates the Platonic solids (tap the screen to cycle through them). If you look at the code (most of the interesting stuff is in SolidsViewController.m), you can see simple illustrations of:

  • Camera setup
  • Animation
  • Matrix stack manipulation
  • Lighting
  • Triangle strips and fans

I don’t claim that anything here is done optimally, but it might serve to get you up and running with 1.1 if it’s been a while since you put a polygon on screen.

Garbage Code

There’s some extraneous OpenGL ES 2.0 stuff in the code because this demo was built on top of Xcode’s “OpenGL ES Application” template, and I didn’t feel like pulling the extra stuff. You can ignore it; it doesn’t do anything.

There’s also some unused code related to either setup (e.g., I turn on alpha-blending) or testing (e.g., the renderXxxxInnerRadius:outerRadius:explode methods). That stuff is just there for you to play with.

Share and Enjoy:
  • Twitter
  • Facebook
  • Digg
  • Reddit
  • HackerNews
  • Google Bookmarks
  • Slashdot
This entry was posted in iPhone. Bookmark the permalink.

Comments are closed.