nib
03-06-2007, 07:11 AM
When I compile the vertex and fragment program there are no errors. The link succeeds. But then there is this weird comment about validation:
Validation Failed: Sampler error:
Samplers of different types use the same texture image unit.
- or -
A sampler's texture unit is out of range (greater than max allowed or negative).
Yet, I don't think I've done anything wrong (?). Works on ATI Radeon:
uniform sampler2D texunit0; //diffuse texture
uniform sampler2D texunit1; //normal map
uniform sampler2D texunit3; //shine map
uniform sampler2DShadow shadowmap; //shadow map, 5
uniform samplerCube cubemap; //cube map, 7
Huff, first run on an intel mac with a nvidia card. :)
Also, any gotchas compiling on an Nvidia 7300 GT ? Seem to be having a compile issue with glsl shaders. Everything else appears to work fine -- vbos, display lists, accelerate library -- when I turn off the glsl shaders. I kept the number of varying variables below 8, as someone suggested before.
I think the glsl program fails to compile. Then I fail to attach to a program object. Oddly, it starts to draw but takes about one minute to draw a single frame when the shader is on!
Validation Failed: Sampler error:
Samplers of different types use the same texture image unit.
- or -
A sampler's texture unit is out of range (greater than max allowed or negative).
Yet, I don't think I've done anything wrong (?). Works on ATI Radeon:
uniform sampler2D texunit0; //diffuse texture
uniform sampler2D texunit1; //normal map
uniform sampler2D texunit3; //shine map
uniform sampler2DShadow shadowmap; //shadow map, 5
uniform samplerCube cubemap; //cube map, 7
Huff, first run on an intel mac with a nvidia card. :)
Also, any gotchas compiling on an Nvidia 7300 GT ? Seem to be having a compile issue with glsl shaders. Everything else appears to work fine -- vbos, display lists, accelerate library -- when I turn off the glsl shaders. I kept the number of varying variables below 8, as someone suggested before.
I think the glsl program fails to compile. Then I fail to attach to a program object. Oddly, it starts to draw but takes about one minute to draw a single frame when the shader is on!