[Bf-python] ctypes libblender

HartsAntler goatman.py at gmail.com
Mon Nov 28 03:51:53 CET 2011


Hi Ideasman,

I could use some help and/or tips how to get the example below working.  I
rewrote the critical parts of creator.c and wm.c in python using ctypes to
load bpy.so.  Im trying to get a window to open, and control the main loop,
but i hit some segfaults along the way.

http://pastebin.com/bwx3JkHf

The generated ctypes bindings include over 9,000 functions, the wrapper is
in the download under ./libblender/__init__.py
http://rpythonic.googlecode.com/files/libblender-nov-2011-linux32bits.tar.bz2

The example should also work on Windows if bpy.dll was compiled with MinGW,
but i haven't tested that.  Copy bpy.dll to
./libblender/win32/libblender.dll

Thanks,
-brett
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.blender.org/pipermail/bf-python/attachments/20111128/3bf6e5eb/attachment.html>


More information about the Bf-python mailing list