Missing function?

The GLSL spec 1.50 (http://www.opengl.org/registry/doc/GLSLangSpec.1.50.09.pdf) at PDF page 99 / labelled page 93, defined the function

ivec2 textureSize (gsampler2DRect sampler)

According ot the preceeding section, the g is used to mean a prefix of “”, “i” or “u”. In my case the prefix is “” as it’s a float sampler.

However, when I try to use this function in my shader:

uniform sampler2DRect Ytex;
void main(){
  ivec2 wh = textureSize(Ytex);

the shader fails to compile with error C1115: unable to find compatible overloaded function “textureSize(sampler2DRect)”.

What am I doing wrong?

Do you have a #version 150 line at the top of the file?

Sorry for the delay replaying. Yes, I have #version 150 at the top of the shader source.

In case it makes a difference, I’m using the Linux x86 NVidia 190.53 graphics driver on Red Hat Enterprise Linux 4.6.

Looks like a driver bug…

Posted to NVidia linux driver support forum: http://www.nvnews.net/vbulletin/showthread.php?p=2199028#post2199028