OpenGL ES: Fix GLSL version number for 1.00 (#5582)

Wikipedia had it wrong: the spec for the OpenGL ES Shading Language Version 1.00 defines the version preprocessor directive as "#version 100", and _not_ "#version 100 es", like version 3.00+ of the language wants it.

This made the Raspberry Pi with the legacy driver unhappy. Thanks @DangusTaargus for reporting.

see https://www.khronos.org/files/opengles_shading_language.pdf
This commit is contained in:
gohai
2018-07-20 11:41:47 -07:00
parent 38ab1e3f66
commit 4d15acae44

View File

@@ -513,7 +513,8 @@ public class PJOGL extends PGL {
@Override
protected String getGLSLVersionSuffix() {
if (context.isGLESProfile()) {
VersionNumber vn = context.getGLSLVersionNumber();
if (context.isGLESProfile() && 1 < vn.getMajor()) {
return " es";
} else {
return "";