Browse Source

initial commit

master
Joshua Moerman 10 years ago
commit
fc5994910d
  1. 4
      .gitignore
  2. 22
      GLEssentials/Fractal-iOS.fsh
  3. 18
      GLEssentials/Fractal-iOS.vsh
  4. 26
      GLEssentials/Fractal.fsh
  5. 18
      GLEssentials/Fractal.vsh
  6. 14
      GLEssentials/Game.h
  7. 123
      GLEssentials/Game.m
  8. 30
      GLEssentials/OSX/GLEssentials-Info.plist
  9. 12
      GLEssentials/OSX/GLEssentialsFullscreenWindow.h
  10. 41
      GLEssentials/OSX/GLEssentialsFullscreenWindow.m
  11. 12
      GLEssentials/OSX/GLEssentialsGLView.h
  12. 219
      GLEssentials/OSX/GLEssentialsGLView.m
  13. 16
      GLEssentials/OSX/GLEssentialsWindowController.h
  14. 108
      GLEssentials/OSX/GLEssentialsWindowController.m
  15. 588
      GLEssentials/OSX/MainMenu.xib
  16. 5
      GLEssentials/OSX/main.m
  17. 13
      GLEssentials/iOS/AppDelegate.h
  18. 40
      GLEssentials/iOS/AppDelegate.m
  19. 49
      GLEssentials/iOS/GLEssentials-Info.plist
  20. 26
      GLEssentials/iOS/Main_iPad.storyboard
  21. 26
      GLEssentials/iOS/Main_iPhone.storyboard
  22. 12
      GLEssentials/iOS/ViewController.h
  23. 90
      GLEssentials/iOS/ViewController.m
  24. 8
      GLEssentials/iOS/main.m
  25. 254
      OSXGLEssentials.xcodeproj/project.pbxproj
  26. 20
      README.md
  27. 32
      Readme.txt
  28. 269
      iOSGLEssentials.xcodeproj/project.pbxproj

4
.gitignore

@ -0,0 +1,4 @@
.DS_Store
*.xcworkspace
*.xcuser*

22
GLEssentials/Fractal-iOS.fsh

@ -0,0 +1,22 @@
#version 100
varying highp vec2 pos;
varying highp vec2 start;
void main(){
highp vec2 z = start;
int i = 0;
for (i = 0; i < 7; i++) {
highp vec2 zsq = z*z;
if(zsq.x + zsq.y > 16.0) break;
highp float t = zsq.x - zsq.y + pos.x;
z.y = 2.0*z.x*z.y + pos.y;
z.x = t;
}
gl_FragColor = vec4(float(i) / 7.0);
gl_FragColor.bg = 0.5 * sin(z) + 0.5;
}

18
GLEssentials/Fractal-iOS.vsh

@ -0,0 +1,18 @@
#version 100
uniform float rotation;
attribute vec4 position;
attribute vec4 color;
varying vec2 pos;
varying vec2 start;
void main(){
pos = position.xy;
pos.x -= 0.5;
start = sqrt(1.0 + 0.01 * rotation) * 0.3 * sin(vec2(0.1, 0.1337) * rotation);
gl_Position = position;
}

26
GLEssentials/Fractal.fsh

@ -0,0 +1,26 @@
#version 330
uniform float rotation;
in vec2 pos;
in vec2 start;
out vec4 fragColor;
void main(){
vec2 z = start;
int i = 0;
for (i = 0; i < 30; i++) {
vec2 zsq = z*z;
if(zsq.x + zsq.y > 16.0) break;
float t = zsq.x - zsq.y + pos.x;
z.y = 2.0*z.x*z.y + pos.y;
z.x = t;
}
fragColor = vec4(float(i) / 30.0);
fragColor.bg = 0.5 * sin(z) + 0.5;
}

18
GLEssentials/Fractal.vsh

@ -0,0 +1,18 @@
#version 330
uniform float rotation;
in vec4 position;
in vec4 color;
out vec2 pos;
out vec2 start;
void main(){
pos = position.xy;
pos.x -= 0.5;
start = sqrt(1.0 + 0.01 * rotation) * 0.3 * sin(vec2(0.1, 0.1337) * rotation);
gl_Position = position;
}

14
GLEssentials/Game.h

@ -0,0 +1,14 @@
//
// Game.h
// iOSGLEssentials
//
// Created by Joshua Moerman on 08/03/14.
//
//
@import Foundation;
@interface Game : NSObject
- (void)update:(float)dt;
- (void)draw;
@end

123
GLEssentials/Game.m

@ -0,0 +1,123 @@
//
// Game.m
// iOSGLEssentials
//
// Created by Joshua Moerman on 08/03/14.
//
//
#import "Game.h"
@import GLKit;
#ifdef ESSENTIAL_GL_PRACTICES_IOS
#define glBindVertexArray glBindVertexArrayOES
#define glGenVertexArrays glGenVertexArraysOES
#define glDeleteVertexArrays glDeleteVertexArraysOES
#endif
#define BUFFER_OFFSET(i) ((char *)NULL + (i))
#ifdef ESSENTIAL_GL_PRACTICES_IOS
NSString * file = @"Fractal-iOS";
#else
NSString * file = @"Fractal";
#endif
const GLfloat quad[] = {
// x y z, r g b
1, -1, 0, 1, 0, 0,
-1, -1, 0, 0, 1, 0,
1, 1, 0, 0, 0, 1,
-1, 1, 0, 1, 1, 1
};
static void check_shader(GLuint s){
GLint logLength;
glGetShaderiv(s, GL_INFO_LOG_LENGTH, &logLength);
if (logLength > 0) {
GLchar *log = (GLchar *)malloc(logLength);
glGetShaderInfoLog(s, logLength, &logLength, log);
NSLog(@"Shader compile log:\n%s", log);
free(log);
}
}
@implementation Game{
float time;
GLuint program;
GLint uniform;
GLuint vao;
GLuint posBufferName;
}
- (id)init{
if(self = [super init]){
time = 0;
program = glCreateProgram();
NSError * error = nil;
NSString * vs = [NSString stringWithContentsOfFile:[[NSBundle mainBundle] pathForResource:file ofType:@"vsh"] encoding:NSASCIIStringEncoding error:&error];
NSString * fs = [NSString stringWithContentsOfFile:[[NSBundle mainBundle] pathForResource:file ofType:@"fsh"] encoding:NSASCIIStringEncoding error:nil];
GLchar const * vs_cstr = [vs UTF8String];
GLchar const * fs_cstr = [fs UTF8String];
GLuint v = glCreateShader(GL_VERTEX_SHADER);
glShaderSource(v, 1, &vs_cstr, NULL);
glCompileShader(v);
check_shader(v);
GLuint f = glCreateShader(GL_FRAGMENT_SHADER);
glShaderSource(f, 1, &fs_cstr, NULL);
glCompileShader(f);
check_shader(f);
glAttachShader(program, v);
glAttachShader(program, f);
glBindAttribLocation(program, 0, "position");
glBindAttribLocation(program, 1, "color");
glLinkProgram(program);
uniform = glGetUniformLocation(program, "rotation");
glDetachShader(program, v);
glDeleteShader(v);
glDetachShader(program, f);
glDeleteShader(f);
glGenVertexArrays(1, &vao);
glBindVertexArray(vao);
glGenBuffers(1, &posBufferName);
glBindBuffer(GL_ARRAY_BUFFER, posBufferName);
glBufferData(GL_ARRAY_BUFFER, 4*6*4, quad, GL_STATIC_DRAW);
glEnableVertexAttribArray(0);
glEnableVertexAttribArray(1);
glVertexAttribPointer(0, 3, GL_FLOAT, GL_FALSE, 6*4, BUFFER_OFFSET(0));
glVertexAttribPointer(1, 3, GL_FLOAT, GL_FALSE, 6*4, BUFFER_OFFSET(3*4));
}
return self;
}
- (void)update:(float)dt{
time += dt;
}
- (void)draw{
glClearColor(0.65f, 0.65f, 0.65f, 1.0f);
glClear(GL_COLOR_BUFFER_BIT | GL_DEPTH_BUFFER_BIT);
glUseProgram(program);
glUniform1f(uniform, time);
glBindVertexArray(vao);
glDrawArrays(GL_TRIANGLE_STRIP, 0, 4);
}
@end

30
GLEssentials/OSX/GLEssentials-Info.plist

@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>English</string>
<key>CFBundleExecutable</key>
<string>${EXECUTABLE_NAME}</string>
<key>CFBundleIdentifier</key>
<string>com.example.apple-samplecode.${PRODUCT_NAME:rfc1034identifier}</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>${PRODUCT_NAME}</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.7</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>Dan Omachi</string>
<key>LSMinimumSystemVersion</key>
<string>${MACOSX_DEPLOYMENT_TARGET}</string>
<key>NSMainNibFile</key>
<string>MainMenu</string>
<key>NSPrincipalClass</key>
<string>NSApplication</string>
</dict>
</plist>

12
GLEssentials/OSX/GLEssentialsFullscreenWindow.h

@ -0,0 +1,12 @@
//
//
// iOSGLEssentials
//
// Copied from the Apple GLEssentials
//
//
@import Cocoa;
@interface GLEssentialsFullscreenWindow : NSWindow
@end

41
GLEssentials/OSX/GLEssentialsFullscreenWindow.m

@ -0,0 +1,41 @@
//
//
// iOSGLEssentials
//
// Copied from the Apple GLEssentials
//
//
#import "GLEssentialsFullscreenWindow.h"
@implementation GLEssentialsFullscreenWindow
- (id)init {
// Create a screen-sized window on the display you want to take over
// Initialize the window making it size of the screen and borderless
NSRect screenRect = [[NSScreen mainScreen] frame];
if(self = [super initWithContentRect:screenRect
styleMask:NSBorderlessWindowMask
backing:NSBackingStoreBuffered
defer:YES]){
self.level = NSMainMenuWindowLevel + 1; // Set the window level to be above the menu bar to cover everything else
self.opaque = YES; // Set opaque
self.hidesOnDeactivate = YES; // Hide this when user switches to another window (or app)
}
return self;
}
- (BOOL)canBecomeKeyWindow {
// Return yes so that this borderless window can receive input
return YES;
}
- (void)keyDown:(NSEvent *)event {
// Implement keyDown since controller will not get [ESC] key event which
// the controller uses to kill fullscreen
[self.windowController keyDown:event];
}
@end

