Ported glsl to version 110 (GL 2.0)
This commit is contained in:
parent
9e9c000dfd
commit
440972ddfa
|
@ -193,13 +193,13 @@ void ImGui_ImplSdl_CreateFontsTexture()
|
|||
bool ImGui_ImplSdl_CreateDeviceObjects()
|
||||
{
|
||||
const GLchar *vertex_shader =
|
||||
"#version 130\n"
|
||||
"#version 110\n"
|
||||
"uniform mat4 ProjMtx;\n"
|
||||
"in vec2 Position;\n"
|
||||
"in vec2 UV;\n"
|
||||
"in vec4 Color;\n"
|
||||
"out vec2 Frag_UV;\n"
|
||||
"out vec4 Frag_Color;\n"
|
||||
"attribute vec2 Position;\n"
|
||||
"attribute vec2 UV;\n"
|
||||
"attribute vec4 Color;\n"
|
||||
"varying vec2 Frag_UV;\n"
|
||||
"varying vec4 Frag_Color;\n"
|
||||
"void main()\n"
|
||||
"{\n"
|
||||
" Frag_UV = UV;\n"
|
||||
|
@ -208,14 +208,13 @@ bool ImGui_ImplSdl_CreateDeviceObjects()
|
|||
"}\n";
|
||||
|
||||
const GLchar* fragment_shader =
|
||||
"#version 130\n"
|
||||
"#version 110\n"
|
||||
"uniform sampler2D Texture;\n"
|
||||
"in vec2 Frag_UV;\n"
|
||||
"in vec4 Frag_Color;\n"
|
||||
"out vec4 Out_Color;\n"
|
||||
"varying vec2 Frag_UV;\n"
|
||||
"varying vec4 Frag_Color;\n"
|
||||
"void main()\n"
|
||||
"{\n"
|
||||
" Out_Color = Frag_Color * texture( Texture, Frag_UV.st);\n"
|
||||
" gl_FragColor = Frag_Color * texture2D(Texture, Frag_UV.st);\n"
|
||||
"}\n";
|
||||
|
||||
g_ShaderHandle = gl.CreateProgram();
|
||||
|
|
Loading…
Reference in New Issue