From d110a371bb8c6f6416f82eabb8a5b54308291abb Mon Sep 17 00:00:00 2001 From: ReinUsesLisp Date: Sat, 18 Jan 2020 19:09:48 -0300 Subject: gl_state: Use bool instead of GLboolean This fixes template resolution considering GLboolean an integer instead of a bool. --- src/video_core/renderer_opengl/gl_rasterizer.cpp | 2 +- src/video_core/renderer_opengl/gl_state.h | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/video_core/renderer_opengl/gl_rasterizer.cpp b/src/video_core/renderer_opengl/gl_rasterizer.cpp index 926bccd42..c428f06e4 100644 --- a/src/video_core/renderer_opengl/gl_rasterizer.cpp +++ b/src/video_core/renderer_opengl/gl_rasterizer.cpp @@ -1272,7 +1272,7 @@ void RasterizerOpenGL::SyncPointState() { const auto& regs = system.GPU().Maxwell3D().regs; // Limit the point size to 1 since nouveau sometimes sets a point size of 0 (and that's invalid // in OpenGL). - state.point.program_control = regs.vp_point_size.enable ? GL_TRUE : GL_FALSE; + state.point.program_control = regs.vp_point_size.enable != 0; state.point.size = std::max(1.0f, regs.point_size); } diff --git a/src/video_core/renderer_opengl/gl_state.h b/src/video_core/renderer_opengl/gl_state.h index 71d418776..678e5cd89 100644 --- a/src/video_core/renderer_opengl/gl_state.h +++ b/src/video_core/renderer_opengl/gl_state.h @@ -131,8 +131,8 @@ public: std::array viewports; struct { - GLboolean program_control = GL_FALSE; // GL_PROGRAM_POINT_SIZE - GLfloat size = 1.0f; // GL_POINT_SIZE + bool program_control = false; // GL_PROGRAM_POINT_SIZE + GLfloat size = 1.0f; // GL_POINT_SIZE } point; struct { -- cgit v1.2.3