12
GLEssentials/OSX/GLEssentialsGLView.h

@ -0,0 +1,12 @@
//
//
// iOSGLEssentials
//
// Copied from the Apple GLEssentials
//
//
@import AppKit;
@interface GLEssentialsGLView : NSOpenGLView
@end

219
GLEssentials/OSX/GLEssentialsGLView.m

@ -0,0 +1,219 @@
//
//
// iOSGLEssentials
//
// Copied from the Apple GLEssentials
//
//
#import "GLEssentialsGLView.h"
#import "Game.h"
@import GLKit;
@import QuartzCore;
@interface GLEssentialsGLView (){
CVDisplayLinkRef displayLink;
Game* game;
}
- (void) initGL;
@end
@implementation GLEssentialsGLView
- (CVReturn) getFrameForTime:(const CVTimeStamp*)outputTime{
// There is no autorelease pool when this method is called
// because it will be called from a background thread.
// It's important to create one or app can leak objects.
@autoreleasepool {
[self drawView];
return kCVReturnSuccess;
}
}
// This is the renderer output callback function
static CVReturn MyDisplayLinkCallback(CVDisplayLinkRef displayLink,
const CVTimeStamp* now,
const CVTimeStamp* outputTime,
CVOptionFlags flagsIn,
CVOptionFlags* flagsOut,
void* displayLinkContext)
{
CVReturn result = [(__bridge GLEssentialsGLView*)displayLinkContext getFrameForTime:outputTime];
return result;
}
- (void) awakeFromNib{
NSOpenGLPixelFormatAttribute attrs[] = {
NSOpenGLPFADoubleBuffer,
NSOpenGLPFADepthSize, 24,
NSOpenGLPFAOpenGLProfile,
NSOpenGLProfileVersion3_2Core,
0
};
NSOpenGLPixelFormat *pf = [[NSOpenGLPixelFormat alloc] initWithAttributes:attrs];
assert(pf);
NSOpenGLContext* context = [[NSOpenGLContext alloc] initWithFormat:pf shareContext:nil];
assert(context);
#ifdef DEBUG
// When we're using a CoreProfile context, crash if we call a legacy OpenGL function
// This will make it much more obvious where and when such a function call is made so
// that we can remove such calls.
// Without this we'd simply get GL_INVALID_OPERATION error for calling legacy functions
// but it would be more difficult to see where that function was called.
CGLEnable([context CGLContextObj], kCGLCECrashOnRemovedFunctions);
#endif
self.pixelFormat = pf;
self.openGLContext = context;
// Opt-In to Retina resolution
self.wantsBestResolutionOpenGLSurface = YES;
}
- (void) prepareOpenGL{
[super prepareOpenGL];
// Make all the OpenGL calls to setup rendering
// and build the necessary rendering objects
[self initGL];
// Create a display link capable of being used with all active displays
CVDisplayLinkCreateWithActiveCGDisplays(&displayLink);
// Set the renderer output callback function
CVDisplayLinkSetOutputCallback(displayLink, &MyDisplayLinkCallback, (__bridge void *)(self));
// Set the display link for the current renderer
CGLContextObj cglContext = [[self openGLContext] CGLContextObj];
CGLPixelFormatObj cglPixelFormat = [[self pixelFormat] CGLPixelFormatObj];
CVDisplayLinkSetCurrentCGDisplayFromOpenGLContext(displayLink, cglContext, cglPixelFormat);
// Activate the display link
CVDisplayLinkStart(displayLink);
// Register to be notified when the window closes so we can stop the displaylink
[[NSNotificationCenter defaultCenter] addObserver:self
selector:@selector(windowWillClose:)
name:NSWindowWillCloseNotification
object:[self window]];
}
- (void) windowWillClose:(NSNotification*)notification{
// Stop the display link when the window is closing because default
// OpenGL render buffers will be destroyed. If display link continues to
// fire without renderbuffers, OpenGL draw calls will set errors.
CVDisplayLinkStop(displayLink);
}
- (void) initGL{
// The reshape function may have changed the thread to which our OpenGL
// context is attached before prepareOpenGL and initGL are called. So call
// makeCurrentContext to ensure that our OpenGL context current to this
// thread (i.e. makeCurrentContext directs all OpenGL calls on this thread
// to [self openGLContext])
[[self openGLContext] makeCurrentContext];
// Synchronize buffer swaps with vertical refresh rate
GLint swapInt = 1;
[[self openGLContext] setValues:&swapInt forParameter:NSOpenGLCPSwapInterval];
// Init our renderer. Use 0 for the defaultFBO which is appropriate for
// OSX (but not iOS since iOS apps must create their own FBO)
game = [[Game alloc] init];
}
- (void) reshape{
[super reshape];
// We draw on a secondary thread through the display link. However, when
// resizing the view, -drawRect is called on the main thread.
// Add a mutex around to avoid the threads accessing the context
// simultaneously when resizing.
CGLLockContext([self.openGLContext CGLContextObj]);
// Get the view size in Points
NSRect viewRectPoints = self.bounds;
// Rendering at retina resolutions will reduce aliasing, but at the potential
// cost of framerate and battery life due to the GPU needing to render more
// pixels.
// Any calculations the renderer does which use pixel dimentions, must be
// in "retina" space. [NSView convertRectToBacking] converts point sizes
// to pixel sizes. Thus the renderer gets the size in pixels, not points,
// so that it can set it's viewport and perform and other pixel based
// calculations appropriately.
// viewRectPixels will be larger (2x) than viewRectPoints for retina displays.
// viewRectPixels will be the same as viewRectPoints for non-retina displays
NSRect viewRectPixels = [self convertRectToBacking:viewRectPoints];
// If we do not want retina (why wouldn't you want it?). DO:
// Points:Pixels is always 1:1 when not supporting retina resolutions
// NSRect viewRectPixels = viewRectPoints;
// Set the new dimensions in our renderer
// [m_renderer resizeWithWidth:viewRectPixels.size.width AndHeight:viewRectPixels.size.height];
CGLUnlockContext([self.openGLContext CGLContextObj]);
}
- (void)renewGState{
// Called whenever graphics state updated (such as window resize)
// OpenGL rendering is not synchronous with other rendering on the OSX.
// Therefore, call disableScreenUpdatesUntilFlush so the window server
// doesn't render non-OpenGL content in the window asynchronously from
// OpenGL content, which could cause flickering. (non-OpenGL content
// includes the title bar and drawing done by the app with other APIs)
[[self window] disableScreenUpdatesUntilFlush];
[super renewGState];
}
- (void) drawRect: (NSRect) theRect{
// Called during resize operations
// Avoid flickering during resize by drawiing
[self drawView];
}
- (void) drawView{
[[self openGLContext] makeCurrentContext];
// We draw on a secondary thread through the display link
// When resizing the view, -reshape is called automatically on the main
// thread. Add a mutex around to avoid the threads accessing the context
// simultaneously when resizing
CGLLockContext([[self openGLContext] CGLContextObj]);
NSRect viewRectPoints = self.bounds;
NSRect viewRectPixels = [self convertRectToBacking:viewRectPoints];
glBindFramebuffer(GL_FRAMEBUFFER, 0);
glViewport(0, 0, viewRectPixels.size.width, viewRectPixels.size.height);
[game update:1/60.0f];
[game draw];
CGLFlushDrawable([[self openGLContext] CGLContextObj]);
CGLUnlockContext([[self openGLContext] CGLContextObj]);
}
- (void) dealloc{
// Stop the display link BEFORE releasing anything in the view
// otherwise the display link thread may call into the view and crash
// when it encounters something that has been release
CVDisplayLinkStop(displayLink);
CVDisplayLinkRelease(displayLink);
// Release the display link AFTER display link has been released
}
@end

16
GLEssentials/OSX/GLEssentialsWindowController.h

@ -0,0 +1,16 @@
//
//
// iOSGLEssentials
//
// Copied from the Apple GLEssentials
//
//
@import Cocoa;
@class GLEssentialsGLView;
@interface GLEssentialsWindowController : NSWindowController {
IBOutlet GLEssentialsGLView *view;
}
@end

108
GLEssentials/OSX/GLEssentialsWindowController.m

@ -0,0 +1,108 @@
//
//
// iOSGLEssentials
//
// Copied from the Apple GLEssentials
//
//
#import "GLEssentialsWindowController.h"
#import "GLEssentialsFullscreenWindow.h"
#import "GLEssentialsGLView.h"
@interface GLEssentialsWindowController () {
GLEssentialsFullscreenWindow *fullscreenWindow; // Fullscreen window
NSWindow* standardWindow; // Non-Fullscreen window (also the initial window)
}
@end
@implementation GLEssentialsWindowController
- (id)initWithWindow:(NSWindow *) window{
if (self = [super initWithWindow:window]){
fullscreenWindow = nil;
}
return self;
}
- (void)goFullscreen{
if(fullscreenWindow){
return;
}
// Allocate a new fullscreen window
fullscreenWindow = [[GLEssentialsFullscreenWindow alloc] init];
// Resize the view to screensize
view.frame = fullscreenWindow.frame;
// Set the view in the fullscreen window
fullscreenWindow.contentView = view;
// keep a referene to the old window
standardWindow = self.window;
// Hide non-fullscreen window so it doesn't show up when switching out
// of this app (i.e. with CMD-TAB)
[standardWindow orderOut:self];
// Set controller to the fullscreen window so that all input will go to
// this controller (self)
self.window = fullscreenWindow;
// Show the window and make it the key window for input
[fullscreenWindow makeKeyAndOrderFront:self];
}
- (void)goWindow{
if(!fullscreenWindow){
return;
}
// Resize the view to the window size
view.frame = standardWindow.frame;
// Set controller to the standard window so that all input will go to
// this controller (self)
self.window = standardWindow;
// Set the content of the orginal window to the view
self.window.contentView = view;
// Show the window and make it the key window for input
[[self window] makeKeyAndOrderFront:self];
// release fullscreenWindow
fullscreenWindow = nil;
}
- (void)keyDown:(NSEvent *)event{
unichar c = [[event charactersIgnoringModifiers] characterAtIndex:0];
switch (c){
// Handle [ESC] key
case 27:
if(fullscreenWindow){
[self goWindow];
}
return;
// Have f key toggle fullscreen
case 'f':
if(fullscreenWindow){
[self goWindow];
} else {
[self goFullscreen];
}
return;
}
// Allow other character to be handled (or not and beep)
[super keyDown:event];
}
@end

