diff options
| author | Marco Lizza <[email protected]> | 2019-01-10 14:54:55 +0100 |
|---|---|---|
| committer | Marco Lizza <[email protected]> | 2019-01-10 14:54:55 +0100 |
| commit | 5adcc30a2e3984d2df59e228c9360edf47f63c7a (patch) | |
| tree | 4001a3296e7b6afe583d9c8506cce801ab174bae | |
| parent | e48f2f9d43238293059b5c3ecec8e13eecc9a68b (diff) | |
| download | raylib-5adcc30a2e3984d2df59e228c9360edf47f63c7a.tar.gz raylib-5adcc30a2e3984d2df59e228c9360edf47f63c7a.zip | |
Adding window visibility configuration flag.
| -rw-r--r-- | src/core.c | 3 | ||||
| -rw-r--r-- | src/raylib.h | 5 |
2 files changed, 6 insertions, 2 deletions
@@ -2247,6 +2247,9 @@ static bool InitGraphicsDevice(int width, int height) //glfwWindowHint(GLFW_AUX_BUFFERS, 0); // Number of auxiliar buffers // Check some Window creation flags + if (configFlags & FLAG_WINDOW_HIDDEN) glfwWindowHint(GLFW_VISIBLE, GL_FALSE); // Visible window + else glfwWindowHint(GLFW_VISIBLE, GL_TRUE); // Window initially hidden + if (configFlags & FLAG_WINDOW_RESIZABLE) glfwWindowHint(GLFW_RESIZABLE, GL_TRUE); // Resizable window else glfwWindowHint(GLFW_RESIZABLE, GL_FALSE); // Avoid window being resizable diff --git a/src/raylib.h b/src/raylib.h index 430e66db..9e254f97 100644 --- a/src/raylib.h +++ b/src/raylib.h @@ -410,8 +410,9 @@ typedef enum { FLAG_WINDOW_RESIZABLE = 4, // Set to allow resizable window FLAG_WINDOW_UNDECORATED = 8, // Set to disable window decoration (frame and buttons) FLAG_WINDOW_TRANSPARENT = 16, // Set to allow transparent window - FLAG_MSAA_4X_HINT = 32, // Set to try enabling MSAA 4X - FLAG_VSYNC_HINT = 64 // Set to try enabling V-Sync on GPU + FLAG_WINDOW_HIDDEN = 32, // Set to create the window initially hidden + FLAG_MSAA_4X_HINT = 64, // Set to try enabling MSAA 4X + FLAG_VSYNC_HINT = 128 // Set to try enabling V-Sync on GPU } ConfigFlag; // Trace log type |
