[PyOpenGL-Users] PyOpenGL_accelerate / subclassed numpy arrays
Brought to you by:
mcfletch
From: Nicolas P. R. <Nic...@in...> - 2015-11-06 07:08:52
|
I've made a numpy array subclass for a vertex buffer that works great with PyOpenGL but does not work if PyOpenGL_accelerate is installed, it complains about about missing handler: File "/Users/rougier/Development/Public/glumpy/glumpy/gloo/buffer.py", line 75, in _update gl.glBufferSubData(self.target, offset, nbytes, data) File "latebind.pyx", line 44, in OpenGL_accelerate.latebind.Curry.__call__ (src/latebind.c:1201) File "/usr/locaL/Cellar/python3/3.5.0/Frameworks/Python.framework/Versions/3.5/lib/python3.5/site-packages/OpenGL/GL/VERSION/GL_1_5.py", line 122, in glBufferSubData data = ArrayDatatype.asArray( data ) File "arraydatatype.pyx", line 174, in OpenGL_accelerate.arraydatatype.ArrayDatatype.asArray (src/arraydatatype.c:4221) File "arraydatatype.pyx", line 57, in OpenGL_accelerate.arraydatatype.HandlerRegistry.c_lookup (src/arraydatatype.c:2230) TypeError: No array-type handler for type <class 'glumpy.gloo.buffer.VertexBuffer'> (value: VertexBuffer([151, 10, 1, ..., 0, 128, 63], ) registered Python: 3.5 PyOpenGL: 3.1.0 PyOpenGL_accelerate: 3.1.0 The package I'm developing: http://glumpy.github.io Any idea ? Nicolas |