Friday 30 July 2010

SAMI

We decided to change tack a little bit. So heres our work output for the last week or so. Its a framework for Sonification of images. The idea being that we can now easily write little scripts to do specific tasks, without having to worry about how they interact with each other. We also have quite a few little scripts, that take images and generate different sorts of music etcetc.

In technical terms, all the scripts are written in python, with a special header, and the GUI reads these headers, so it knows what data to give them, and then runs them in an embedded interpreter. Its also clever enough to maintain lists of information about an image (or images), handle different error messages from the scripts, as well as editing and reloading them.

http://www.mediafire.com/file/o5c0aaepfifo1jh/scripts.tar.gz

http://www.mediafire.com/file/92aj2kaia8c88se/Sonify-Framework-30-07-10--16-21.tar.gz

To compile it you'll need:
- Qt4.6 from qt.nokia.com
- python 2.6.5 from http://www.python.org/download/releases/2.6.5/
- numpy and scipy from http://www.scipy.org/Download
- possibly matplotlib from http://matplotlib.sourceforge.net/

Just load the .pro file in qt creator, and it should compile just fine. If you want the scripts directory to be one other than where the executable is, you'll need to create an environment variable PYTHONPATH, whose value is the scripts directory. You may also need to change QMAKE_CXXFLAGS in .pro file, to the values given by running 'import distutils.sysconfig;
distutils.sysconfig.get_config_var('LINKFORSHARED')' in the python interpreter.

If you have installed python in a weird place, you'll need to update the library and include flags etc in the .pro file to the location of the libraries and headers for python.

[I'm working on automating both of the above]

No comments:

Post a Comment