|Python scripting engine|
|Categories:||All Plugins, Stable Plugins, ScriptEngine Plugins|
The Python scripting engine fully integrates the popular Python scripting language into K-3D. Python (http://www.python.org) is already used extensively in the scientific and graphics communities (among many others), combining a powerful multi-paradigm language with an expansive collection of runtime libraries. A comprehensive object model exposes all K-3D features for complete, detailed control by scripts written in Python.
Because K-3D supports multiple scripting languages, programs written in Python must begin with the literal #python at position zero within the program sources, so K-3D can identify them for playback by the correct script engine.
K-3D's object model is packaged for use within scripts as a Python module named k3d. Most K-3D Python scripts will import the k3d module near the beginning of a script for later access to K-3D's features:
#python import k3d k3d.ui().message("howdy, world!")
For a discussion of the many ways in which you can use scripting in K-3D, see Scripting. The K-3D Python object model documentation is generated automatically from the sources and located at http://www.k-3d.org/docs/epydoc
There are many sample scripts written in Python located in the k3d/share/scripts directory and its subdirectories. In addition most of the regression test scripts located in the k3d/tests directory are written in Python.
A comprehensive Python documentation :
A good resource for 3D programming in python
Some useful python modules :