bkaradzic пре 12 година
родитељ
комит
10236da0f4
3 измењених фајлова са 5 додато и 3 уклоњено
  1. 1 1
      premake/bgfx.lua
  2. 3 1
      src/glcontext_wgl.cpp
  3. 1 1
      src/renderer_gl.cpp

+ 1 - 1
premake/bgfx.lua

@@ -30,7 +30,7 @@ project "bgfx"
 			BGFX_DIR .. "src/**.mm",
 		}
 
-	configuration { "vs* or linux" }
+	configuration { "vs* or linux or mingw" }
 		includedirs {
 			--nacl has GLES2 headers modified...
 			BGFX_DIR .. "3rdparty/glext",

+ 3 - 1
src/glcontext_wgl.cpp

@@ -203,7 +203,7 @@ namespace bgfx
 
 			uint32_t flags = BGFX_CONFIG_DEBUG ? WGL_CONTEXT_DEBUG_BIT_ARB : 0;
 			BX_UNUSED(flags);
-			int32_t contextAttrs[] =
+			int32_t contextAttrs[9] =
 			{
 #if BGFX_CONFIG_RENDERER_OPENGL >= 31
 				WGL_CONTEXT_MAJOR_VERSION_ARB, 3,
@@ -213,6 +213,8 @@ namespace bgfx
 #else
 				WGL_CONTEXT_MAJOR_VERSION_ARB, 2,
 				WGL_CONTEXT_MINOR_VERSION_ARB, 1,
+				0, 0,
+				0, 0,
 #endif // BGFX_CONFIG_RENDERER_OPENGL >= 31
 				0
 			};

+ 1 - 1
src/renderer_gl.cpp

@@ -180,7 +180,7 @@ namespace bgfx
 		glGetError(); // ignore error if glGetString returns NULL.
 		if (NULL != str)
 		{
-			return bx::hashMurmur2A(str, strlen(str) );
+			return bx::hashMurmur2A(str, (uint32_t)strlen(str) );
 		}
 
 		return 0;