
OpenGL is a cross-platform graphics API that (OpenGL®), specifically, the OpenGL ES API. Here’s where the fun begins! Open ViewController.Android includes support for high performance 2D and 3D graphics with the Open Graphics Library Introducing GLKView and GLKViewController Click Next, choose a folder in which to save your project and click Create.īuild and run. Make sure none of the checkboxes are selected. Set the Product Name to OpenGLKit and the Language to Swift. Select the iOS\Application\Single View App template. Open Xcode and create a brand new project. You’re going to make it all from scratch! There’s no starter project for this tutorial. You will build an app that draws a cube to the screen and makes it rotate. The goal of this tutorial is to get you up-to-speed with the basics of using OpenGL with GLKit, assuming you have no previous experience with this whatsoever.

Without further ado, it’s time to get started! Note: You will use OpenGL ES 3.0, which is available on iPhone 5S and above, iPad Mini 2 and above, and iPad 5th generation and above. Texture Loading: Makes it much easier to load images as textures to be used in OpenGL.Math: Provides helpers and functions for common math routines like vector and matrix manipulation.Effects: These implement common shading behaviors and are a handy way of setting up basic lighting, shading, reflection mapping and skybox effects.


Views and View Controllers: These abstract much of the boilerplate code that GLKit uses to set up a basic OpenGL ES (Embedded Systems) project.GLKit provides functionality in four areas: You’ll learn how all of this works in this GLKit tutorial for iOS. It also allows developers to focus on drawing, not on getting the project set up.

Apple has developed a framework called GLKit to help developers create apps that leverage OpenGL and to abstract boilerplate code. If you’re interested in graphics programming, chances are that you’ve read about OpenGL, which remains the most-adopted API from a hardware and software perspective. The original tutorial was written by Ray Wenderlich. Update note: This tutorial has been updated to Swift 4.1 and Xcode 9.3 by Felipe Laso-Marsetti.
