aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGarett Bass <garett@recroom.com>2020-06-04 12:26:01 -0700
committerGarett Bass <garett@recroom.com>2020-06-04 12:26:01 -0700
commitcd76dfa183241b1831b81318fcd4aab5f91ead8d (patch)
tree59660081c0f9f43d1fecf4f9d0c52c641d7e9a35
parentd3c41e669de9bc35eadd946c36e87662b022108a (diff)
added more #define NOMINMAX, removed redundant #include <windows.h>
-rw-r--r--sokol_app.h2
-rw-r--r--sokol_audio.h3
-rw-r--r--sokol_fetch.h3
-rw-r--r--sokol_gfx.h4
4 files changed, 11 insertions, 1 deletions
diff --git a/sokol_app.h b/sokol_app.h
index bd060ab9..cf52ba63 100644
--- a/sokol_app.h
+++ b/sokol_app.h
@@ -3263,6 +3263,8 @@ _SOKOL_PRIVATE const _sapp_gl_fbconfig* _sapp_gl_choose_fbconfig(const _sapp_gl_
#if defined(_WIN32)
#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
+#endif
+#ifndef NOMINMAX
#define NOMINMAX
#endif
#include <windows.h>
diff --git a/sokol_audio.h b/sokol_audio.h
index 21907d49..ec6ebe67 100644
--- a/sokol_audio.h
+++ b/sokol_audio.h
@@ -469,6 +469,9 @@ inline void saudio_setup(const saudio_desc& desc) { return saudio_setup(&desc);
#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
#endif
+ #ifndef NOMINMAX
+ #define NOMINMAX
+ #endif
#include <windows.h>
#include <synchapi.h>
#pragma comment (lib, "kernel32.lib")
diff --git a/sokol_fetch.h b/sokol_fetch.h
index 68ca33ed..c416a102 100644
--- a/sokol_fetch.h
+++ b/sokol_fetch.h
@@ -1002,6 +1002,9 @@ inline void sfetch_setup(const sfetch_desc_t& desc) { return sfetch_setup(&desc)
#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
#endif
+ #ifndef NOMINMAX
+ #define NOMINMAX
+ #endif
#include <windows.h>
#define _SFETCH_PLATFORM_WINDOWS (1)
#define _SFETCH_PLATFORM_EMSCRIPTEN (0)
diff --git a/sokol_gfx.h b/sokol_gfx.h
index 2aac9bde..9526ba86 100644
--- a/sokol_gfx.h
+++ b/sokol_gfx.h
@@ -2463,7 +2463,9 @@ inline void sg_init_pass(sg_pass pass_id, const sg_pass_desc& desc) { return sg_
#ifndef WIN32_LEAN_AND_MEAN
#define WIN32_LEAN_AND_MEAN
#endif
- #include <windows.h>
+ #ifndef NOMINMAX
+ #define NOMINMAX
+ #endif
#include <d3d11.h>
#include <d3dcompiler.h>
#if (defined(WINAPI_FAMILY_PARTITION) && !WINAPI_FAMILY_PARTITION(WINAPI_PARTITION_DESKTOP))