Commit a0311cef authored by Robert Menzel's avatar Robert Menzel
parents 5f4bbdbc 157d4ded
......@@ -26,7 +26,7 @@ const char *debugSeverityName( GLenum _type );
void ACGLRegisterDefaultDebugCallback();
//! default debug callback
void APIENTRY ACGL_KHR_default_debug_callback( GLenum _source, GLenum _type, GLuint _id, GLenum _severity, GLsizei _length, const GLchar *_message, const void *_userParam);
void APIENTRY ACGL_KHR_default_debug_callback( GLenum _source, GLenum _type, GLuint _id, GLenum _severity, GLsizei _length, const GLchar *_message, void *_userParam);
} // OpenGL
} // ACGL
......
......@@ -141,8 +141,8 @@ typedef unsigned int GLhandleARB;
typedef struct __GLsync *GLsync;
struct _cl_context;
struct _cl_event;
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef unsigned short GLhalfNV;
typedef GLintptr GLvdpauSurfaceNV;
......@@ -1297,7 +1297,7 @@ typedef unsigned int GLhandleARB;
#define glGetDebugMessageLogARB _ptrc_glGetDebugMessageLogARB
// Extension: KHR_debug
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *);
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *);
#define glDebugMessageCallback _ptrc_glDebugMessageCallback
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean);
#define glDebugMessageControl _ptrc_glDebugMessageControl
......
......@@ -141,8 +141,8 @@ typedef unsigned int GLhandleARB;
typedef struct __GLsync *GLsync;
struct _cl_context;
struct _cl_event;
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef unsigned short GLhalfNV;
typedef GLintptr GLvdpauSurfaceNV;
......@@ -1838,7 +1838,7 @@ typedef unsigned int GLhandleARB;
#define glGetDebugMessageLogARB _ptrc_glGetDebugMessageLogARB
// Extension: KHR_debug
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *);
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *);
#define glDebugMessageCallback _ptrc_glDebugMessageCallback
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean);
#define glDebugMessageControl _ptrc_glDebugMessageControl
......
......@@ -141,8 +141,8 @@ typedef unsigned int GLhandleARB;
typedef struct __GLsync *GLsync;
struct _cl_context;
struct _cl_event;
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef unsigned short GLhalfNV;
typedef GLintptr GLvdpauSurfaceNV;
......@@ -1898,7 +1898,7 @@ typedef unsigned int GLhandleARB;
#define glGetDebugMessageLogARB _ptrc_glGetDebugMessageLogARB
// Extension: KHR_debug
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *);
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *);
#define glDebugMessageCallback _ptrc_glDebugMessageCallback
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean);
#define glDebugMessageControl _ptrc_glDebugMessageControl
......
......@@ -141,8 +141,8 @@ typedef unsigned int GLhandleARB;
typedef struct __GLsync *GLsync;
struct _cl_context;
struct _cl_event;
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef unsigned short GLhalfNV;
typedef GLintptr GLvdpauSurfaceNV;
......@@ -1536,7 +1536,7 @@ typedef unsigned int GLhandleARB;
#define glGetDebugMessageLogARB _ptrc_glGetDebugMessageLogARB
// Extension: KHR_debug
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *);
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *);
#define glDebugMessageCallback _ptrc_glDebugMessageCallback
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean);
#define glDebugMessageControl _ptrc_glDebugMessageControl
......
......@@ -141,8 +141,8 @@ typedef unsigned int GLhandleARB;
typedef struct __GLsync *GLsync;
struct _cl_context;
struct _cl_event;
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef unsigned short GLhalfNV;
typedef GLintptr GLvdpauSurfaceNV;
......@@ -1554,7 +1554,7 @@ typedef unsigned int GLhandleARB;
#define glGetDebugMessageLogARB _ptrc_glGetDebugMessageLogARB
// Extension: KHR_debug
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *);
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *);
#define glDebugMessageCallback _ptrc_glDebugMessageCallback
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean);
#define glDebugMessageControl _ptrc_glDebugMessageControl
......
......@@ -141,8 +141,8 @@ typedef unsigned int GLhandleARB;
typedef struct __GLsync *GLsync;
struct _cl_context;
struct _cl_event;
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef unsigned short GLhalfNV;
typedef GLintptr GLvdpauSurfaceNV;
......@@ -1633,7 +1633,7 @@ typedef unsigned int GLhandleARB;
#define glGetDebugMessageLogARB _ptrc_glGetDebugMessageLogARB
// Extension: KHR_debug
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *);
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *);
#define glDebugMessageCallback _ptrc_glDebugMessageCallback
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean);
#define glDebugMessageControl _ptrc_glDebugMessageControl
......
......@@ -141,8 +141,8 @@ typedef unsigned int GLhandleARB;
typedef struct __GLsync *GLsync;
struct _cl_context;
struct _cl_event;
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef unsigned short GLhalfNV;
typedef GLintptr GLvdpauSurfaceNV;
......@@ -1670,7 +1670,7 @@ typedef unsigned int GLhandleARB;
#define glGetDebugMessageLogARB _ptrc_glGetDebugMessageLogARB
// Extension: KHR_debug
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *);
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *);
#define glDebugMessageCallback _ptrc_glDebugMessageCallback
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean);
#define glDebugMessageControl _ptrc_glDebugMessageControl
......
......@@ -141,8 +141,8 @@ typedef unsigned int GLhandleARB;
typedef struct __GLsync *GLsync;
struct _cl_context;
struct _cl_event;
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef unsigned short GLhalfNV;
typedef GLintptr GLvdpauSurfaceNV;
......@@ -1776,7 +1776,7 @@ typedef unsigned int GLhandleARB;
#define glGetDebugMessageLogARB _ptrc_glGetDebugMessageLogARB
// Extension: KHR_debug
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *);
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *);
#define glDebugMessageCallback _ptrc_glDebugMessageCallback
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean);
#define glDebugMessageControl _ptrc_glDebugMessageControl
......
......@@ -141,8 +141,8 @@ typedef unsigned int GLhandleARB;
typedef struct __GLsync *GLsync;
struct _cl_context;
struct _cl_event;
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef unsigned short GLhalfNV;
typedef GLintptr GLvdpauSurfaceNV;
......@@ -2037,7 +2037,7 @@ typedef unsigned int GLhandleARB;
#define glGetDebugMessageLogARB _ptrc_glGetDebugMessageLogARB
// Extension: KHR_debug
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *);
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *);
#define glDebugMessageCallback _ptrc_glDebugMessageCallback
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean);
#define glDebugMessageControl _ptrc_glDebugMessageControl
......
......@@ -141,8 +141,8 @@ typedef unsigned int GLhandleARB;
typedef struct __GLsync *GLsync;
struct _cl_context;
struct _cl_event;
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef unsigned short GLhalfNV;
typedef GLintptr GLvdpauSurfaceNV;
......@@ -2056,7 +2056,7 @@ typedef unsigned int GLhandleARB;
#define glGetDebugMessageLogARB _ptrc_glGetDebugMessageLogARB
// Extension: KHR_debug
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *);
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *);
#define glDebugMessageCallback _ptrc_glDebugMessageCallback
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean);
#define glDebugMessageControl _ptrc_glDebugMessageControl
......
......@@ -141,8 +141,8 @@ typedef unsigned int GLhandleARB;
typedef struct __GLsync *GLsync;
struct _cl_context;
struct _cl_event;
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef unsigned short GLhalfNV;
typedef GLintptr GLvdpauSurfaceNV;
......@@ -1536,7 +1536,7 @@ typedef unsigned int GLhandleARB;
#define glGetDebugMessageLogARB _ptrc_glGetDebugMessageLogARB
// Extension: KHR_debug
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *);
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *);
#define glDebugMessageCallback _ptrc_glDebugMessageCallback
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean);
#define glDebugMessageControl _ptrc_glDebugMessageControl
......
......@@ -141,8 +141,8 @@ typedef unsigned int GLhandleARB;
typedef struct __GLsync *GLsync;
struct _cl_context;
struct _cl_event;
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef unsigned short GLhalfNV;
typedef GLintptr GLvdpauSurfaceNV;
......@@ -1554,7 +1554,7 @@ typedef unsigned int GLhandleARB;
#define glGetDebugMessageLogARB _ptrc_glGetDebugMessageLogARB
// Extension: KHR_debug
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *);
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *);
#define glDebugMessageCallback _ptrc_glDebugMessageCallback
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean);
#define glDebugMessageControl _ptrc_glDebugMessageControl
......
......@@ -141,8 +141,8 @@ typedef unsigned int GLhandleARB;
typedef struct __GLsync *GLsync;
struct _cl_context;
struct _cl_event;
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef unsigned short GLhalfNV;
typedef GLintptr GLvdpauSurfaceNV;
......@@ -1633,7 +1633,7 @@ typedef unsigned int GLhandleARB;
#define glGetDebugMessageLogARB _ptrc_glGetDebugMessageLogARB
// Extension: KHR_debug
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *);
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *);
#define glDebugMessageCallback _ptrc_glDebugMessageCallback
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean);
#define glDebugMessageControl _ptrc_glDebugMessageControl
......
......@@ -141,8 +141,8 @@ typedef unsigned int GLhandleARB;
typedef struct __GLsync *GLsync;
struct _cl_context;
struct _cl_event;
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef unsigned short GLhalfNV;
typedef GLintptr GLvdpauSurfaceNV;
......@@ -1670,7 +1670,7 @@ typedef unsigned int GLhandleARB;
#define glGetDebugMessageLogARB _ptrc_glGetDebugMessageLogARB
// Extension: KHR_debug
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *);
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *);
#define glDebugMessageCallback _ptrc_glDebugMessageCallback
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean);
#define glDebugMessageControl _ptrc_glDebugMessageControl
......
......@@ -141,8 +141,8 @@ typedef unsigned int GLhandleARB;
typedef struct __GLsync *GLsync;
struct _cl_context;
struct _cl_event;
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef unsigned short GLhalfNV;
typedef GLintptr GLvdpauSurfaceNV;
......@@ -1776,7 +1776,7 @@ typedef unsigned int GLhandleARB;
#define glGetDebugMessageLogARB _ptrc_glGetDebugMessageLogARB
// Extension: KHR_debug
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *);
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *);
#define glDebugMessageCallback _ptrc_glDebugMessageCallback
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean);
#define glDebugMessageControl _ptrc_glDebugMessageControl
......
......@@ -141,8 +141,8 @@ typedef unsigned int GLhandleARB;
typedef struct __GLsync *GLsync;
struct _cl_context;
struct _cl_event;
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef unsigned short GLhalfNV;
typedef GLintptr GLvdpauSurfaceNV;
......@@ -2037,7 +2037,7 @@ typedef unsigned int GLhandleARB;
#define glGetDebugMessageLogARB _ptrc_glGetDebugMessageLogARB
// Extension: KHR_debug
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *);
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *);
#define glDebugMessageCallback _ptrc_glDebugMessageCallback
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean);
#define glDebugMessageControl _ptrc_glDebugMessageControl
......
......@@ -141,8 +141,8 @@ typedef unsigned int GLhandleARB;
typedef struct __GLsync *GLsync;
struct _cl_context;
struct _cl_event;
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,const void *userParam);
typedef void (APIENTRY *GLDEBUGPROC)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCARB)(GLenum source,GLenum type,GLuint id,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef void (APIENTRY *GLDEBUGPROCAMD)(GLuint id,GLenum category,GLenum severity,GLsizei length,const GLchar *message,void *userParam);
typedef unsigned short GLhalfNV;
typedef GLintptr GLvdpauSurfaceNV;
......@@ -2056,7 +2056,7 @@ typedef unsigned int GLhandleARB;
#define glGetDebugMessageLogARB _ptrc_glGetDebugMessageLogARB
// Extension: KHR_debug
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *);
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *);
#define glDebugMessageCallback _ptrc_glDebugMessageCallback
extern void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean);
#define glDebugMessageControl _ptrc_glDebugMessageControl
......
......@@ -139,7 +139,8 @@ class CSystemTimer : public CProcessTimer
{
public:
CSystemTimer() : CProcessTimer() {
ACGL::Utils::error() << "No system timer present on this OS - fallback to process time" << std::endl;
static bool warned = false;
if ( !warned++ ) ACGL::Utils::error() << "No system timer present on this OS - fallback to process time" << std::endl;
}
};
......@@ -147,8 +148,9 @@ public:
class CThreadTimer : public CProcessTimer
{
public:
CThreadTimer() : CProcessTimer() {
ACGL::Utils::error() << "No thread timer present on this OS - fallback to process time" << std::endl;
CThreadTimer() : CProcessTimer() {
static bool warned = false;
if ( !warned++ ) ACGL::Utils::error() << "No thread timer present on this OS - fallback to process time" << std::endl;
}
};
......
......@@ -307,7 +307,9 @@ SharedGeometryData loadGeometryDataFromOBJ(const std::string& _filename, bool _c
glm::vec3 v0 = (glm::vec3)positionData[indices[3 * triangleIndex + 0].position];
glm::vec3 v1 = (glm::vec3)positionData[indices[3 * triangleIndex + 1].position];
glm::vec3 v2 = (glm::vec3)positionData[indices[3 * triangleIndex + 2].position];
glm::vec3 normal = glm::normalize(glm::cross(v1 - v0, v2 - v0));
glm::vec3 normal = glm::cross(v1 - v0, v2 - v0);
if (normal != glm::vec3(0))
normal = glm::normalize(normal);
abData[pos++] = normal.x;
abData[pos++] = normal.y;
abData[pos++] = normal.z;
......
......@@ -265,7 +265,7 @@ void TextureData::setTexel( glm::uvec2 _texCoord, glm::vec4 _color )
GLint *data = (GLint *) (mData+texelOffset);
glm::ivec4 color = glm::ivec4( _color * glm::vec4(2147483648.0f) );
color = glm::clamp( color, glm::ivec4(-2147483648), glm::ivec4(2147483647) );
color = glm::clamp( color, glm::ivec4(std::numeric_limits<int>::min()), glm::ivec4(2147483647) );
data[0] = color.r;
if ( getNumberOfChannels() > 1 ) data[1] = color.g;
......
......@@ -527,6 +527,7 @@ SharedTextureData loadTextureDataFromPNM(const std::string& _filename, ColorSpac
if(offset == 7)
fileStream.ignore(1);
}
else elem = 0;
if(!fileStream.good()) break;
......@@ -692,9 +693,10 @@ bool saveTextureDataToLodepng( const SharedTextureData &_data, const std::string
LodePNGColorType colorType;
if (channelCount == 1) colorType = LCT_GREY;
if (channelCount == 2) colorType = LCT_GREY_ALPHA;
if (channelCount == 3) colorType = LCT_RGB;
if (channelCount == 4) colorType = LCT_RGBA;
else if (channelCount == 2) colorType = LCT_GREY_ALPHA;
else if (channelCount == 3) colorType = LCT_RGB;
else if (channelCount == 4) colorType = LCT_RGBA;
else colorType = LCT_RGBA;
unsigned int errorCode = lodepng_encode_file(_filename.c_str(),
processedData, _data->getWidth(), _data->getHeight(),
......
......@@ -36,7 +36,7 @@ SharedTexture2D loadTexture2D(const std::string& _filename, ColorSpace _colorSpa
} else {
ACGL::Utils::error() << "can't create Texture from file " << _filename << " creating small empty texture instead." << std::endl;
//SharedTexture2D dummy = std::make_shared<Texture2D>();
SharedTexture2D dummy = SharedTexture2D();
SharedTexture2D dummy = SharedTexture2D(new Texture2D);
dummy->resize( glm::uvec2(4,4) );
return dummy;
}
......
......@@ -65,7 +65,7 @@ void ACGLRegisterDefaultDebugCallback()
}
//! place a brakepoint in here to find the source of a problem!
void APIENTRY ACGL_KHR_default_debug_callback( GLenum _source, GLenum _type, GLuint _id, GLenum _severity, GLsizei /*_length*/, const GLchar *_message, const void* /* _userParam*/ )
void APIENTRY ACGL_KHR_default_debug_callback( GLenum _source, GLenum _type, GLuint _id, GLenum _severity, GLsizei /*_length*/, const GLchar *_message, void* /* _userParam*/ )
{
// yes, this could be implemented with less dublicated code, but the
// point here is to have one code path which gets only called in case of an error
......
......@@ -28,6 +28,7 @@ void VertexArrayObject::bind() const
{
glBindVertexArray( mObjectName );
#ifdef ACGL_DEBUG
// check if the EAB actually bound is the same as the one this ACGL object has stored:
GLint myEAB = 0;
GLint boundEAB = 0;
......@@ -43,6 +44,7 @@ void VertexArrayObject::bind() const
// an we end up in an infinite recursion...
glBindBuffer(GL_ELEMENT_ARRAY_BUFFER, myEAB);
}
#endif
}
void VertexArrayObject::attachElementArrayBuffer( const ConstSharedElementArrayBuffer& _elementArrayBuffer )
......
......@@ -64,7 +64,7 @@
// GL state:
GLDEBUGPROC KHR_DEBUG_EMULATOR_callback = NULL;
const void *KHR_DEBUG_EMULATOR_userParam = NULL;
void * KHR_DEBUG_EMULATOR_userParam = NULL;
int KHR_DEBUG_EMULATOR_isEnabled = 1;
int KHR_DEBUG_EMULATOR_isSynchronous = 0;
GLenum KHR_DEBUG_EMULATOR_lastGLError = GL_NO_ERROR;
......@@ -84,10 +84,10 @@ extern GLboolean (CODEGEN_FUNCPTR *_original_glIsEnabled)( GLenum );
extern GLvoid (CODEGEN_FUNCPTR *_original_glGetIntegerv)( GLenum, GLint * );
extern GLvoid (CODEGEN_FUNCPTR *_original_glGetPointerv)( GLenum, GLvoid ** );
// not used in here, just used to check if glClear redirects to the original function ;-)
extern GLvoid (CODEGEN_FUNCPTR *_original_glClear)(GLbitfield);
extern GLvoid(CODEGEN_FUNCPTR *_original_glClear)(GLbitfield);
// shortcut to add OpenGL errors detected by this emulation:
#define INSERT_API_ERROR( e, m ) KHR_DEBUG_EMULATOR_lastGLError = e; KHR_DEBUG_EMULATOR_DebugMessageInsert_internal(GL_DEBUG_SOURCE_API, GL_DEBUG_TYPE_ERROR, e, GL_DEBUG_SEVERITY_HIGH, -1, m );
#define INSERT_API_ERROR( e, m ) do { KHR_DEBUG_EMULATOR_lastGLError = e; KHR_DEBUG_EMULATOR_DebugMessageInsert_internal(GL_DEBUG_SOURCE_API, GL_DEBUG_TYPE_ERROR, e, GL_DEBUG_SEVERITY_HIGH, -1, m ); } while(0)
//
// support to query debug messages (only one):
......@@ -246,7 +246,7 @@ void APIENTRY KHR_DEBUG_EMULATOR_DebugMessageInsert_internal(GLenum source, GLen
/////////////////////////////
GLboolean debugContextIsSimulated();
void APIENTRY KHR_DEBUG_EMULATOR_DebugMessageCallback(GLDEBUGPROC callback, const void * userParam)
void APIENTRY KHR_DEBUG_EMULATOR_DebugMessageCallback(GLDEBUGPROC callback, void * userParam)
{
KHR_DEBUG_EMULATOR_callback = callback;
KHR_DEBUG_EMULATOR_userParam = userParam;
......
......@@ -134,8 +134,8 @@ GLuint (CODEGEN_FUNCPTR *_original_glGetDebugMessageLogARB)(GLuint, GLsizei, GLe
GLuint (CODEGEN_FUNCPTR *_ptrc_glGetDebugMessageLogARB)(GLuint, GLsizei, GLenum *, GLenum *, GLuint *, GLenum *, GLsizei *, GLchar *) = NULL;
// Extension: KHR_debug
void (CODEGEN_FUNCPTR *_original_glDebugMessageCallback)(GLDEBUGPROC, const void *) = NULL;
void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *) = NULL;
void (CODEGEN_FUNCPTR *_original_glDebugMessageCallback)(GLDEBUGPROC, void *) = NULL;
void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *) = NULL;
void (CODEGEN_FUNCPTR *_original_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean) = NULL;
void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean) = NULL;
void (CODEGEN_FUNCPTR *_original_glDebugMessageInsert)(GLenum, GLenum, GLuint, GLenum, GLsizei, const GLchar *) = NULL;
......@@ -2439,7 +2439,7 @@ static int Load_ARB_debug_output()
static int Load_KHR_debug()
{
int numFailed = 0;
_original_glDebugMessageCallback = (void (CODEGEN_FUNCPTR *)(GLDEBUGPROC, const void *))IntGetProcAddress("glDebugMessageCallback");
_original_glDebugMessageCallback = (void (CODEGEN_FUNCPTR *)(GLDEBUGPROC, void *))IntGetProcAddress("glDebugMessageCallback");
if(!_original_glDebugMessageCallback) numFailed++;
_original_glDebugMessageControl = (void (CODEGEN_FUNCPTR *)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean))IntGetProcAddress("glDebugMessageControl");
if(!_original_glDebugMessageControl) numFailed++;
......@@ -2468,7 +2468,7 @@ static int Load_KHR_debug()
void APIENTRY KHR_DEBUG_EMULATOR_DebugMessageInsert(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar * buf);
void APIENTRY KHR_DEBUG_EMULATOR_DebugMessageCallback(GLDEBUGPROC callback, const void * userParam);
void APIENTRY KHR_DEBUG_EMULATOR_DebugMessageCallback(GLDEBUGPROC callback, void * userParam);
void APIENTRY KHR_DEBUG_EMULATOR_DebugMessageControl(GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint * ids, GLboolean enabled);
......@@ -2605,8 +2605,8 @@ GLuint APIENTRY wrapperglGetDebugMessageLogARB(GLuint count, GLsizei bufsize, GL
// Extension: KHR_debug
// WRAPPER FOR void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *)
void APIENTRY wrapperglDebugMessageCallback(GLDEBUGPROC callback, const void * userParam){
// WRAPPER FOR void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *)
void APIENTRY wrapperglDebugMessageCallback(GLDEBUGPROC callback, void * userParam){
_original_glDebugMessageCallback(callback, userParam);
KHR_DEBUG_EMULATOR_CHECK_GL_ERROR();
}
......
......@@ -164,8 +164,8 @@ GLuint (CODEGEN_FUNCPTR *_original_glGetDebugMessageLogARB)(GLuint, GLsizei, GLe
GLuint (CODEGEN_FUNCPTR *_ptrc_glGetDebugMessageLogARB)(GLuint, GLsizei, GLenum *, GLenum *, GLuint *, GLenum *, GLsizei *, GLchar *) = NULL;
// Extension: KHR_debug
void (CODEGEN_FUNCPTR *_original_glDebugMessageCallback)(GLDEBUGPROC, const void *) = NULL;
void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *) = NULL;
void (CODEGEN_FUNCPTR *_original_glDebugMessageCallback)(GLDEBUGPROC, void *) = NULL;
void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *) = NULL;
void (CODEGEN_FUNCPTR *_original_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean) = NULL;
void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageControl)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean) = NULL;
void (CODEGEN_FUNCPTR *_original_glDebugMessageInsert)(GLenum, GLenum, GLuint, GLenum, GLsizei, const GLchar *) = NULL;
......@@ -3067,7 +3067,7 @@ static int Load_ARB_debug_output()
static int Load_KHR_debug()
{
int numFailed = 0;
_original_glDebugMessageCallback = (void (CODEGEN_FUNCPTR *)(GLDEBUGPROC, const void *))IntGetProcAddress("glDebugMessageCallback");
_original_glDebugMessageCallback = (void (CODEGEN_FUNCPTR *)(GLDEBUGPROC, void *))IntGetProcAddress("glDebugMessageCallback");
if(!_original_glDebugMessageCallback) numFailed++;
_original_glDebugMessageControl = (void (CODEGEN_FUNCPTR *)(GLenum, GLenum, GLenum, GLsizei, const GLuint *, GLboolean))IntGetProcAddress("glDebugMessageControl");
if(!_original_glDebugMessageControl) numFailed++;
......@@ -3428,7 +3428,7 @@ static int Load_NV_copy_image()
void APIENTRY KHR_DEBUG_EMULATOR_DebugMessageInsert(GLenum source, GLenum type, GLuint id, GLenum severity, GLsizei length, const GLchar * buf);
void APIENTRY KHR_DEBUG_EMULATOR_DebugMessageCallback(GLDEBUGPROC callback, const void * userParam);
void APIENTRY KHR_DEBUG_EMULATOR_DebugMessageCallback(GLDEBUGPROC callback, void * userParam);
void APIENTRY KHR_DEBUG_EMULATOR_DebugMessageControl(GLenum source, GLenum type, GLenum severity, GLsizei count, const GLuint * ids, GLboolean enabled);
......@@ -3565,8 +3565,8 @@ GLuint APIENTRY wrapperglGetDebugMessageLogARB(GLuint count, GLsizei bufsize, GL
// Extension: KHR_debug
// WRAPPER FOR void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, const void *)
void APIENTRY wrapperglDebugMessageCallback(GLDEBUGPROC callback, const void * userParam){
// WRAPPER FOR void (CODEGEN_FUNCPTR *_ptrc_glDebugMessageCallback)(GLDEBUGPROC, void *)
void APIENTRY wrapperglDebugMessageCallback(GLDEBUGPROC callback, void * userParam){
_original_glDebugMessageCallback(callback, userParam);
KHR_DEBUG_EMULATOR_CHECK_GL_ERROR();
}
......