Tuesday, October 2, 2012

OpenGL ES with iOS 5 Part 1: Learning to draw – Swipe Conference 2012

In September I presented two talks at Swipe Conference in Sydney. The first talk, "OpenGL ES with iOS 5 Part 1: Learning to draw", was an introduction to OpenGL ES and GLKit, aimed at iOS developers new to OpenGL programming.
In the talk I used a simple demo app, SwipeOpenGLTriangles, to demonstrate OpenGL ES rendering concepts with GLKit, such as:


  • Setting up an OpenGL ES scene using GLKViewController + GLKView
  • Rendering triangles (GL_TRIANGLES) and meshes made of triangles
  • Applying vertex colours, using GLKBaseEffect
  • Applying lighting, using GLKBaseEffect
  • Applying texturing, using GLKBaseEffect and GLKTextureLoader
  • Using Vertex Array Objects (VAO) and Vertex Buffer Objects (VBO)
  • Using interleaved vertex arrays (IVA)
  • Animating vertex positions (tap screen to animate between flat triangles and 3D open box shape)
  • The sample app is universal and supports all orientations.




The full source to the demo app is released open source (MIT licensed) at https://github.com/chrismiles/SwipeOpenGLTriangles


The slides from the talk are available at https://speakerdeck.com/chrismiles/opengl-es-with-ios-5-part-1-learning-to-draw or http://chrismiles.info/presentations/SwipeConf-2012-OpenGL-ES-iOS5/Swipe-2012-OpenGL-ES-iOS5-Part1.pdf [PDF].

Update: The presentation video is now online at https://www.youtube.com/watch?v=s6VCaFQFBtM

No comments: