SWIG for making your C++ apps scriptable


If you’d like to make your apps scriptable through Perl or Python in the manner that MS Office (and most of Windows) is scriptable through VB, you should take a look at SWIG.


There are some good tutorials on line for doing this too, I’ll post some links here when I get a moment to round them all up.


just bring gamemonkey or angelscript into your code, extending objects and exposing them to your script is just a matter of writing a simple proxy class (or calling some functions in angelscript). i’ve made some tests, gamemonkey is more faster than angelscript but its language is more like lua than c or c++… on the other side angelscript is faster to implement (for exposing c/c++ objects and functions to your script) but has a drawback of being slightly slower when running bytecode. anyway both are used in games for maintaining game logic and ai, and both are pretty fast imho. sure you can’t put a script function called in a inner loop of audio processing, but for scripting offline actions they work fine.


take a look!