summarylogtreecommitdiffstats
path: root/mangohud-opengl2.patch
blob: a2bf93eec0e281a9520a5c81f44d1d7d1ee4c87e (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
diff --git a/src/gl/imgui_impl_opengl3.cpp b/src/gl/imgui_impl_opengl3.cpp
index 2103773..28f24a7 100644
--- a/src/gl/imgui_impl_opengl3.cpp
+++ b/src/gl/imgui_impl_opengl3.cpp
@@ -184,7 +184,7 @@ static bool    ImGui_ImplOpenGL3_CreateDeviceObjects()
         glGetIntegerv(GL_VERTEX_ARRAY_BINDING, &last_vertex_array);
 
     // Parse GLSL version string
-    int glsl_version = 130;
+    int glsl_version = 120;
     sscanf(g_GlslVersionString, "#version %d", &glsl_version);
 
     const GLchar* vertex_shader_glsl_120 =
@@ -422,7 +422,7 @@ bool    ImGui_ImplOpenGL3_Init(const char* glsl_version)
 
     if (!g_IsGLES) {
         // Not GL ES
-        glsl_version = "#version 130";
+        glsl_version = "#version 120";
         g_GlVersion = major * 100 + minor * 10;
         if (major >= 4 && minor >= 1)
             glsl_version = "#version 410";
@@ -456,7 +456,7 @@ bool    ImGui_ImplOpenGL3_Init(const char* glsl_version)
     // Store GLSL version string so we can refer to it later in case we recreate shaders.
     // Note: GLSL version is NOT the same as GL version. Leave this to NULL if unsure.
     if (glsl_version == NULL)
-        glsl_version = "#version 130";
+        glsl_version = "#version 120";
 
     IM_ASSERT((int)strlen(glsl_version) + 2 < IM_ARRAYSIZE(g_GlslVersionString));
     strcpy(g_GlslVersionString, glsl_version);