From e4a86e26c6a63794bda4d6423458ab36829c8014 Mon Sep 17 00:00:00 2001 From: assiduous Date: Mon, 24 Feb 2020 12:10:45 -0800 Subject: Fixed Linux build issues --- Graphics/GraphicsEngineOpenGL/include/pch.h | 1 + Graphics/GraphicsEngineOpenGL/src/GLContextLinux.cpp | 7 +++---- 2 files changed, 4 insertions(+), 4 deletions(-) (limited to 'Graphics/GraphicsEngineOpenGL') diff --git a/Graphics/GraphicsEngineOpenGL/include/pch.h b/Graphics/GraphicsEngineOpenGL/include/pch.h index 384b1ae5..739cfa4c 100644 --- a/Graphics/GraphicsEngineOpenGL/include/pch.h +++ b/Graphics/GraphicsEngineOpenGL/include/pch.h @@ -62,6 +62,7 @@ # endif # include "GL/glew.h" +# include "GL/glxew.h" # include // Undefine beautiful defines from GL/glx.h -> X11/Xlib.h diff --git a/Graphics/GraphicsEngineOpenGL/src/GLContextLinux.cpp b/Graphics/GraphicsEngineOpenGL/src/GLContextLinux.cpp index dac8af2d..6abc2822 100644 --- a/Graphics/GraphicsEngineOpenGL/src/GLContextLinux.cpp +++ b/Graphics/GraphicsEngineOpenGL/src/GLContextLinux.cpp @@ -159,15 +159,14 @@ void GLContext::SwapBuffers(int SwapInterval) { if (m_WindowId != 0 && m_pDisplay != nullptr) { + auto wnd = static_cast(m_WindowId); + auto display = reinterpret_cast(m_pDisplay); #if GLX_EXT_swap_control if (glXSwapIntervalEXT != nullptr) { - glXSwapIntervalEXT(SwapInterval); + glXSwapIntervalEXT(display, wnd, SwapInterval); } #endif - - auto wnd = static_cast(m_WindowId); - auto display = reinterpret_cast(m_pDisplay); glXSwapBuffers(display, wnd); } else -- cgit v1.2.3