diff --git a/libobs-opengl/gl-subsystem.c b/libobs-opengl/gl-subsystem.c index db2deac99..4c33991bb 100644 --- a/libobs-opengl/gl-subsystem.c +++ b/libobs-opengl/gl-subsystem.c @@ -20,8 +20,12 @@ #include "gl-subsystem.h" /* Goofy Windows.h macros need to be removed */ -#undef far +#ifdef near #undef near +#endif +#ifdef far +#undef far +#endif /* #define SHOW_ALL_GL_MESSAGES */ diff --git a/libobs/graphics/graphics.c b/libobs/graphics/graphics.c index 4f3ee8905..19a23439b 100644 --- a/libobs/graphics/graphics.c +++ b/libobs/graphics/graphics.c @@ -28,8 +28,10 @@ #include "effect-parser.h" #include "effect.h" -#ifdef _MSC_VER +#ifdef near #undef near +#endif +#ifdef far #undef far #endif