use #version 120 on desktop GL
This commit is contained in:
parent
fbbb3cba5c
commit
735d032bdd
|
@ -213,10 +213,10 @@ static struct ShaderProgram *gfx_opengl_create_and_load_new_shader(uint32_t shad
|
|||
size_t num_floats = 4;
|
||||
|
||||
// Vertex shader
|
||||
#ifdef OSX_BUILD
|
||||
append_line(vs_buf, &vs_len, "");
|
||||
#else
|
||||
#ifdef USE_GLES
|
||||
append_line(vs_buf, &vs_len, "#version 100");
|
||||
#else
|
||||
append_line(vs_buf, &vs_len, "#version 120");
|
||||
#endif
|
||||
append_line(vs_buf, &vs_len, "attribute vec4 aVtxPos;");
|
||||
if (used_textures[0] || used_textures[1]) {
|
||||
|
@ -248,11 +248,11 @@ static struct ShaderProgram *gfx_opengl_create_and_load_new_shader(uint32_t shad
|
|||
append_line(vs_buf, &vs_len, "}");
|
||||
|
||||
// Fragment shader
|
||||
#ifdef OSX_BUILD
|
||||
append_line(fs_buf, &fs_len, "");
|
||||
#else
|
||||
#ifdef USE_GLES
|
||||
append_line(fs_buf, &fs_len, "#version 100");
|
||||
append_line(fs_buf, &fs_len, "precision mediump float;");
|
||||
#else
|
||||
append_line(fs_buf, &fs_len, "#version 120");
|
||||
#endif
|
||||
|
||||
if (used_textures[0] || used_textures[1]) {
|
||||
|
|
Loading…
Reference in New Issue