588
GLEssentials/OSX/MainMenu.xib

@ -0,0 +1,588 @@
<?xml version="1.0" encoding="UTF-8"?>
<archive type="com.apple.InterfaceBuilder3.Cocoa.XIB" version="8.00">
<data>
<int key="IBDocument.SystemTarget">1060</int>
<string key="IBDocument.SystemVersion">12E55</string>
<string key="IBDocument.InterfaceBuilderVersion">4457.6</string>
<string key="IBDocument.AppKitVersion">1187.39</string>
<string key="IBDocument.HIToolboxVersion">626.00</string>
<object class="NSMutableDictionary" key="IBDocument.PluginVersions">
<string key="NS.key.0">com.apple.InterfaceBuilder.CocoaPlugin</string>
<string key="NS.object.0">4457.6</string>
</object>
<array key="IBDocument.IntegratedClassDependencies">
<string>NSCustomObject</string>
<string>NSMenu</string>
<string>NSMenuItem</string>
<string>NSView</string>
<string>NSWindowTemplate</string>
</array>
<array key="IBDocument.PluginDependencies">
<string>com.apple.InterfaceBuilder.CocoaPlugin</string>
</array>
<object class="NSMutableDictionary" key="IBDocument.Metadata">
<string key="NS.key.0">PluginDependencyRecalculationVersion</string>
<integer value="1" key="NS.object.0"/>
</object>
<array class="NSMutableArray" key="IBDocument.RootObjects" id="90632081">
<object class="NSCustomObject" id="486364360">
<string key="NSClassName">NSApplication</string>
</object>
<object class="NSCustomObject" id="1035516885">
<string key="NSClassName">FirstResponder</string>
</object>
<object class="NSCustomObject" id="405552742">
<string key="NSClassName">NSApplication</string>
</object>
<object class="NSMenu" id="272187220">
<string key="NSTitle">AMainMenu</string>
<array class="NSMutableArray" key="NSMenuItems">
<object class="NSMenuItem" id="358823679">
<reference key="NSMenu" ref="272187220"/>
<string key="NSTitle">OSXGLEssentials</string>
<string key="NSKeyEquiv"/>
<int key="NSKeyEquivModMask">1048576</int>
<int key="NSMnemonicLoc">2147483647</int>
<object class="NSCustomResource" key="NSOnImage" id="77751979">
<string key="NSClassName">NSImage</string>
<string key="NSResourceName">NSMenuCheckmark</string>
</object>
<object class="NSCustomResource" key="NSMixedImage" id="907913823">
<string key="NSClassName">NSImage</string>
<string key="NSResourceName">NSMenuMixedState</string>
</object>
<string key="NSAction">submenuAction:</string>
<object class="NSMenu" key="NSSubmenu" id="870519225">
<string key="NSTitle">OSXGLEssentials</string>
<array class="NSMutableArray" key="NSMenuItems">
<object class="NSMenuItem" id="1031860713">
<reference key="NSMenu" ref="870519225"/>
<string key="NSTitle">About OSXGLEssentialPractices</string>
<string key="NSKeyEquiv"/>
<int key="NSMnemonicLoc">2147483647</int>
<reference key="NSOnImage" ref="77751979"/>
<reference key="NSMixedImage" ref="907913823"/>
</object>
<object class="NSMenuItem" id="419577662">
<reference key="NSMenu" ref="870519225"/>
<bool key="NSIsDisabled">YES</bool>
<bool key="NSIsSeparator">YES</bool>
<string key="NSTitle"/>
<string key="NSKeyEquiv"/>
<int key="NSKeyEquivModMask">1048576</int>
<int key="NSMnemonicLoc">2147483647</int>
<reference key="NSOnImage" ref="77751979"/>
<reference key="NSMixedImage" ref="907913823"/>
</object>
<object class="NSMenuItem" id="580600437">
<reference key="NSMenu" ref="870519225"/>
<string key="NSTitle">Preferences…</string>
<string key="NSKeyEquiv">,</string>
<int key="NSKeyEquivModMask">1048576</int>
<int key="NSMnemonicLoc">2147483647</int>
<reference key="NSOnImage" ref="77751979"/>
<reference key="NSMixedImage" ref="907913823"/>
</object>
<object class="NSMenuItem" id="32280392">
<reference key="NSMenu" ref="870519225"/>
<bool key="NSIsDisabled">YES</bool>
<bool key="NSIsSeparator">YES</bool>
<string key="NSTitle"/>
<string key="NSKeyEquiv"/>
<int key="NSKeyEquivModMask">1048576</int>
<int key="NSMnemonicLoc">2147483647</int>
<reference key="NSOnImage" ref="77751979"/>
<reference key="NSMixedImage" ref="907913823"/>
</object>
<object class="NSMenuItem" id="827343213">
<reference key="NSMenu" ref="870519225"/>
<string key="NSTitle">Services</string>
<string key="NSKeyEquiv"/>
<int key="NSKeyEquivModMask">1048576</int>
<int key="NSMnemonicLoc">2147483647</int>
<reference key="NSOnImage" ref="77751979"/>
<reference key="NSMixedImage" ref="907913823"/>
<string key="NSAction">submenuAction:</string>
<object class="NSMenu" key="NSSubmenu" id="344449109">
<string key="NSTitle">Services</string>
<array class="NSMutableArray" key="NSMenuItems"/>
<string key="NSName">_NSServicesMenu</string>
</object>
</object>
<object class="NSMenuItem" id="1050756762">
<reference key="NSMenu" ref="870519225"/>
<bool key="NSIsDisabled">YES</bool>
<bool key="NSIsSeparator">YES</bool>
<string key="NSTitle"/>
<string key="NSKeyEquiv"/>
<int key="NSKeyEquivModMask">1048576</int>
<int key="NSMnemonicLoc">2147483647</int>
<reference key="NSOnImage" ref="77751979"/>
<reference key="NSMixedImage" ref="907913823"/>
</object>
<object class="NSMenuItem" id="287068359">
<reference key="NSMenu" ref="870519225"/>
<string key="NSTitle">Hide OSXGLEssentialPractices</string>
<string key="NSKeyEquiv">h</string>
<int key="NSKeyEquivModMask">1048576</int>
<int key="NSMnemonicLoc">2147483647</int>
<reference key="NSOnImage" ref="77751979"/>
<reference key="NSMixedImage" ref="907913823"/>
</object>
<object class="NSMenuItem" id="942645836">
<reference key="NSMenu" ref="870519225"/>
<string key="NSTitle">Hide Others</string>
<string key="NSKeyEquiv">h</string>
<int key="NSKeyEquivModMask">1572864</int>
<int key="NSMnemonicLoc">2147483647</int>
<reference key="NSOnImage" ref="77751979"/>
<reference key="NSMixedImage" ref="907913823"/>
</object>
<object class="NSMenuItem" id="567730237">
<reference key="NSMenu" ref="870519225"/>
<string key="NSTitle">Show All</string>
<string key="NSKeyEquiv"/>
<int key="NSKeyEquivModMask">1048576</int>
<int key="NSMnemonicLoc">2147483647</int>
<reference key="NSOnImage" ref="77751979"/>
<reference key="NSMixedImage" ref="907913823"/>
</object>
<object class="NSMenuItem" id="836990092">
<reference key="NSMenu" ref="870519225"/>
<bool key="NSIsDisabled">YES</bool>
<bool key="NSIsSeparator">YES</bool>
<string key="NSTitle"/>
<string key="NSKeyEquiv"/>
<int key="NSKeyEquivModMask">1048576</int>
<int key="NSMnemonicLoc">2147483647</int>
<reference key="NSOnImage" ref="77751979"/>
<reference key="NSMixedImage" ref="907913823"/>
</object>
<object class="NSMenuItem" id="767000474">
<reference key="NSMenu" ref="870519225"/>
<string key="NSTitle">Quit OSXGLEssentialPractices</string>
<string key="NSKeyEquiv">q</string>
<int key="NSKeyEquivModMask">1048576</int>
<int key="NSMnemonicLoc">2147483647</int>
<reference key="NSOnImage" ref="77751979"/>
<reference key="NSMixedImage" ref="907913823"/>
</object>
</array>
<string key="NSName">_NSAppleMenu</string>
</object>
</object>
<object class="NSMenuItem" id="102739154">
<reference key="NSMenu" ref="272187220"/>
<string key="NSTitle">Help</string>
<string key="NSKeyEquiv"/>
<int key="NSMnemonicLoc">2147483647</int>
<reference key="NSOnImage" ref="77751979"/>
<reference key="NSMixedImage" ref="907913823"/>
<string key="NSAction">submenuAction:</string>
<object class="NSMenu" key="NSSubmenu" id="631823079">
<string key="NSTitle">Help</string>
<array class="NSMutableArray" key="NSMenuItems">
<object class="NSMenuItem" id="621165125">
<reference key="NSMenu" ref="631823079"/>
<string key="NSTitle">MacGLEssentialPractices Help</string>
<string key="NSKeyEquiv">?</string>
<int key="NSKeyEquivModMask">1048576</int>
<int key="NSMnemonicLoc">2147483647</int>
<reference key="NSOnImage" ref="77751979"/>
<reference key="NSMixedImage" ref="907913823"/>
</object>
</array>
<string key="NSName">_NSHelpMenu</string>
</object>
</object>
</array>
<string key="NSName">_NSMainMenu</string>
</object>
<object class="NSWindowTemplate" id="414626874">
<int key="NSWindowStyleMask">15</int>
<int key="NSWindowBacking">2</int>
<string key="NSWindowRect">{{200, 200}, {320, 480}}</string>
<int key="NSWTFlags">1954021376</int>
<string key="NSWindowTitle">OSXGLEssentialPractices</string>
<string key="NSWindowClass">NSWindow</string>
<nil key="NSViewClass"/>
<nil key="NSUserInterfaceItemIdentifier"/>
<object class="NSView" key="NSWindowView" id="10404108">
<nil key="NSNextResponder"/>
<int key="NSvFlags">1792</int>
<object class="NSPSMatrix" key="NSFrameMatrix"/>
<string key="NSFrameSize">{320, 480}</string>
</object>
<string key="NSScreenRect">{{0, 0}, {1920, 1178}}</string>
<string key="NSMaxSize">{10000000000000, 10000000000000}</string>
<bool key="NSWindowIsRestorable">YES</bool>
</object>
<object class="NSCustomObject" id="869686893">
<string key="NSClassName">GLEssentialsGLView</string>
</object>
<object class="NSCustomObject" id="862971392">
<string key="NSClassName">GLEssentialsWindowController</string>
</object>
</array>
<object class="IBObjectContainer" key="IBDocument.Objects">
<bool key="usesAutoincrementingIDs">NO</bool>
<array class="NSMutableArray" key="connectionRecords">
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">terminate:</string>
<reference key="source" ref="405552742"/>
<reference key="destination" ref="767000474"/>
</object>
<string key="id">449</string>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">orderFrontStandardAboutPanel:</string>
<reference key="source" ref="486364360"/>
<reference key="destination" ref="1031860713"/>
</object>
<string key="id">142</string>
</object>
<object class="IBConnectionRecord">
<object class="IBOutletConnection" key="connection">
<string key="label">delegate</string>
<reference key="source" ref="486364360"/>
<reference key="destination" ref="869686893"/>
</object>
<string key="id">495</string>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">hide:</string>
<reference key="source" ref="1035516885"/>
<reference key="destination" ref="287068359"/>
</object>
<string key="id">367</string>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">hideOtherApplications:</string>
<reference key="source" ref="1035516885"/>
<reference key="destination" ref="942645836"/>
</object>
<string key="id">368</string>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">showHelp:</string>
<reference key="source" ref="1035516885"/>
<reference key="destination" ref="621165125"/>
</object>
<string key="id">493</string>
</object>
<object class="IBConnectionRecord">
<object class="IBActionConnection" key="connection">
<string key="label">unhideAllApplications:</string>
<reference key="source" ref="1035516885"/>
<reference key="destination" ref="567730237"/>
</object>
<string key="id">370</string>
</object>
<object class="IBConnectionRecord">
<object class="IBOutletConnection" key="connection">
<string key="label">view</string>
<reference key="source" ref="862971392"/>
<reference key="destination" ref="10404108"/>
</object>
<string key="id">hMc-Rf-8LH</string>
</object>
<object class="IBConnectionRecord">
<object class="IBOutletConnection" key="connection">
<string key="label">window</string>
<reference key="source" ref="862971392"/>
<reference key="destination" ref="414626874"/>
</object>
<string key="id">z3B-S9-PsV</string>
</object>
</array>
<object class="IBMutableOrderedSet" key="objectRecords">
<array key="orderedObjects">
<object class="IBObjectRecord">
<string key="id">0</string>
<array key="object" id="0"/>
<reference key="children" ref="90632081"/>
<nil key="parent"/>
</object>
<object class="IBObjectRecord">
<string key="id">-2</string>
<reference key="object" ref="486364360"/>
<reference key="parent" ref="0"/>
<string key="objectName">File's Owner</string>
</object>
<object class="IBObjectRecord">
<string key="id">-1</string>
<reference key="object" ref="1035516885"/>
<reference key="parent" ref="0"/>
<string key="objectName">First Responder</string>
</object>
<object class="IBObjectRecord">
<string key="id">-3</string>
<reference key="object" ref="405552742"/>
<reference key="parent" ref="0"/>
<string key="objectName">Application</string>
</object>
<object class="IBObjectRecord">
<string key="id">29</string>
<reference key="object" ref="272187220"/>
<array class="NSMutableArray" key="children">
<reference ref="358823679"/>
<reference ref="102739154"/>
</array>
<reference key="parent" ref="0"/>
</object>
<object class="IBObjectRecord">
<string key="id">56</string>
<reference key="object" ref="358823679"/>
<array class="NSMutableArray" key="children">
<reference ref="870519225"/>
</array>
<reference key="parent" ref="272187220"/>
</object>
<object class="IBObjectRecord">
<string key="id">57</string>
<reference key="object" ref="870519225"/>
<array class="NSMutableArray" key="children">
<reference ref="1031860713"/>
<reference ref="419577662"/>
<reference ref="580600437"/>
<reference ref="32280392"/>
<reference ref="827343213"/>
<reference ref="1050756762"/>
<reference ref="287068359"/>
<reference ref="942645836"/>
<reference ref="567730237"/>
<reference ref="836990092"/>
<reference ref="767000474"/>
</array>
<reference key="parent" ref="358823679"/>
</object>
<object class="IBObjectRecord">
<string key="id">58</string>
<reference key="object" ref="1031860713"/>
<reference key="parent" ref="870519225"/>
</object>
<object class="IBObjectRecord">
<string key="id">236</string>
<reference key="object" ref="419577662"/>
<reference key="parent" ref="870519225"/>
</object>
<object class="IBObjectRecord">
<string key="id">129</string>
<reference key="object" ref="580600437"/>
<reference key="parent" ref="870519225"/>
</object>
<object class="IBObjectRecord">
<string key="id">143</string>
<reference key="object" ref="32280392"/>
<reference key="parent" ref="870519225"/>
</object>
<object class="IBObjectRecord">
<string key="id">131</string>
<reference key="object" ref="827343213"/>
<array class="NSMutableArray" key="children">
<reference ref="344449109"/>
</array>
<reference key="parent" ref="870519225"/>
</object>
<object class="IBObjectRecord">
<string key="id">130</string>
<reference key="object" ref="344449109"/>
<reference key="parent" ref="827343213"/>
</object>
<object class="IBObjectRecord">
<string key="id">144</string>
<reference key="object" ref="1050756762"/>
<reference key="parent" ref="870519225"/>
</object>
<object class="IBObjectRecord">
<string key="id">134</string>
<reference key="object" ref="287068359"/>
<reference key="parent" ref="870519225"/>
</object>
<object class="IBObjectRecord">
<string key="id">145</string>
<reference key="object" ref="942645836"/>
<reference key="parent" ref="870519225"/>
</object>
<object class="IBObjectRecord">
<string key="id">150</string>
<reference key="object" ref="567730237"/>
<reference key="parent" ref="870519225"/>
</object>
<object class="IBObjectRecord">
<string key="id">149</string>
<reference key="object" ref="836990092"/>
<reference key="parent" ref="870519225"/>
</object>
<object class="IBObjectRecord">
<string key="id">136</string>
<reference key="object" ref="767000474"/>
<reference key="parent" ref="870519225"/>
</object>
<object class="IBObjectRecord">
<string key="id">490</string>
<reference key="object" ref="102739154"/>
<array class="NSMutableArray" key="children">
<reference ref="631823079"/>
</array>
<reference key="parent" ref="272187220"/>
</object>
<object class="IBObjectRecord">
<string key="id">491</string>
<reference key="object" ref="631823079"/>
<array class="NSMutableArray" key="children">
<reference ref="621165125"/>
</array>
<reference key="parent" ref="102739154"/>
</object>
<object class="IBObjectRecord">
<string key="id">492</string>
<reference key="object" ref="621165125"/>
<reference key="parent" ref="631823079"/>
<string key="objectName">Menu Item - OSXGLEssentialPractices Help</string>
</object>
<object class="IBObjectRecord">
<string key="id">371</string>
<reference key="object" ref="414626874"/>
<array class="NSMutableArray" key="children">
<reference ref="10404108"/>
</array>
<reference key="parent" ref="0"/>
<string key="objectName">Window - OSXGLEssentialPractices</string>
</object>
<object class="IBObjectRecord">
<string key="id">372</string>
<reference key="object" ref="10404108"/>
<reference key="parent" ref="414626874"/>
</object>
<object class="IBObjectRecord">
<string key="id">494</string>
<reference key="object" ref="869686893"/>
<reference key="parent" ref="0"/>
<string key="objectName">GL Essentials View</string>
</object>
<object class="IBObjectRecord">
<string key="id">M8b-ga-iOS</string>
<reference key="object" ref="862971392"/>
<reference key="parent" ref="0"/>
<string key="objectName">GL Essentials Window Controller</string>
</object>
</array>
</object>
<dictionary class="NSMutableDictionary" key="flattenedProperties">
<string key="-1.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="-1.showNotes"/>
<string key="-2.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="-2.showNotes"/>
<string key="-3.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="-3.showNotes"/>
<string key="129.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="129.showNotes"/>
<string key="130.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="130.showNotes"/>
<string key="131.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="131.showNotes"/>
<string key="134.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="134.showNotes"/>
<string key="136.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="136.showNotes"/>
<string key="143.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="143.showNotes"/>
<string key="144.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="144.showNotes"/>
<string key="145.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="145.showNotes"/>
<string key="149.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="149.showNotes"/>
<string key="150.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="150.showNotes"/>
<string key="236.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="236.showNotes"/>
<string key="29.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="29.showNotes"/>
<boolean value="NO" key="371.IBNSWindowAutoPositionCentersHorizontal"/>
<boolean value="NO" key="371.IBNSWindowAutoPositionCentersVertical"/>
<string key="371.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="YES" key="371.NSWindowTemplate.visibleAtLaunch"/>
<boolean value="NO" key="371.showNotes"/>
<string key="372.CustomClassName">GLEssentialsGLView</string>
<string key="372.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<reference key="372.IBUserGuides" ref="0"/>
<boolean value="NO" key="372.showNotes"/>
<string key="490.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="490.showNotes"/>
<string key="491.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="491.showNotes"/>
<string key="492.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="492.showNotes"/>
<string key="494.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="494.showNotes"/>
<string key="56.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="56.showNotes"/>
<string key="57.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="57.showNotes"/>
<string key="58.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<boolean value="NO" key="58.showNotes"/>
<string key="M8b-ga-iOS.IBPluginDependency">com.apple.InterfaceBuilder.CocoaPlugin</string>
<string key="M8b-ga-iOS.object.labelIdentifier">IBBuiltInLabel-Blue</string>
<boolean value="NO" key="M8b-ga-iOS.showNotes"/>
</dictionary>
<dictionary class="NSMutableDictionary" key="unlocalizedProperties"/>
<nil key="activeLocalization"/>
<dictionary class="NSMutableDictionary" key="localizations"/>
<nil key="sourceID"/>
</object>
<object class="IBClassDescriber" key="IBDocument.Classes">
<array class="NSMutableArray" key="referencedPartialClassDescriptions">
<object class="IBPartialClassDescription">
<string key="className">GLEssentialsGLView</string>
<string key="superclassName">NSOpenGLView</string>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBProjectSource</string>
<string key="minorKey">./Classes/GLEssentialsGLView.h</string>
</object>
</object>
<object class="IBPartialClassDescription">
<string key="className">GLEssentialsWindowController</string>
<string key="superclassName">NSWindowController</string>
<object class="NSMutableDictionary" key="outlets">
<string key="NS.key.0">view</string>
<string key="NS.object.0">GLEssentialsGLView</string>
</object>
<object class="NSMutableDictionary" key="toOneOutletInfosByName">
<string key="NS.key.0">view</string>
<object class="IBToOneOutletInfo" key="NS.object.0">
<string key="name">view</string>
<string key="candidateClassName">GLEssentialsGLView</string>
</object>
</object>
<object class="IBClassDescriptionSource" key="sourceIdentifier">
<string key="majorKey">IBProjectSource</string>
<string key="minorKey">./Classes/GLEssentialsWindowController.h</string>
</object>
</object>
</array>
</object>
<int key="IBDocument.localizationMode">0</int>
<string key="IBDocument.TargetRuntimeIdentifier">IBCocoaFramework</string>
<object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDependencies">
<string key="NS.key.0">com.apple.InterfaceBuilder.CocoaPlugin.macosx</string>
<integer value="1060" key="NS.object.0"/>
</object>
<object class="NSMutableDictionary" key="IBDocument.PluginDeclaredDevelopmentDependencies">
<string key="NS.key.0">com.apple.InterfaceBuilder.CocoaPlugin.InterfaceBuilder3</string>
<integer value="4600" key="NS.object.0"/>
</object>
<bool key="IBDocument.PluginDeclaredDependenciesTrackSystemTargetVersion">YES</bool>
<int key="IBDocument.defaultPropertyAccessControl">3</int>
<dictionary class="NSMutableDictionary" key="IBDocument.LastKnownImageSizes">
<string key="NSMenuCheckmark">{11, 11}</string>
<string key="NSMenuMixedState">{10, 3}</string>
</dictionary>
</data>
</archive>

