GlslWriter: Handle OpenGL ES precision qualifier
This commit is contained in:
@@ -98,6 +98,16 @@ namespace Nz
|
||||
AppendLine();
|
||||
}
|
||||
|
||||
if (m_environment.glES)
|
||||
{
|
||||
AppendLine("#if GL_FRAGMENT_PRECISION_HIGH");
|
||||
AppendLine("precision highp float;");
|
||||
AppendLine("#else");
|
||||
AppendLine("precision mediump float;");
|
||||
AppendLine("#endif");
|
||||
AppendLine();
|
||||
}
|
||||
|
||||
// Global variables (uniforms, input and outputs)
|
||||
const char* inKeyword = (glslVersion >= 130) ? "in" : "varying";
|
||||
const char* outKeyword = (glslVersion >= 130) ? "out" : "varying";
|
||||
|
||||
Reference in New Issue
Block a user