I’ve been looking into atmospheric scattering, and running the code found here (second project down - Atmosphere), and exactly every other time I run the program, the driver crashes and the notification bubble with “display driver has stopped responding and has successfully recovered” pops up.
I tracked it down once to a specific statement in the glsl, and changing it to some equivalent code, and that worked for a while. But now the problem has returned, and also happens in my own adapted version of the code. Has anyone else with an ATI card tried to run this demo and experienced crashes?
I’m using Windows 7 64 bit, with an HD5770.
I also have Windows 7 64bit with a HD 5770 but, I can’t compile the source because I don’t have the tiffio.h file. So, if you could show me where to download it I’ll do so and test the code out.
Thanks. You need to have libtiff, and glew as well.
I’m trying to get it working but I don’t know how to compile it so I found a .lib download of it and now I’m getting some other errors… Why can’t the developers just provide the lib and dll?
Yeah. libtiff is an especial PITA to compile. It’s only used in the demo for loading the earth texture though, so you could just comment out the loadTiff function, and where it’s called (loadData), and pass 0 to glTexImage instead.
Ok, it compiles now but when I run it I get:
“The application was unable to start correctly(0xc000007b). Click OK to close the application.”…
EDIT: Well I fixed that problem but now I’m getting a bunch shader compile error which hopefully I can sort out…
Hmm. Did you put the glut dll in the exe directory? (forgot to mention glut earlier).
Edit: Ah cool.
I had to put an #ifdef FRAGMENT in common.glsl around the functions, IIRC.
I tried that and now I’m getting some other stupid errors:
“Assigning non-constant to = const highp 3-component vector of float”
Getting that error for every shader…
Hmm. I don’t remember that happening for me.
Just another data point – On Ubuntu it compiles and runs fine (NVIDIA 9600GT card though) with only one addition to the Main.cpp file; #include <cstring>. The compile command is
g++ Main.cpp -lglut -lGLEW -ltiff
ps libraries glut, glew, tiff easily installed with synaptic GUI.
I have a try with the project. There is no crash but the compiler threw out the error message - “Undeclared identifier gl_FragCoord.”. I also can’t find the message mentioned by heyufool1 - “Assigning non-constant to = const highp 3-component vector of float”.
After looking at the shaders, it seems the common.glsl is used by both vertex shader and fragment shader, and gl_FragCoord is used in common.glsl. According to the spec, accessing gl_FragCoord in the vertex shader is illegal. I think it’s helpful that you move the fragment shader method out of the vertex shader anyway.
Thanks marshats. Interesting to know it works on NVidia cards.
Frank: Yeah. Putting #ifdef FRAGMENT in common.glsl around the functions should solve that. The NVidia compiler is more lenient I guess.
Once that change is in, the program should work, and that’s when I get the driver crash.
This topic was automatically closed 183 days after the last reply. New replies are no longer allowed.