将图像转换为声波
pumila的Python项目详细描述
普米拉是一个图像到声音转换器。它能改变颜色的变化, 亮度,饱和度和不透明度成不同的声音。
许可证
Pumila是GNU Affero通用条款下的自由软件 许可证版本3(或任何更高版本)。这是程序的0.1.0版。
联系人
普米拉的作者是尼尔斯·塞鲁普。应发送错误报告和建议 暂时到ns@metanohi.name。
安装
方式1
获取Pumila的最新版本 http://metanohi.name/projects/pumila/或 http://pypi.python.org/pypi/pumila
从下载的文件中提取pumila,cd到其中并在 终端:
# python3 setup.py install
示例可在examples目录中找到。
方式2
运行这个:
# pip-3.1 install pumila
请注意,这不会提供任何示例。
依赖关系
Python3.1+
- 对于基于deb的发行版(trisquel、debian等):运行apt-get install python3
- 对于基于RPM的发行版:运行yum install python3
- 对于其他发行版:执行类似的操作或访问 http://python.org/download/
皮加梅
在正常情况下,您可以这样做:
- 对于基于deb的发行版:运行apt-get install python-pygame
- 对于基于RPM的发行版:运行yum install pygame
- 对于其他发行版:执行类似的操作或访问 http://pygame.org/download.shtml
然而,PyGame1.9.1版本与Python3并不完美,Python3 意味着您必须自己从svn编译pygame,请参见 http://pygame.org/wiki/Compilation
cython
最好从http://cython.org/-pumila works获得最新版本 使用v0.15,但早期版本的测试并不多。
可选,但推荐模块
进度条
- 网址:http://code.google.com/p/python-progressbar/
- 安装:运行easy_install3 progressbar。
设置程序标题
- 网址:http://code.google.com/p/py-setproctitle/
- 安装:运行easy_install3 setproctitle。
文档
什么影响什么:
bottom <-- frequency --> top bright <-- amplitude --> dark no saturation <-- amplitude --> full saturation transparent <-- amplitude --> opaque
波形类型:
hue 0 to 90, red to ······ chartreuse: sine to triangle hue 90 to 180, chartreuse to cyan: triangle to square hue 180 to 270, cyan to ····· purple: square to sawtooth hue 270 to 360 (0), purple to ··· red: sawtooth to sine
使用
作为命令行工具
运行pumila来使用它。运行pumila --help查看如何使用它。
作为模块
要了解如何使用它,请运行:
$ pydoc3 pumila
而且:
$ pydoc3 pumila.core $ pydoc3 pumila.primitives
等等。
示例
在examples目录中有几个示例。所有示例图像都是 在Creative Commons Zero 1.0许可下提供。
开发
pumila使用git进行代码管理。最新(有时不稳定)的代码 网址:
$ git clone git://gitorious.org/pumila/pumila.git
本文档
版权所有(c)2011 Niels Serup
复制和分发此文件,无论是否修改,都是 允许在任何媒体上使用,无需版权声明 通知保留。此文件按原样提供,不作任何保证。