提交 bf371437 编写于 作者: J jp9000

Fixed debug extension check

 - Check the actual debug extension instead of checking GL 4.0 support;
   it appears that despite having GL 4.0 support, AMD does not implement
   the standard debug extensions even when the *_CONTEXT_DEBUG_BIT_ARB
   flag is set on the context.

 - Also, fixed a place where spaces where used for indents instead of a
   tab.
上级 156009cc
......@@ -73,10 +73,8 @@ static void gl_enable_debug()
{
/* Perhaps we should create GLEW contexts? */
if (GLEW_VERSION_4_0)
if (GLEW_ARB_debug_output)
glDebugMessageCallback(gl_debug_proc, NULL);
else if (GLEW_ARB_debug_output)
glDebugMessageCallbackARB(gl_debug_proc, NULL);
else {
blog(LOG_DEBUG, "Failed to set GL debug callback as it is "
"not supported.");
......
......@@ -156,7 +156,7 @@ static inline HGLRC gl_init_basic_context(HDC hdc)
static const int attribs[] =
{
#ifdef _DEBUG
WGL_CONTEXT_FLAGS_ARB, WGL_CONTEXT_DEBUG_BIT_ARB,
WGL_CONTEXT_FLAGS_ARB, WGL_CONTEXT_DEBUG_BIT_ARB,
#endif
WGL_CONTEXT_PROFILE_MASK_ARB, WGL_CONTEXT_CORE_PROFILE_BIT_ARB,
0, 0
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册