5
GLEssentials/OSX/main.m

@ -0,0 +1,5 @@
@import Cocoa;
int main(int argc, char *argv[]){
return NSApplicationMain(argc, (const char **) argv);
}

13
GLEssentials/iOS/AppDelegate.h

@ -0,0 +1,13 @@
//
// AppDelegate.h
// temp
//
// Created by Joshua Moerman on 07/03/14.
// Copyright (c) 2014 Joshua Moerman. All rights reserved.
//
@import UIKit;
@interface AppDelegate : UIResponder <UIApplicationDelegate>
@property (strong, nonatomic) UIWindow *window;
@end

40
GLEssentials/iOS/AppDelegate.m

@ -0,0 +1,40 @@
//
// AppDelegate.m
// temp
//
// Created by Joshua Moerman on 07/03/14.
// Copyright (c) 2014 Joshua Moerman. All rights reserved.
//
#import "AppDelegate.h"
@implementation AppDelegate
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions{
// Override point for customization after application launch.
return YES;
}
- (void)applicationWillResignActive:(UIApplication *)application{
// Sent when the application is about to move from active to inactive state. This can occur for certain types of temporary interruptions (such as an incoming phone call or SMS message) or when the user quits the application and it begins the transition to the background state.
// Use this method to pause ongoing tasks, disable timers, and throttle down OpenGL ES frame rates. Games should use this method to pause the game.
}
- (void)applicationDidEnterBackground:(UIApplication *)application{
// Use this method to release shared resources, save user data, invalidate timers, and store enough application state information to restore your application to its current state in case it is terminated later.
// If your application supports background execution, this method is called instead of applicationWillTerminate: when the user quits.
}
- (void)applicationWillEnterForeground:(UIApplication *)application{
// Called as part of the transition from the background to the inactive state; here you can undo many of the changes made on entering the background.
}
- (void)applicationDidBecomeActive:(UIApplication *)application{
// Restart any tasks that were paused (or not yet started) while the application was inactive. If the application was previously in the background, optionally refresh the user interface.
}
- (void)applicationWillTerminate:(UIApplication *)application{
// Called when the application is about to terminate. Save data if appropriate. See also applicationDidEnterBackground:.
}
@end

