From f953b7c9bddb09a10b5b8c41805fc16ebeee5dfc Mon Sep 17 00:00:00 2001 From: Charlie Barto Date: Thu, 20 Mar 2014 00:50:44 -0400 Subject: [PATCH] fixed dylib paths on OSX and changed the type of GLHandle from int to GLuint --- src/opengl.nim | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/opengl.nim b/src/opengl.nim index 6549cc6..0ed2da9 100644 --- a/src/opengl.nim +++ b/src/opengl.nim @@ -25,9 +25,11 @@ when defined(windows): ogldll* = "OpenGL32.dll" gludll* = "GLU32.dll" elif defined(macosx): + #macosx has this notion of a framework, thus the path to the openGL dylib files + #is absolute const - ogldll* = "libGL.dylib" - gludll* = "libGLU.dylib" + ogldll* = "/System/Library/Frameworks/OpenGL.framework/Versions/Current/Libraries/libGL.dylib" + gludll* = "/System/Library/Frameworks/OpenGL.framework/Versions/Current/Libraries/libGLU.dylib" else: const ogldll* = "libGL.so.1" @@ -533,7 +535,7 @@ type GLsizeiptr* = GLsizei # GL_ARB_vertex_buffer_object GLintptrARB* = GLint GLsizeiptrARB* = GLsizei # GL_VERSION_2_0 - GLHandle* = int + GLHandle* = GLuint PGLchar* = cstring PPGLchar* = ptr PGLChar # GL_EXT_timer_query GLint64EXT* = Int64