A question about MatDefs

In a MatDef one can see such lines:



[java] Technique {

VertexShader GLSL100: Shaders/MovingTexture/MovingTexture.vert

FragmentShader GLSL100: Shaders/MovingTexture/MovingTexture.frag[/java]



The “GLSL100” denotes the version of GLSL right? So my questions are:


  1. Why is it usually 100, when other versions are available?
  2. What does the version influence? As far as I understand it is just that the higher the version, the richer is the instruction set? Is that the only difference?
  3. Where can I read about that?

That’s the GLSL instruction set version to be used by the video drivers.



Basically, the higher the version number, the more modern the hardware has to be. Last I checked (and if my memory serves) the latest version is 140.



So by trying to use 100 (version 1.0) jME tries to stick to the lowest hardware possible. Note that for some effect it’s mandatory to use higher version number. So in that case, if you have for example, a driver that only supports 100 that particular shader wouldn’t run on that video card either because the hardware doesn’t support it or the drivers do not.



There’s most likely info about the version scheme on opengl.org. That’s where I’d look first for more info.

2 Likes