[Bf-python] comments on writing an exporter

Michel Selten michel.s at home.nl
Sat May 31 21:54:25 CEST 2003


On Thu, 2003-05-29 at 20:38, Willian Padovani Germano wrote:
> On Thu, 2003-05-29 at 04:27, Peter Amstutz wrote:
> > Incidentally, is there a particular reason why Blender does not use a 
> > tool like SWIG (http://www.swig.org/) ?  I have used it to bring a
> > sophisticated C++ library into Perl and amount of labor it saves is
> > absolutely incredible.
> 
> Initially Michel tried that, but from what he told me, the old Blender
> kernel isn't nice enough for these new approaches ...

Yes, I tried using SWIG. I thought it would be of great help.
Unfortunately some functions in the 2.25 api are rather difficult (or
should I say almost impossible) to implement using SWIG. For example,
the Blender.Get function can return an integer, float or a string
depending on the argument you pass to it. If you check the history of
the BPY_interface.c file in source/blender/python, you'll see when I
stopped using SWIG:
http://projects.blender.org/viewcvs/viewcvs.cgi/blender/source/blender/python/BPY_interface.c?cvsroot=bf-blender

With regards,
	Michel





More information about the Bf-python mailing list