]> git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - shader_glsl.h
in glsl130, add "precision mediump float"
[xonotic/darkplaces.git] / shader_glsl.h
index 44d84da3fc67e89e7cbcffe93189f09921c0df95..f5fc5510452f876e904b37f09b9925595211babd 100644 (file)
@@ -2,14 +2,17 @@
 "// written by Forest 'LordHavoc' Hale\n"
 "// shadowmapping enhancements by Lee 'eihrul' Salzman\n"
 "\n"
-"// GL ES shaders use precision modifiers, standard GL does not\n"
+"// GL ES and GLSL130 shaders use precision modifiers, standard GL does not\n"
 "#ifndef GL_ES\n"
+"#ifndef GLSL130\n"
 "#define lowp\n"
 "#define mediump\n"
 "#define highp\n"
 "#endif\n"
+"#endif\n"
 "\n"
 "#ifdef GLSL130\n"
+"precision mediump float;\n"
 "# ifdef VERTEX_SHADER\n"
 "#  define dp_varying out\n"
 "#  define dp_attribute in\n"