PyCarrara, a free Python scripting plugin for Carrara
© 2010 Frederic Rible

Origin of the project:

One year ago, I discovered Animusic (http://www.animusic.com/) and started to think that procedural animation may be a solution to compensate my poor skills for hand made character motions: with a software engineer background, I am more comfortable with  mathematics and source code than with keyframes, curves and other CG tools !

My first try with MIDI driven animation has been done under Houdini with the help of the excellent ebook “Simultaneous Music, Animation and Sound Techniques with Houdini” by Andrew Lowell: my Houdini animation “Thermal Pipe Organ” can be found on Youtube. Rapidly I began to think about a Python scripting solution to do the same thing under any other CG application.

Python is a general purpose scripting language already available in many CG applications. But its usage does not limit to CG: many applications such as music production, dynamic web pages, scientific software use it. Lots of Python software libraries are available: MIDI file parser is one example.

Carrara embedded Python scripting can open many new opportunities for automatic complex animation and procedural scene construction. Python scripting can be seen as tool which can automate almost anything that can be done by hand with the GUI: objects, lights or shader parameters modification, geometry construction, objects replication, etc … This technique is very powerful for repeated operations that can be described with mathematic formulas and software algorithms. For example, it is possible to parse a MIDI file and move the piano keys according to notes. Another possible usage is the automatic creation of 3D models of building at positions read from a geographical map file.