49
GLEssentials/iOS/GLEssentials-Info.plist

@ -0,0 +1,49 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleDevelopmentRegion</key>
<string>English</string>
<key>CFBundleDisplayName</key>
<string>${PRODUCT_NAME}</string>
<key>CFBundleExecutable</key>
<string>${EXECUTABLE_NAME}</string>
<key>CFBundleIdentifier</key>
<string>com.example.apple-samplecode.${PRODUCT_NAME:rfc1034identifier}</string>
<key>CFBundleInfoDictionaryVersion</key>
<string>6.0</string>
<key>CFBundleName</key>
<string>${PRODUCT_NAME}</string>
<key>CFBundlePackageType</key>
<string>APPL</string>
<key>CFBundleShortVersionString</key>
<string>1.7</string>
<key>CFBundleSignature</key>
<string>????</string>
<key>CFBundleVersion</key>
<string>1.0</string>
<key>LSRequiresIPhoneOS</key>
<true/>
<key>UIMainStoryboardFile</key>
<string>Main_iPhone</string>
<key>UIMainStoryboardFile~ipad</key>
<string>Main_iPad</string>
<key>UIRequiredDeviceCapabilities</key>
<array>
<string>opengles-2</string>
</array>
<key>UISupportedInterfaceOrientations</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
</array>
<key>UISupportedInterfaceOrientations~ipad</key>
<array>
<string>UIInterfaceOrientationPortrait</string>
<string>UIInterfaceOrientationLandscapeLeft</string>
<string>UIInterfaceOrientationLandscapeRight</string>
<string>UIInterfaceOrientationPortraitUpsideDown</string>
</array>
</dict>
</plist>

26
GLEssentials/iOS/Main_iPad.storyboard

@ -0,0 +1,26 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="4451" systemVersion="13A461" targetRuntime="iOS.CocoaTouch.iPad" propertyAccessControl="none" useAutolayout="YES" initialViewController="BV1-FR-VrT">
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="3676"/>
</dependencies>
<scenes>
<!--class Prefix:identifier View Controller-->
<scene sceneID="tXr-a1-R10">
<objects>
<glkViewController preferredFramesPerSecond="30" id="BV1-FR-VrT" customClass="ViewController" sceneMemberID="viewController">
<glkView key="view" contentMode="scaleToFill" id="3se-qz-xqx">
<rect key="frame" x="0.0" y="0.0" width="768" height="1024"/>
<autoresizingMask key="autoresizingMask" widthSizable="YES" heightSizable="YES"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
</glkView>
</glkViewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="SZV-WD-TEh" sceneMemberID="firstResponder"/>
</objects>
</scene>
</scenes>
<simulatedMetricsContainer key="defaultSimulatedMetrics">
<nil key="statusBar"/>
<simulatedOrientationMetrics key="orientation"/>
<simulatedScreenMetrics key="destination"/>
</simulatedMetricsContainer>
</document>

26
GLEssentials/iOS/Main_iPhone.storyboard

@ -0,0 +1,26 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<document type="com.apple.InterfaceBuilder3.CocoaTouch.Storyboard.XIB" version="3.0" toolsVersion="4451" systemVersion="13A461" targetRuntime="iOS.CocoaTouch" propertyAccessControl="none" useAutolayout="YES" initialViewController="LVB-YS-i5n">
<dependencies>
<plugIn identifier="com.apple.InterfaceBuilder.IBCocoaTouchPlugin" version="3676"/>
</dependencies>
<scenes>
<!--class Prefix:identifier View Controller-->
<scene sceneID="CtS-rA-C9T">
<objects>
<glkViewController preferredFramesPerSecond="30" id="LVB-YS-i5n" customClass="ViewController" sceneMemberID="viewController">
<glkView key="view" contentMode="scaleToFill" id="bdc-N1-crn">
<rect key="frame" x="0.0" y="0.0" width="320" height="568"/>
<autoresizingMask key="autoresizingMask" flexibleMaxX="YES" flexibleMaxY="YES"/>
<color key="backgroundColor" white="1" alpha="1" colorSpace="custom" customColorSpace="calibratedWhite"/>
</glkView>
</glkViewController>
<placeholder placeholderIdentifier="IBFirstResponder" id="btX-cZ-eVz" sceneMemberID="firstResponder"/>
</objects>
</scene>
</scenes>
<simulatedMetricsContainer key="defaultSimulatedMetrics">
<nil key="statusBar"/>
<simulatedOrientationMetrics key="orientation"/>
<simulatedScreenMetrics key="destination" type="retina4"/>
</simulatedMetricsContainer>
</document>

