diff --git a/maszyna.vcxproj.filters b/maszyna.vcxproj.filters
index b3368c08..665a7b90 100644
--- a/maszyna.vcxproj.filters
+++ b/maszyna.vcxproj.filters
@@ -315,9 +315,6 @@
Source Files\imgui
-
- Source Files\imgui
-
Source Files\imgui
@@ -327,6 +324,12 @@
Source Files\application\mode_editor
+
+ Source Files\imgui
+
+
+ Source Files\imgui
+
diff --git a/renderer.cpp b/renderer.cpp
index a85679c0..4821d118 100644
--- a/renderer.cpp
+++ b/renderer.cpp
@@ -3722,8 +3722,8 @@ opengl_renderer::Init_caps() {
+ " Vendor: " + std::string( (char *)glGetString( GL_VENDOR ) )
+ " OpenGL Version: " + oglversion );
- if( !GLEW_VERSION_1_5 ) {
- ErrorLog( "Requires openGL >= 1.5" );
+ if( !GLEW_VERSION_3_0 ) {
+ ErrorLog( "Requires openGL >= 3.0" ); // technically 1.5 for now, but imgui wants more
return false;
}
diff --git a/stdafx.h b/stdafx.h
index 194b7018..145bed1f 100644
--- a/stdafx.h
+++ b/stdafx.h
@@ -106,14 +106,11 @@
#include "openglmatrixstack.h"
// imgui.h comes with its own operator new which gets wrecked by dbg_new, so we temporarily disable the latter
-#ifdef _MSC_VER
-#ifdef _DEBUG
+#ifdef DBG_NEW
+#pragma push_macro("new")
#undef new
-#endif // _DEBUG
-#endif
#include "imgui.h"
-#ifdef _MSC_VER
-#ifdef _DEBUG
-#define new DBG_NEW
-#endif // _DEBUG
+#pragma pop_macro("new")
+#else
+#include "imgui.h"
#endif
diff --git a/uilayer.cpp b/uilayer.cpp
index b7d26251..c5ed4262 100644
--- a/uilayer.cpp
+++ b/uilayer.cpp
@@ -14,7 +14,7 @@ http://mozilla.org/MPL/2.0/.
#include "renderer.h"
#include "imgui_impl_glfw.h"
-#include "imgui_impl_opengl2.h"
+#include "imgui_impl_opengl3.h"
extern "C"
{
@@ -74,7 +74,8 @@ ui_layer::init( GLFWwindow *Window ) {
// m_imguiio->Fonts->AddFontFromFileTTF( "c:/windows/fonts/lucon.ttf", 13.0f );
ImGui_ImplGlfw_InitForOpenGL( m_window, false );
- ImGui_ImplOpenGL2_Init();
+// ImGui_ImplOpenGL3_Init( "#version 140" );
+ ImGui_ImplOpenGL3_Init();
init_colors();
@@ -118,7 +119,7 @@ ui_layer::init_colors() {
void
ui_layer::shutdown() {
- ImGui_ImplOpenGL2_Shutdown();
+ ImGui_ImplOpenGL3_Shutdown();
ImGui_ImplGlfw_Shutdown();
ImGui::DestroyContext();
}
@@ -188,7 +189,7 @@ ui_layer::render() {
::glClientActiveTexture( m_textureunit );
::glBindBuffer( GL_ARRAY_BUFFER, 0 );
- ImGui_ImplOpenGL2_NewFrame();
+ ImGui_ImplOpenGL3_NewFrame();
ImGui_ImplGlfw_NewFrame();
ImGui::NewFrame();
@@ -198,7 +199,7 @@ ui_layer::render() {
render_();
ImGui::Render();
- ImGui_ImplOpenGL2_RenderDrawData( ImGui::GetDrawData() );
+ ImGui_ImplOpenGL3_RenderDrawData( ImGui::GetDrawData() );
::glPopClientAttrib();
}
diff --git a/version.h b/version.h
index 458ffd4c..abe477cd 100644
--- a/version.h
+++ b/version.h
@@ -1,5 +1,5 @@
#pragma once
#define VERSION_MAJOR 18
-#define VERSION_MINOR 911
+#define VERSION_MINOR 918
#define VERSION_REVISION 0