Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Define NOMINMAX before windows.h #100

Closed
AlexMax opened this issue Jul 23, 2017 · 1 comment
Closed

Define NOMINMAX before windows.h #100

AlexMax opened this issue Jul 23, 2017 · 1 comment

Comments

@AlexMax
Copy link

AlexMax commented Jul 23, 2017

I ran into an issue where GLAD included windows.h. I've read #42, and I understand why you thought it was a good idea to keep it, but one thing that would help a whole bunch is defining NOMINMAX before including windows.h. This specifically is a major pain-point when including windows.h, as the min and max macros conflict with std::min and std::max, which seems like behavior you would want to avoid in most cases. Those who needed Microsoft's min/max could simply include windows.h before GLAD.

For what it's worth, SDL_opengl.h appears to do exactly what I describe.

@Dav1dde
Copy link
Owner

Dav1dde commented Jul 24, 2017

I will look into it tonight, seems like I missed that change as it was proposed in #42. Thanks for bringing that up again.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants