On Tue, Sep 28, 2010 at 3:05 PM, Devon Scott-Tunkin
<devon.scotttunkin@xxxxxxxxx> wrote:
It should be noted that display lists are deprecated (but for all intents and purposes still there) in the anti-fixed function opengl 3.1+ (and perhaps completely unavailable in open gl es 2.0?). So learning vbos is probably a good idea...
So, dumb question.... are VBOs actually implemented in PyOpenGL? I've started looking into it, and I can't find any working examples of anyone using a VBO in python. (I've found one that looks okay, but it must be for a previous version, because the function signatures don't even match up for me.) I've tried to translate examples from C with no luck. As far as I can tell, here's how you would set one up (vlist is a numpy array):
gl_buffer = glGenBuffers(1)
glBindBuffer(GL_ARRAY_BUFFER_ARB, gl_buffer)
glBufferData(GL_ARRAY_BUFFER_ARB, vlist, GL_STATIC_DRAW)
glVertexPointerd(0)
The last line gives me an error:
TypeError: ('cannot be converted to pointer', <bound method PointerType.voidDataPointer of <class 'OpenGL.arrays.arraydatatype.GLdoubleArray'>>)
So... yeah. Any working examples?
Thanks,
Christopher