libgoatvr

diff src/opengl.h @ 30:1a8343ea54ce

fixed on windows
author John Tsiombikas <nuclear@member.fsf.org>
date Sat, 11 Apr 2015 04:01:47 +0300
parents 0fea7c2b25d7
children
line diff
     1.1 --- a/src/opengl.h	Wed Apr 08 02:32:22 2015 +0300
     1.2 +++ b/src/opengl.h	Sat Apr 11 04:01:47 2015 +0300
     1.3 @@ -13,12 +13,18 @@
     1.4  #include <GL/gl.h>
     1.5  #endif
     1.6  
     1.7 +#include "glext.h"
     1.8 +
     1.9  #ifdef __unix__
    1.10  #include <GL/glx.h>
    1.11  #endif
    1.12  
    1.13  void vrimp_swap_buffers(void);
    1.14  
    1.15 -void (*vrimp_glfunc(const char *name))();
    1.16 +#if defined(__unix__)
    1.17 +#define vrimp_glfunc(n) glXGetProcAddress(n)
    1.18 +#elif defined(WIN32)
    1.19 +#define vrimp_glfunc(n)	wglGetProcAddress(n)
    1.20 +#endif
    1.21  
    1.22  #endif	/* VR_OPENGL_H_ */