pyopengl and pypy

rndblnch <[email protected]> Sat, 27 Nov 2010 00:54:28 +0000 (UTC)
Newsgroups gmane.comp.python.opengl.devel
Message-ID <[email protected]>
hello,

i'm trying to make my pyopengl(3.0.1)-based code run with pypy (1.4).
i ran into some issues:
1) the use of ctypes.pythonapi (for PyString_AsString in arrays/strings.py and
PyBuffer_FromMemory in arrays/vbo.py)
2) an "AttributeError: type object 'ArrayDatatype' has no attribute
'_CData_input'", trackback:
...
  File "/Users/Shared/src/pypy-1.4-osx/site-packages/OpenGL/latebind.py", line
45, in __call__
    return self._finalCall( *args, **named )
  File "/Users/Shared/src/pypy-1.4-osx/site-packages/OpenGL/wrapper.py", line
784, in wrapperCall
    result = self.wrappedOperation( *cArguments )
  File
"/Users/Shared/src/pypy-1.4-osx/site-packages/OpenGL/platform/baseplatform.py",
line 335, in __call__
    return self( *args, **named )
  File "/Users/Shared/src/pypy-1.4-osx/lib_pypy/_ctypes/function.py", line 166,
in __call__
    argtypes, argsandobjs = self._wrap_args(argtypes, args)
  File "/Users/Shared/src/pypy-1.4-osx/lib_pypy/_ctypes/function.py", line 281,
in _wrap_args
    wrapped = argtype._CData_input(arg)
AttributeError: type object 'ArrayDatatype' has no attribute '_CData_input'

i guess that for 1) it should be possible to write pure ctypes/python
replacements for the needed functions (any hints welcome :)
for 2) i didn't manage to understand enough the relationship between pyopengl
and ctypes to get any clue about what's going on.

anybody with some experience with/interested by such issues?

thanks for your help,

renaud



------------------------------------------------------------------------------
Increase Visibility of Your 3D Game App & Earn a Chance To Win $500!
Tap into the largest installed PC base & get more eyes on your game by
optimizing for Intel(R) Graphics Technology. Get started today with the
Intel(R) Software Partner Program. Five $500 cash prizes are up for grabs.
http://p.sf.net/sfu/intelisp-dev2dev
_______________________________________________
PyOpenGL Homepage
http://pyopengl.sourceforge.net