PDA

View Full Version : Mesa3D GLSL supports 1.20??



Jason Tiller
05-11-2011, 04:37 PM
Hi, All, :)

Mesa claims that it supports GLSL 1.20 from 7.3 on up. I'm currently using 7.10.1 from Kubuntu 11.04 on x86_64, and I get an error when trying to provide an initial value to a uniform variable. The compiler complains that:

0:7(25): error: cannot initialize uniforms in GLSL 1.10

I'm using Intel i5 embedded graphics (i915 kernel driver).

I'm really struggling to make GLSL work under Linux. Aargh! But thanks in advance for any help you can provide,

---Jason

V-man
05-11-2011, 07:08 PM
http://www.opengl.org/wiki/GLSL_:_recommendations#Version_Number

Also, what about glGetString(GL_SHADING_LANGUAGE_VERSION)?

Jason Tiller
05-11-2011, 10:39 PM
Hey, V-Man! Thanks!

glGetString( GL_SHADING_LANGUAGE_VERSION )

returns 1.20, which is good.

Interestingly, when I placed

#version 120

at the top of my vertex shader, the compile error goes away. Huh? I don't understand - is the default to only support 1.10 unless it sees the #version?

Thanks! Learn something every day!

---Jaon

Alfonse Reinheart
05-11-2011, 10:45 PM
is the default to only support 1.10 unless it sees the #version?

Yes, it is.