Created
July 3, 2018 18:36
-
-
Save spacepluk/7d44431070dc95816440f2a308ca1c35 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/examples/01-cubes/cubes.cpp b/examples/01-cubes/cubes.cpp | |
index 0e96c370..131126a8 100644 | |
--- a/examples/01-cubes/cubes.cpp | |
+++ b/examples/01-cubes/cubes.cpp | |
@@ -148,7 +148,7 @@ public: | |
// Set view 0 clear state. | |
bgfx::setViewClear(0 | |
, BGFX_CLEAR_COLOR|BGFX_CLEAR_DEPTH | |
- , 0x303030ff | |
+ , 0x00000000 | |
, 1.0f | |
, 0 | |
); | |
diff --git a/examples/20-nanovg/nanovg.cpp b/examples/20-nanovg/nanovg.cpp | |
index 8d0e91ee..bd38bc36 100644 | |
--- a/examples/20-nanovg/nanovg.cpp | |
+++ b/examples/20-nanovg/nanovg.cpp | |
@@ -1264,7 +1264,7 @@ public: | |
// Set view 0 clear state. | |
bgfx::setViewClear(0 | |
, BGFX_CLEAR_COLOR|BGFX_CLEAR_DEPTH | |
- , 0x303030ff | |
+ , 0x00000000 | |
, 1.0f | |
, 0 | |
); | |
diff --git a/examples/common/entry/entry_glfw.cpp b/examples/common/entry/entry_glfw.cpp | |
index 5e81dd9a..6006ccc7 100644 | |
--- a/examples/common/entry/entry_glfw.cpp | |
+++ b/examples/common/entry/entry_glfw.cpp | |
@@ -7,7 +7,7 @@ | |
#if ENTRY_CONFIG_USE_GLFW | |
-#define GLFW_INCLUDE_NONE | |
+//#define GLFW_INCLUDE_NONE | |
#include <GLFW/glfw3.h> | |
#if GLFW_VERSION_MINOR < 2 | |
@@ -53,13 +53,15 @@ namespace entry | |
bgfx::PlatformData pd; | |
# if BX_PLATFORM_LINUX || BX_PLATFORM_BSD | |
pd.ndt = glfwGetX11Display(); | |
+ pd.context = glfwGetGLXContext(_window); | |
# elif BX_PLATFORM_OSX | |
pd.ndt = NULL; | |
+ pd.context = NULL; | |
# elif BX_PLATFORM_WINDOWS | |
pd.ndt = NULL; | |
+ pd.context = NULL; | |
# endif // BX_PLATFORM_WINDOWS | |
pd.nwh = glfwNativeWindowHandle(_window); | |
- pd.context = NULL; | |
pd.backBuffer = NULL; | |
pd.backBufferDS = NULL; | |
bgfx::setPlatformData(pd); | |
@@ -409,7 +411,8 @@ namespace entry | |
glfwSetJoystickCallback(joystickCb); | |
- glfwWindowHint(GLFW_CLIENT_API, GLFW_NO_API); | |
+ glfwWindowHint(GLFW_TRANSPARENT_FRAMEBUFFER, GLFW_TRUE); | |
+ glfwWindowHint(GLFW_DECORATED, GLFW_FALSE); | |
WindowHandle handle = { m_windowAlloc.alloc() }; | |
m_windows[0] = glfwCreateWindow(ENTRY_DEFAULT_WIDTH | |
diff --git a/makefile b/makefile | |
index 5997d37f..a5ee768c 100644 | |
--- a/makefile | |
+++ b/makefile | |
@@ -91,7 +91,7 @@ asmjs-release: .build/projects/gmake-asmjs ## Build - Emscripten Release | |
asmjs: asmjs-debug asmjs-release ## Build - Emscripten Debug and Release | |
.build/projects/gmake-linux: | |
- $(GENIE) --with-tools --with-combined-examples --with-shared-lib --gcc=linux-gcc gmake | |
+ $(GENIE) --with-tools --with-glfw --with-combined-examples --with-shared-lib --gcc=linux-gcc gmake | |
linux-debug64: .build/projects/gmake-linux ## Build - Linux x64 Debug | |
$(MAKE) -R -C .build/projects/gmake-linux config=debug64 | |
linux-release64: .build/projects/gmake-linux ## Build - Linux x64 Release | |
diff --git a/scripts/genie.lua b/scripts/genie.lua | |
index fd6f21f5..935177ae 100644 | |
--- a/scripts/genie.lua | |
+++ b/scripts/genie.lua | |
@@ -164,7 +164,7 @@ function exampleProjectDefaults() | |
if _OPTIONS["with-glfw"] then | |
defines { "ENTRY_CONFIG_USE_GLFW=1" } | |
- links { "glfw3" } | |
+ links { "glfw" } | |
configuration { "linux or freebsd" } | |
links { | |
diff --git a/scripts/texturev.lua b/scripts/texturev.lua | |
index c2425559..255783ca 100644 | |
--- a/scripts/texturev.lua | |
+++ b/scripts/texturev.lua | |
@@ -42,7 +42,7 @@ project ("texturev") | |
if _OPTIONS["with-glfw"] then | |
defines { "ENTRY_CONFIG_USE_GLFW=1" } | |
links { | |
- "glfw3" | |
+ "glfw" | |
} | |
configuration { "linux or freebsd" } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment