1
0
mirror of https://github.com/blawar/GLideN64.git synced 2024-06-27 23:14:05 +00:00

Code refactor: get rid of Windows macro min and max.

This commit is contained in:
Sergey Lipskiy 2022-02-19 22:00:57 +07:00
parent f4d83cd9bd
commit 7eef2b3684
9 changed files with 12 additions and 21 deletions

View File

@ -8,10 +8,6 @@
#include "PluginAPI.h"
#include "FrameBuffer.h"
#ifdef min
#undef min
#endif
bool DisplayWindow::start()
{
if (!_start())

View File

@ -25,6 +25,9 @@
#define __EXT_TXFILTER_H__
#ifdef OS_WINDOWS
#ifndef NOMINMAX
#define NOMINMAX
#endif
#include <windows.h>
#define TXHMODULE HMODULE
#define DLOPEN(a) LoadLibraryW(a)

View File

@ -2,6 +2,9 @@
#define GLFUNCTIONS_H
#ifdef OS_WINDOWS
#ifndef NOMINMAX
#define NOMINMAX
#endif
#include <windows.h>
//#define FORCE_UNBUFFERED_DRAWER // Debug option.
#elif defined(OS_LINUX)

View File

@ -1,5 +1,4 @@
#include "glsl_CombinerProgramUniformFactoryAccurate.h"
#include <Config.h>
#include <FrameBuffer.h>
#include <Textures.h>
@ -8,10 +7,6 @@
#include <cmath>
#ifdef min
#undef min
#endif
namespace {
using namespace glsl;

View File

@ -8,10 +8,6 @@
#include <cmath>
#ifdef min
#undef min
#endif
namespace {
using namespace glsl;

View File

@ -26,10 +26,6 @@
#include <Graphics/OpenGLContext/GraphicBuffer/GraphicBufferWrapper.h>
#endif
#ifdef min
#undef min
#endif
using namespace opengl;
ContextImpl::ContextImpl()
@ -38,7 +34,6 @@ ContextImpl::ContextImpl()
}
ContextImpl::~ContextImpl()
{
}

View File

@ -2,6 +2,9 @@
#define COMMONPLUGINAPI_H
#ifdef MUPENPLUSAPI
#ifndef NOMINMAX
#define NOMINMAX
#endif
#include "m64p_plugin.h"
#else
#include "windows/GLideN64_windows.h"

View File

@ -1,7 +1,7 @@
#ifndef GLIDEN64_WINDOWS_H
#define GLIDEN64_WINDOWS_H
#include <windows.h>
#include "Platform.h"
extern HWND hWnd;
extern HWND hStatusBar;

View File

@ -1,4 +1,4 @@
#include <Windows.h>
#include "Platform.h"
#include "Config.h"
#include "../GLideNHQ/inc/png.h"
@ -118,6 +118,6 @@ void SaveScreenshot(const wchar_t * _folder, const char * _name, int _width, int
}
if (i == 1000)
return;
write_png_file(fileName, _width, _height, _data);
}