commit 331fa1e

chld  ·  2026-07-30 16:35:45 +0000 UTC
parent 9f15095
lower major gl version to 3.3
2 files changed,  +3, -3
+1, -1
1@@ -20,7 +20,7 @@ void platform_init(MGContext* ctx)
2 
3 #ifdef MG_RENDERER_SOKOL
4 	/* TODO: OpenGL specifis */
5-	SDL_GL_SetAttribute(SDL_GL_CONTEXT_MAJOR_VERSION, 4);
6+	SDL_GL_SetAttribute(SDL_GL_CONTEXT_MAJOR_VERSION, 3);
7 	SDL_GL_SetAttribute(SDL_GL_CONTEXT_MINOR_VERSION, 1);
8 	SDL_GL_SetAttribute(SDL_GL_CONTEXT_PROFILE_MASK, SDL_GL_CONTEXT_PROFILE_CORE);
9 	SDL_GL_SetAttribute(SDL_GL_DOUBLEBUFFER, 1);
+2, -2
 1@@ -48,7 +48,7 @@ static void sokol_log(const char* tag, u32 level, u32 item, const char* msg, u32
 2 static RendererState ren;
 3 /* TODO: textures */
 4 static const char* vsdr =
 5-    "#version 410\n"
 6+    "#version 330\n"
 7     "layout(location=0) in vec3 position;\n"
 8     "layout(location=1) in vec2 texcoord0;\n"
 9     "layout(location=2) in vec4 color0;\n"
10@@ -65,7 +65,7 @@ static const char* vsdr =
11     "    colour = color0;\n"
12     "}\n";
13 static const char* fsdr =
14-    "#version 410\n"
15+    "#version 330\n"
16     "in vec2 uv;\n"
17     "in vec4 colour;\n"
18     "\n"