I keep encountering a Segmentation fault when the GLSL texture3D method is executed in a fragment shader.
Created attachment 9385 [details] Sample application showing shader problem Attached is a sample application showing the problem. The file should be unpacked in the progs directory and then the application can be built.
Looks like you've got a bug in your fragment shader. It's illegal to write to a uniform variable in your shader: uniform vec3 normalNoise; ... normalNoise = texture3D(NoiseTex, noiseTexCoord);\n" I'll add an error check for that in Mesa. Are you using Mesa from git?
Thanks for the quick reqponse. I looked at the code and saw what you are talking about. That was pointed out to me before but I forgot to fix it, sorry about that. None the less, if you remove the declaration from the top of the shader and declare it in the in the code (ie. "vec3 normalNoise = texture3D(NoiseTex, noiseTexCoord);") you get the same results. Again if you comment the line out, the application runs. I have tried it with Release Version 6.5.2 and from the latest in git (as of 28 March 2007). I was going to try it with the glsl-compiler-1 branch but I could not get it to compile. Tim
You've got a number of bugs in your program. For example, the texture sampler binding is incorrect. It's supposed to be the texture unit, not texture object ID. The texcoords are suspect too. In fact, Mesa's rasterizer is crashing because one of the texture coords is extremely large. Another thing: you seem to be mixing OpenGL 2.0 and GL_ARB_shader_objects functions. You should stick with one or the other exclusively. I'll send you a hacked version of your demo that seems to work for me.
Added a check in the compiler to generate warning on assignment to read-only values. Closing. Re-open if there's anything else.
Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.