Hi,
I'm making a flight simulator type thing, and I want the planes to have shadows. I tried to reverse engineer NeHe 27, but only the .exe ran, and I couldn't get the program to work otherwise. I program in Python, so any code in Python is more useful. What would be great is a Python version of something like NeHe 27 or at least the key function calls. Thanks,
G
NeHe's 27 lesson - Shadow Volumes - it's old approach, they are quite useless, try Shadow Mapping (very good technique, it's very useful, but it has few disadvantages).
I'm working from:
http://www.cs.ualberta.ca/~ghali/courses/texts/redbook/html/09-10-shadowmap.c.html
which I translated into Python, but the glDrawPixels() call is really really slow. Why?
G
http://www.cs.ualberta.ca/~ghali/courses/texts/redbook/html/09-10-shadowmap.c.html
which I translated into Python, but the glDrawPixels() call is really really slow. Why?
G
I think I'm onto something with this other tutorial:
http://www.paulsprojects.net/tutorials/smt/smt.html
I've translated it from the C++ it's in to Python. I think that these lines don't work:I see the torus and the spheres, but no shadow. I commented them out because I can't get the extensions. How would one do it without the extensions?
http://www.paulsprojects.net/tutorials/smt/smt.html
I've translated it from the C++ it's in to Python. I think that these lines don't work:
glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_COMPARE_MODE_ARB, GL_COMPARE_R_TO_TEXTURE)glTexParameteri(GL_TEXTURE_2D, GL_TEXTURE_COMPARE_FUNC_ARB, GL_LEQUAL)glTexParameteri(GL_TEXTURE_2D, GL_DEPTH_TEXTURE_MODE_ARB, GL_INTENSITY)
Try setting up shaders. Because the methods using fixed function pipeline is both confusing and slow because you draw the scene 3 times. If you do a shader, it will only require 1 draw.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement