Improves OpenGL-ES support (especially for Raspberry Pi), contribution of Erkki Nokso-Koivisto, fetches the GLSL version correctly when using ES2

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@10301 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
3.0
jul..om 12 years ago
parent 1112b380d2
commit 36e6eb7fdc
  1. 6
      engine/src/jogl/com/jme3/renderer/jogl/JoglRenderer.java

@ -188,8 +188,14 @@ public class JoglRenderer implements Renderer {
versionStr = versionStr.substring(0, spaceIdx);
}
//FIXME revisit this fix later
try {
float version = Float.parseFloat(versionStr);
glslVer = (int) (version * 100);
} catch (NumberFormatException e) {
logger.warning("Failed parsing GLSL version assuming it's v1.00");
glslVer = 100;
}
switch (glslVer) {
default:

Loading…
Cancel
Save