View Full Version : Multitexturing (3) problem with shader recompile.

09-23-2009, 01:56 AM
I had two textures (diffuse map/normal map) with GLSL per-pixel lighting which works fine for a year now. I decided to add additional lightmap texture as a 3rd texture unit which seems to work fine but when i change anything in the shader runtime in GLIntercept and recompile (F7) it breaks on glDrawElements with GL_INVALID_VALUE (index count is 108). Before that, NO error occurs and i can't figure out what the problem is. Can't be multitexturing since 2 textures work fine. Can't be multiple UV sets since i pack two sets into single one (xy, zw). If i remove the third texture2D sampler in the shader everything is back to normal. Any idea what that could be?

<GeForce 8600 GT (latest Omega)>

09-23-2009, 07:34 PM
It would be nice to see the shader as well as it's initialization code.

09-24-2009, 02:56 AM
@Kavara: open a new thread.

@DmitryM: everything is initialized just fine and works if i have 2 sampler2D samplers in the shader. im beginning to think it's not something im doing wrong. it only outputs error if i recompile the shader with GLIntercept and the produced string and error value make absolutely no sense. anyways, will continue digging, post the solution once i figure it out.

09-24-2009, 05:05 AM
IIRC When I was using GLIntercept I would get some odd errors when adding uniforms. It was nothing todo with the actual shader, just some issue with GLIntercept.


09-24-2009, 05:12 AM
Thanks, i begin to think myself its GLIntercept. would like to know more on that, who discovered weird behavior and the results.