Reputation: 1153
I want to create a small application using Python 3.3 and ctypes, in which the graphics and some other low level operations are done in a C shared library. I have some SDL2 code to create a simple window that works fine when run as a standalone executable, but not when called via ctypes as a shared library.
SDL doesn't produce any errors when called via ctypes, but the window is simply never displayed. I have to imagine this has something to do with threads or spawning processes, but searching hasn't netted me any results.
Upvotes: 0
Views: 629
Reputation: 11
Your ctypes bindings might be wrong. Did you make sure that they correctly wrap the required functions of yours?
http://bitbucket.org/marcusva/py-sdl2 seems to contain ctypes-wrappers for SDL2, which you might use as reference for your own code.
Upvotes: 1