12
GLEssentials/iOS/ViewController.h

@ -0,0 +1,12 @@
//
// ViewController.h
// temp
//
// Created by Joshua Moerman on 07/03/14.
// Copyright (c) 2014 Joshua Moerman. All rights reserved.
//
@import GLKit;
@interface ViewController : GLKViewController
@end

90
GLEssentials/iOS/ViewController.m

@ -0,0 +1,90 @@
//
// ViewController.m
// temp
//
// Created by Joshua Moerman on 07/03/14.
// Copyright (c) 2014 Joshua Moerman. All rights reserved.
//
#import "ViewController.h"
#import "Game.h"
@interface ViewController () {
Game * game;
}
@property (nonatomic) EAGLContext *context;
- (void)setupGL;
- (void)tearDownGL;
@end
@implementation ViewController
- (void)viewDidLoad{
[super viewDidLoad];
// all devices supporting ios 5 also support ES 2.0
// only a couple of devices support ES 3.0
self.context = [[EAGLContext alloc] initWithAPI:kEAGLRenderingAPIOpenGLES2];
assert(self.context);
GLKView *view = (GLKView *)self.view;
view.context = self.context;
view.drawableDepthFormat = GLKViewDrawableDepthFormat24;
view.drawableMultisample = GLKViewDrawableMultisampleNone;
view.contentScaleFactor = 1.0;
self.preferredFramesPerSecond = 60;
[self setupGL];
}
- (void)dealloc{
[self tearDownGL];
if ([EAGLContext currentContext] == self.context) {
[EAGLContext setCurrentContext:nil];
}
}
- (void)didReceiveMemoryWarning{
[super didReceiveMemoryWarning];
if (self.isViewLoaded && (!self.view.window)) {
self.view = nil;
[self tearDownGL];
if ([EAGLContext currentContext] == self.context) {
[EAGLContext setCurrentContext:nil];
}
self.context = nil;
}
// Dispose of any resources that can be recreated.
}
- (void)setupGL{
[EAGLContext setCurrentContext:self.context];
game = [[Game alloc] init];
}
- (void)tearDownGL{
[EAGLContext setCurrentContext:self.context];
game = nil;
}
#pragma mark - GLKView and GLKViewController delegate methods
- (void)update{
[game update:self.timeSinceLastUpdate];
}
- (void)glkView:(GLKView *)view drawInRect:(CGRect)rect{
// If we drew on a different fbo in the meantime, do this
[((GLKView *) self.view) bindDrawable];
[game draw];
}
@end

8
GLEssentials/iOS/main.m

@ -0,0 +1,8 @@
@import UIKit;
#import "AppDelegate.h"
int main(int argc, char *argv[]){
@autoreleasepool {
return UIApplicationMain(argc, argv, nil, NSStringFromClass([AppDelegate class]));
}
}

254
OSXGLEssentials.xcodeproj/project.pbxproj

