I found a really cool program to view openGL with objective-c from http://osx.hyperjeff.net/MyApps/Cosmos3d.php. The only problem was that the code didn’t build at my xcode straight away. This problem was fixed quite easily with changing the active SDK to 10.5.