@ -0,0 +1,254 @@
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objects = {
/* Begin PBXBuildFile section */
4295A2CA18CB4E5100A58D8F /* GLEssentialsFullscreenWindow.m in Sources */ = {isa = PBXBuildFile; fileRef = 4295A2C318CB4E5100A58D8F /* GLEssentialsFullscreenWindow.m */; };
4295A2CB18CB4E5100A58D8F /* GLEssentialsGLView.m in Sources */ = {isa = PBXBuildFile; fileRef = 4295A2C518CB4E5100A58D8F /* GLEssentialsGLView.m */; };
4295A2CC18CB4E5100A58D8F /* GLEssentialsWindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = 4295A2C718CB4E5100A58D8F /* GLEssentialsWindowController.m */; };
4295A2E018CB68A400A58D8F /* Game.m in Sources */ = {isa = PBXBuildFile; fileRef = 4295A2DF18CB68A400A58D8F /* Game.m */; };
4295A2EB18CBB0F700A58D8F /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 4295A2EA18CBB0F700A58D8F /* main.m */; };
4295A2F318CBB22800A58D8F /* MainMenu.xib in Resources */ = {isa = PBXBuildFile; fileRef = 4295A2F218CBB22800A58D8F /* MainMenu.xib */; };
4295A2F718CBBFF100A58D8F /* Fractal.vsh in Sources */ = {isa = PBXBuildFile; fileRef = 4295A2F618CBBFF100A58D8F /* Fractal.vsh */; };
4295A2F918CBC00600A58D8F /* Fractal.fsh in Sources */ = {isa = PBXBuildFile; fileRef = 4295A2F818CBC00500A58D8F /* Fractal.fsh */; };
4295A2FA18CBC15000A58D8F /* Fractal.vsh in Resources */ = {isa = PBXBuildFile; fileRef = 4295A2F618CBBFF100A58D8F /* Fractal.vsh */; };
4295A2FB18CBC15000A58D8F /* Fractal.fsh in Resources */ = {isa = PBXBuildFile; fileRef = 4295A2F818CBC00500A58D8F /* Fractal.fsh */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
3A1598D311B9DDB0001E7AB5 /* OSXGLEssentials.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = OSXGLEssentials.app; sourceTree = BUILT_PRODUCTS_DIR; };
4295A2C218CB4E5100A58D8F /* GLEssentialsFullscreenWindow.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GLEssentialsFullscreenWindow.h; path = GLEssentials/OSX/GLEssentialsFullscreenWindow.h; sourceTree = "<group>"; };
4295A2C318CB4E5100A58D8F /* GLEssentialsFullscreenWindow.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = GLEssentialsFullscreenWindow.m; path = GLEssentials/OSX/GLEssentialsFullscreenWindow.m; sourceTree = "<group>"; };
4295A2C418CB4E5100A58D8F /* GLEssentialsGLView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GLEssentialsGLView.h; path = GLEssentials/OSX/GLEssentialsGLView.h; sourceTree = "<group>"; };
4295A2C518CB4E5100A58D8F /* GLEssentialsGLView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = GLEssentialsGLView.m; path = GLEssentials/OSX/GLEssentialsGLView.m; sourceTree = "<group>"; };
4295A2C618CB4E5100A58D8F /* GLEssentialsWindowController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GLEssentialsWindowController.h; path = GLEssentials/OSX/GLEssentialsWindowController.h; sourceTree = "<group>"; };
4295A2C718CB4E5100A58D8F /* GLEssentialsWindowController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = GLEssentialsWindowController.m; path = GLEssentials/OSX/GLEssentialsWindowController.m; sourceTree = "<group>"; };
4295A2DE18CB68A400A58D8F /* Game.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = Game.h; path = GLEssentials/Game.h; sourceTree = "<group>"; };
4295A2DF18CB68A400A58D8F /* Game.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = Game.m; path = GLEssentials/Game.m; sourceTree = "<group>"; };
4295A2EA18CBB0F700A58D8F /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = GLEssentials/OSX/main.m; sourceTree = "<group>"; };
4295A2F018CBB1D200A58D8F /* GLEssentials-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = "GLEssentials-Info.plist"; path = "GLEssentials/OSX/GLEssentials-Info.plist"; sourceTree = "<group>"; };
4295A2F218CBB22800A58D8F /* MainMenu.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; name = MainMenu.xib; path = GLEssentials/OSX/MainMenu.xib; sourceTree = "<group>"; };
4295A2F618CBBFF100A58D8F /* Fractal.vsh */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; name = Fractal.vsh; path = GLEssentials/Fractal.vsh; sourceTree = "<group>"; };
4295A2F818CBC00500A58D8F /* Fractal.fsh */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; name = Fractal.fsh; path = GLEssentials/Fractal.fsh; sourceTree = "<group>"; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
8D11072E0486CEB800E47090 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
080E96DDFE201D6D7F000001 /* GLEssentials */ = {
isa = PBXGroup;
children = (
4295A2DE18CB68A400A58D8F /* Game.h */,
4295A2DF18CB68A400A58D8F /* Game.m */,
4295A2F618CBBFF100A58D8F /* Fractal.vsh */,
4295A2F818CBC00500A58D8F /* Fractal.fsh */,
4295A2F418CBB24A00A58D8F /* OSX */,
29B97315FDCFA39411CA2CEA /* Supporting Files */,
);
name = GLEssentials;
sourceTree = "<group>";
};
19C28FACFE9D520D11CA2CBB /* Products */ = {
isa = PBXGroup;
children = (
3A1598D311B9DDB0001E7AB5 /* OSXGLEssentials.app */,
);
name = Products;
sourceTree = "<group>";
};
29B97314FDCFA39411CA2CEA /* OSXGLEssentials */ = {
isa = PBXGroup;
children = (
080E96DDFE201D6D7F000001 /* GLEssentials */,
19C28FACFE9D520D11CA2CBB /* Products */,
);
name = OSXGLEssentials;
sourceTree = "<group>";
};
29B97315FDCFA39411CA2CEA /* Supporting Files */ = {
isa = PBXGroup;
children = (
4295A2F018CBB1D200A58D8F /* GLEssentials-Info.plist */,
4295A2EA18CBB0F700A58D8F /* main.m */,
);
name = "Supporting Files";
sourceTree = "<group>";
};
4295A2F418CBB24A00A58D8F /* OSX */ = {
isa = PBXGroup;
children = (
4295A2C218CB4E5100A58D8F /* GLEssentialsFullscreenWindow.h */,
4295A2C318CB4E5100A58D8F /* GLEssentialsFullscreenWindow.m */,
4295A2C418CB4E5100A58D8F /* GLEssentialsGLView.h */,
4295A2C518CB4E5100A58D8F /* GLEssentialsGLView.m */,
4295A2C618CB4E5100A58D8F /* GLEssentialsWindowController.h */,
4295A2C718CB4E5100A58D8F /* GLEssentialsWindowController.m */,
4295A2F218CBB22800A58D8F /* MainMenu.xib */,
);
name = OSX;
sourceTree = "<group>";
};
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
8D1107260486CEB800E47090 /* OSXGLEssentials */ = {
isa = PBXNativeTarget;
buildConfigurationList = C01FCF4A08A954540054247B /* Build configuration list for PBXNativeTarget "OSXGLEssentials" */;
buildPhases = (
8D1107290486CEB800E47090 /* Resources */,
8D11072C0486CEB800E47090 /* Sources */,
8D11072E0486CEB800E47090 /* Frameworks */,
);
buildRules = (
);
dependencies = (
);
name = OSXGLEssentials;
productInstallPath = "$(HOME)/Applications";
productName = OSXGLEssentials;
productReference = 3A1598D311B9DDB0001E7AB5 /* OSXGLEssentials.app */;
productType = "com.apple.product-type.application";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
29B97313FDCFA39411CA2CEA /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0450;
};
buildConfigurationList = C01FCF4E08A954540054247B /* Build configuration list for PBXProject "OSXGLEssentials" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
hasScannedForEncodings = 1;
knownRegions = (
English,
Japanese,
French,
German,
);
mainGroup = 29B97314FDCFA39411CA2CEA /* OSXGLEssentials */;
projectDirPath = "";
projectRoot = "";
targets = (
8D1107260486CEB800E47090 /* OSXGLEssentials */,
);
};
/* End PBXProject section */
/* Begin PBXResourcesBuildPhase section */
8D1107290486CEB800E47090 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
4295A2FA18CBC15000A58D8F /* Fractal.vsh in Resources */,
4295A2FB18CBC15000A58D8F /* Fractal.fsh in Resources */,
4295A2F318CBB22800A58D8F /* MainMenu.xib in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
8D11072C0486CEB800E47090 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
4295A2F918CBC00600A58D8F /* Fractal.fsh in Sources */,
4295A2EB18CBB0F700A58D8F /* main.m in Sources */,
4295A2F718CBBFF100A58D8F /* Fractal.vsh in Sources */,
4295A2CA18CB4E5100A58D8F /* GLEssentialsFullscreenWindow.m in Sources */,
4295A2CC18CB4E5100A58D8F /* GLEssentialsWindowController.m in Sources */,
4295A2E018CB68A400A58D8F /* Game.m in Sources */,
4295A2CB18CB4E5100A58D8F /* GLEssentialsGLView.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin XCBuildConfiguration section */
C01FCF4B08A954540054247B /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
COMBINE_HIDPI_IMAGES = YES;
COPY_PHASE_STRIP = NO;
GCC_MODEL_TUNING = G5;
INFOPLIST_FILE = "$(SRCROOT)/GLEssentials/OSX/GLEssentials-Info.plist";
INSTALL_PATH = "$(HOME)/Applications";
PRODUCT_NAME = OSXGLEssentials;
};
name = Debug;
};
C01FCF4C08A954540054247B /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
COMBINE_HIDPI_IMAGES = YES;
DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
GCC_MODEL_TUNING = G5;
INFOPLIST_FILE = "$(SRCROOT)/GLEssentials/OSX/GLEssentials-Info.plist";
INSTALL_PATH = "$(HOME)/Applications";
PRODUCT_NAME = OSXGLEssentials;
};
name = Release;
};
C01FCF4F08A954540054247B /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
GCC_OPTIMIZATION_LEVEL = 0;
GCC_PREPROCESSOR_DEFINITIONS = "DEBUG=1";
};
name = Debug;
};
C01FCF5008A954540054247B /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
GCC_C_LANGUAGE_STANDARD = gnu99;
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
C01FCF4A08A954540054247B /* Build configuration list for PBXNativeTarget "OSXGLEssentials" */ = {
isa = XCConfigurationList;
buildConfigurations = (
C01FCF4B08A954540054247B /* Debug */,
C01FCF4C08A954540054247B /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
C01FCF4E08A954540054247B /* Build configuration list for PBXProject "OSXGLEssentials" */ = {
isa = XCConfigurationList;
buildConfigurations = (
C01FCF4F08A954540054247B /* Debug */,
C01FCF5008A954540054247B /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = 29B97313FDCFA39411CA2CEA /* Project object */;
}

20
README.md

@ -0,0 +1,20 @@
# GLMinimals
Very minimaal Xcode projects for OpenGL apps (both OSX and iOS).
## Motivation
I wanted a unified framework for OpenGL on both OSX and iOS without to much of a hassle (less is more). Just to play around easily and to see what the differences are between OSX and iOS. However, the sample code "GLEssentials" provided by Apple was very outdated, so I modernized it.
## Changes include:
* Converted to ARC
* Usage of obj-c modules
* Usage of GLKit (instead of doing everything by hand with EAGLayers and the like)
* Removed their basic glUtils (as such functionality is in GLKit anyways)
* Restructered project and a lot of simplifications
* Retina is supported by default
## Where to plug in
Just change Game.h and Game.mm to whatever you like. Note that everything in there is hardcoded and should not be regarded as example code.

32
Readme.txt

@ -0,0 +1,32 @@
GLEssentials
================================================================================
DESCRIPTION:
This sample provides an example of some of the techniques described in the
"OpenGL Essential Design Practices" WWDC 2010 session. There are usages of
Vertex Buffer Objects (VBOs), Vertex Array Objects (VAOs), Framebuffer Objects
(FBO), and GLSL Program Objects. It creates a VAO and VBOs from model data
loaded in. It creates a texture for the model from image data and GLSL shaders
from source also loaded in. It also creates an FBO and texture to render a
reflection of the model. It uses an environment mapping GLSL program to apply
the reflection texture to a plane. This sample also demonstrates sharing of
OpenGL ES source code for iPhone OS and OpenGL source code for OS X.
Additionally, it implement fullscreen rendering, retina display support, and
demonstrates how to obtain and use an OpenGL 3.2 rendering context on OS X.
================================================================================
BUILD REQUIREMENTS:
Mac version: Mac OS X v10.6 or later, Xcode 3.1 or later
iOS version: iOS SDK 4.0 or later
================================================================================
RUNTIME REQUIREMENTS:
Mac version: Mac OS X v10.6 or later
Mac version: Mac OS X Lion or later to use OpenGL 3.2
iOS version: iOS 4.0 or later (with OpenGL ES 2.0 support)
================================================================================
Copyright (C) 2010~2013 Apple Inc. All rights reserved.

269
iOSGLEssentials.xcodeproj/project.pbxproj

@ -0,0 +1,269 @@
// !$*UTF8*$!
{
archiveVersion = 1;
classes = {
};
objectVersion = 46;
objects = {
/* Begin PBXBuildFile section */
4295A2AC18CA2C1200A58D8F /* AppDelegate.m in Sources */ = {isa = PBXBuildFile; fileRef = 4295A2A718CA2C1200A58D8F /* AppDelegate.m */; };
4295A2AD18CA2C1200A58D8F /* Main_iPad.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 4295A2A818CA2C1200A58D8F /* Main_iPad.storyboard */; };
4295A2AE18CA2C1200A58D8F /* Main_iPhone.storyboard in Resources */ = {isa = PBXBuildFile; fileRef = 4295A2A918CA2C1200A58D8F /* Main_iPhone.storyboard */; };
4295A2AF18CA2C1200A58D8F /* ViewController.m in Sources */ = {isa = PBXBuildFile; fileRef = 4295A2AB18CA2C1200A58D8F /* ViewController.m */; };
4295A2DD18CB58B200A58D8F /* Game.m in Sources */ = {isa = PBXBuildFile; fileRef = 4295A2DC18CB58B200A58D8F /* Game.m */; };
4295A2ED18CBB11900A58D8F /* main.m in Sources */ = {isa = PBXBuildFile; fileRef = 4295A2EC18CBB11900A58D8F /* main.m */; };
4295A2EF18CBB1C800A58D8F /* GLEssentials-Info.plist in Resources */ = {isa = PBXBuildFile; fileRef = 4295A2EE18CBB1C800A58D8F /* GLEssentials-Info.plist */; };
4295A2FE18CBC7D800A58D8F /* Fractal-iOS.fsh in Sources */ = {isa = PBXBuildFile; fileRef = 4295A2FC18CBC7D800A58D8F /* Fractal-iOS.fsh */; };
4295A2FF18CBC7D800A58D8F /* Fractal-iOS.vsh in Sources */ = {isa = PBXBuildFile; fileRef = 4295A2FD18CBC7D800A58D8F /* Fractal-iOS.vsh */; };
4295A30018CBC81700A58D8F /* Fractal-iOS.fsh in Resources */ = {isa = PBXBuildFile; fileRef = 4295A2FC18CBC7D800A58D8F /* Fractal-iOS.fsh */; };
4295A30118CBC81700A58D8F /* Fractal-iOS.vsh in Resources */ = {isa = PBXBuildFile; fileRef = 4295A2FD18CBC7D800A58D8F /* Fractal-iOS.vsh */; };
/* End PBXBuildFile section */
/* Begin PBXFileReference section */
3A609E3811B9DB3300AA4C48 /* iOSGLEssentials.app */ = {isa = PBXFileReference; explicitFileType = wrapper.application; includeInIndex = 0; path = iOSGLEssentials.app; sourceTree = BUILT_PRODUCTS_DIR; };
4295A2A618CA2C1200A58D8F /* AppDelegate.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = AppDelegate.h; path = GLEssentials/iOS/AppDelegate.h; sourceTree = "<group>"; };
4295A2A718CA2C1200A58D8F /* AppDelegate.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = AppDelegate.m; path = GLEssentials/iOS/AppDelegate.m; sourceTree = "<group>"; };
4295A2A818CA2C1200A58D8F /* Main_iPad.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = Main_iPad.storyboard; path = GLEssentials/iOS/Main_iPad.storyboard; sourceTree = "<group>"; };
4295A2A918CA2C1200A58D8F /* Main_iPhone.storyboard */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.storyboard; name = Main_iPhone.storyboard; path = GLEssentials/iOS/Main_iPhone.storyboard; sourceTree = "<group>"; };
4295A2AA18CA2C1200A58D8F /* ViewController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = ViewController.h; path = GLEssentials/iOS/ViewController.h; sourceTree = "<group>"; };
4295A2AB18CA2C1200A58D8F /* ViewController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = ViewController.m; path = GLEssentials/iOS/ViewController.m; sourceTree = "<group>"; };
4295A2DB18CB58B200A58D8F /* Game.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = Game.h; path = GLEssentials/Game.h; sourceTree = "<group>"; };
4295A2DC18CB58B200A58D8F /* Game.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = Game.m; path = GLEssentials/Game.m; sourceTree = "<group>"; };
4295A2EC18CBB11900A58D8F /* main.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = main.m; path = GLEssentials/iOS/main.m; sourceTree = "<group>"; };
4295A2EE18CBB1C800A58D8F /* GLEssentials-Info.plist */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text.plist.xml; name = "GLEssentials-Info.plist"; path = "GLEssentials/iOS/GLEssentials-Info.plist"; sourceTree = "<group>"; };
4295A2FC18CBC7D800A58D8F /* Fractal-iOS.fsh */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; name = "Fractal-iOS.fsh"; path = "GLEssentials/Fractal-iOS.fsh"; sourceTree = "<group>"; };
4295A2FD18CBC7D800A58D8F /* Fractal-iOS.vsh */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.glsl; name = "Fractal-iOS.vsh"; path = "GLEssentials/Fractal-iOS.vsh"; sourceTree = "<group>"; };
/* End PBXFileReference section */
/* Begin PBXFrameworksBuildPhase section */
1D60588F0D05DD3D006BFB54 /* Frameworks */ = {
isa = PBXFrameworksBuildPhase;
buildActionMask = 2147483647;
files = (
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXFrameworksBuildPhase section */
/* Begin PBXGroup section */
19C28FACFE9D520D11CA2CBB /* Products */ = {
isa = PBXGroup;
children = (
3A609E3811B9DB3300AA4C48 /* iOSGLEssentials.app */,
);
name = Products;
sourceTree = "<group>";
};
29B97314FDCFA39411CA2CEA /* CustomTemplate */ = {
isa = PBXGroup;
children = (
4295A2A518CA2C0300A58D8F /* GLEssentials */,
19C28FACFE9D520D11CA2CBB /* Products */,
);
name = CustomTemplate;
sourceTree = "<group>";
};
4295A2A518CA2C0300A58D8F /* GLEssentials */ = {
isa = PBXGroup;
children = (
4295A2FC18CBC7D800A58D8F /* Fractal-iOS.fsh */,
4295A2FD18CBC7D800A58D8F /* Fractal-iOS.vsh */,
4295A2DB18CB58B200A58D8F /* Game.h */,
4295A2DC18CB58B200A58D8F /* Game.m */,
4295A2F518CBB26C00A58D8F /* iOS */,
4295A2B018CA2C1600A58D8F /* Supporting Files */,
);
name = GLEssentials;
sourceTree = "<group>";
};
4295A2B018CA2C1600A58D8F /* Supporting Files */ = {
isa = PBXGroup;
children = (
4295A2EE18CBB1C800A58D8F /* GLEssentials-Info.plist */,
4295A2EC18CBB11900A58D8F /* main.m */,
);
name = "Supporting Files";
sourceTree = "<group>";
};
4295A2F518CBB26C00A58D8F /* iOS */ = {
isa = PBXGroup;
children = (
4295A2A618CA2C1200A58D8F /* AppDelegate.h */,
4295A2A718CA2C1200A58D8F /* AppDelegate.m */,
4295A2A818CA2C1200A58D8F /* Main_iPad.storyboard */,
4295A2A918CA2C1200A58D8F /* Main_iPhone.storyboard */,
4295A2AA18CA2C1200A58D8F /* ViewController.h */,
4295A2AB18CA2C1200A58D8F /* ViewController.m */,
);
name = iOS;
sourceTree = "<group>";
};
/* End PBXGroup section */
/* Begin PBXNativeTarget section */
1D6058900D05DD3D006BFB54 /* GLEssentials */ = {
isa = PBXNativeTarget;
buildConfigurationList = 1D6058960D05DD3E006BFB54 /* Build configuration list for PBXNativeTarget "GLEssentials" */;
buildPhases = (
1D60588D0D05DD3D006BFB54 /* Resources */,
1D60588E0D05DD3D006BFB54 /* Sources */,
1D60588F0D05DD3D006BFB54 /* Frameworks */,
);
buildRules = (
);
dependencies = (
);
name = GLEssentials;
productName = iOSGLEssentials;
productReference = 3A609E3811B9DB3300AA4C48 /* iOSGLEssentials.app */;
productType = "com.apple.product-type.application";
};
/* End PBXNativeTarget section */
/* Begin PBXProject section */
29B97313FDCFA39411CA2CEA /* Project object */ = {
isa = PBXProject;
attributes = {
LastUpgradeCheck = 0420;
};
buildConfigurationList = C01FCF4E08A954540054247B /* Build configuration list for PBXProject "iOSGLEssentials" */;
compatibilityVersion = "Xcode 3.2";
developmentRegion = English;
hasScannedForEncodings = 1;
knownRegions = (
English,
Japanese,
French,
German,
);
mainGroup = 29B97314FDCFA39411CA2CEA /* CustomTemplate */;
projectDirPath = "";
projectRoot = "";
targets = (
1D6058900D05DD3D006BFB54 /* GLEssentials */,
);
};
/* End PBXProject section */
/* Begin PBXResourcesBuildPhase section */
1D60588D0D05DD3D006BFB54 /* Resources */ = {
isa = PBXResourcesBuildPhase;
buildActionMask = 2147483647;
files = (
4295A30018CBC81700A58D8F /* Fractal-iOS.fsh in Resources */,
4295A30118CBC81700A58D8F /* Fractal-iOS.vsh in Resources */,
4295A2AE18CA2C1200A58D8F /* Main_iPhone.storyboard in Resources */,
4295A2AD18CA2C1200A58D8F /* Main_iPad.storyboard in Resources */,
4295A2EF18CBB1C800A58D8F /* GLEssentials-Info.plist in Resources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXResourcesBuildPhase section */
/* Begin PBXSourcesBuildPhase section */
1D60588E0D05DD3D006BFB54 /* Sources */ = {
isa = PBXSourcesBuildPhase;
buildActionMask = 2147483647;
files = (
4295A2DD18CB58B200A58D8F /* Game.m in Sources */,
4295A2FF18CBC7D800A58D8F /* Fractal-iOS.vsh in Sources */,
4295A2AF18CA2C1200A58D8F /* ViewController.m in Sources */,
4295A2FE18CBC7D800A58D8F /* Fractal-iOS.fsh in Sources */,
4295A2ED18CBB11900A58D8F /* main.m in Sources */,
4295A2AC18CA2C1200A58D8F /* AppDelegate.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};
/* End PBXSourcesBuildPhase section */
/* Begin XCBuildConfiguration section */
1D6058940D05DD3E006BFB54 /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
CLANG_WARN_OBJC_MISSING_PROPERTY_SYNTHESIS = NO;
COPY_PHASE_STRIP = NO;
GCC_DYNAMIC_NO_PIC = NO;
GCC_OPTIMIZATION_LEVEL = 0;
INFOPLIST_FILE = "$(SRCROOT)/GLEssentials/iOS/GLEssentials-Info.plist";
PRODUCT_NAME = iOSGLEssentials;
SDKROOT = iphoneos;
TARGETED_DEVICE_FAMILY = "1,2";
};
name = Debug;
};
1D6058950D05DD3E006BFB54 /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
ALWAYS_SEARCH_USER_PATHS = NO;
ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;
CLANG_WARN_OBJC_MISSING_PROPERTY_SYNTHESIS = NO;
COPY_PHASE_STRIP = YES;
INFOPLIST_FILE = "$(SRCROOT)/GLEssentials/iOS/GLEssentials-Info.plist";
PRODUCT_NAME = iOSGLEssentials;
SDKROOT = iphoneos;
TARGETED_DEVICE_FAMILY = "1,2";
VALIDATE_PRODUCT = YES;
};
name = Release;
};
C01FCF4F08A954540054247B /* Debug */ = {
isa = XCBuildConfiguration;
buildSettings = {
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
GCC_C_LANGUAGE_STANDARD = c99;
GCC_PREPROCESSOR_DEFINITIONS = ESSENTIAL_GL_PRACTICES_IOS;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 7.0;
SUPPORTED_PLATFORMS = "iphonesimulator iphoneos";
};
name = Debug;
};
C01FCF5008A954540054247B /* Release */ = {
isa = XCBuildConfiguration;
buildSettings = {
CLANG_ENABLE_MODULES = YES;
CLANG_ENABLE_OBJC_ARC = YES;
"CODE_SIGN_IDENTITY[sdk=iphoneos*]" = "iPhone Developer";
GCC_C_LANGUAGE_STANDARD = c99;
GCC_PREPROCESSOR_DEFINITIONS = ESSENTIAL_GL_PRACTICES_IOS;
GCC_WARN_ABOUT_RETURN_TYPE = YES;
GCC_WARN_UNUSED_VARIABLE = YES;
IPHONEOS_DEPLOYMENT_TARGET = 7.0;
OTHER_CFLAGS = "-DNS_BLOCK_ASSERTIONS=1";
SUPPORTED_PLATFORMS = "iphonesimulator iphoneos";
};
name = Release;
};
/* End XCBuildConfiguration section */
/* Begin XCConfigurationList section */
1D6058960D05DD3E006BFB54 /* Build configuration list for PBXNativeTarget "GLEssentials" */ = {
isa = XCConfigurationList;
buildConfigurations = (
1D6058940D05DD3E006BFB54 /* Debug */,
1D6058950D05DD3E006BFB54 /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
C01FCF4E08A954540054247B /* Build configuration list for PBXProject "iOSGLEssentials" */ = {
isa = XCConfigurationList;
buildConfigurations = (
C01FCF4F08A954540054247B /* Debug */,
C01FCF5008A954540054247B /* Release */,
);
defaultConfigurationIsVisible = 0;
defaultConfigurationName = Release;
};
/* End XCConfigurationList section */
};
rootObject = 29B97313FDCFA39411CA2CEA /* Project object */;
}