Re: [linux-audio-dev]Using python for small multimedia app ?
RTaylor wrote: On 2004-06-03 14:54:56 + Cournapeau David <[EMAIL PROTECTED]> wrote: I am discovering python, having looked for a matlab-like environement. I am wondering now if it is possible to do some small multimedia applications with it; more precisely, I would like to develop a scientific application for audio/video analysis. Basically, I need to show an avi video with a synchronised waveform view of the sound, and some other features views, like the pitch of the film voices (the actual pitch detection doesn't need to be computed on the fly). Python seems really great for rapid developement, but I wonder if it is possible to play different media synchronously (the media decoding itself will be of course coded in C/C++) with it? Does anyone here have any experience with multimedia and python ? www.squeak.org It's not Python {but there are bindings available {should you need them}}. ...Should take you a couple of hours. If you really have your heart set on python: http://pythoncard.sourceforge.net Thank you all for your answers. I don't know why I didn't think about PD: excellent way to see its possibilities ! Concerning the SC language: I don't know anything about it, but I think it is kind of overkill for my application (which doesn't really demand any RT capabilities, if you don't consider playing a video as a RT problem). Seems interesting, though for other applications. cheers, David
Re: [linux-audio-dev]Using python for small multimedia app ?
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 hi, while doing some research for FreeJ, i now ended up integrating the Javascript OO parser (mozilla.org/js SpiderMonkey) which is more than satisfying for the purpose. is SuperCollider implementing its own parser? FreeJ is only video app and the next version will soon feature scriptability, it would be definitely interesting for me to seek integration with a language like SC. ciao - -- jaromil, dyne.org rasta coder, http://rastasoft.org -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.4 (GNU/Linux) Comment: Cryptographically signed mail, see http://gnupg.org iD8DBQFAwDsZWLCC1ltubZcRAk4yAJ9LaaXqi23XOev/Mhp3cWqKgQxobgCeOv+A UZuhHI9Ms4/ydH88k8YS+iY= =9NO5 -END PGP SIGNATURE-
Re: [linux-audio-dev]Using python for small multimedia app ?
Hi, This subject reminded me that some time ago, a friend of mine mentioned that he had read a message of James McCartney (SuperCollider) in which James talked about his decision of having implemented his own OO language for SC rather than reusing an existing, generic, OO language. I looked for this message but could not find it, so I wrote James directly, because I thought it might be an interesting addition to this thread. James gave me a very extensive reply, which I forward to the list. Maarten ->8 Begin forwarded message: Date: Thu, 3 Jun 2004 15:34:01 -0700 From: james mccartney <[EMAIL PROTECTED]> To: [EMAIL PROTECTED] Subject: Re: supercollider vs generic OO languages I've included the original text file you are probably looking for below. Here's some current remarks.. First of all I'm not sure many folks had heard about Python and definitely not Ruby when I began writing SuperCollider in 1994. At that time Python was not the language it is now. So those languages weren't available as choices. Second, neither of those languages are meant for real time. SC has a real time garbage collector, constant time message lookup and various other features designed for real time operation. Python uses reference counting GC which has unbounded time cost when an object is freed. Third SC was written specifically for writing music and audio processes. The math system and behaviour of basic methods in the system were designed for this. I looked into what it might take to make the Ruby math system support building synthesis graphs the way that SC does, and it did not seem like an easy thing to do. I think that as languages SC is certainly comparable in strength to Python and Ruby. SC has the most flexible argument passing of any of them. Any or all arguments can be passed either positionally or by keyword to any function. Keyword arguments can occur in any order. Functions can be passed more or fewer arguments than defined. Unspecified arguments can have default values. Functions can be called with unspecified arguments bound dynamically in the caller's environment. Excess arguments can be collected in arrays. SC has closures and coroutines and is more consistent about their semantics than either Python or Ruby. SC's object model is based on Smalltalk but has also borrowed from Scheme, NewtonScript, J, Icon. SC has borrowed some syntax features from Ruby which happened to have co-evolved with a similar syntax. SC no longer has to run at interrupt level as it did on OS 9, but many of the issues for real time operation are the same. Rather than struggle with a language not designed for real time they should investigate using SuperCollider. It has been ported to linux. SuperCollider 2.0 Why SuperCollider 2.0 ? SuperCollider version 2.0 is a new programming language. Why invent a new language and not use an existing language? Computer music composition is a specification problem. Both sound synthesis and the composition of sounds are complex problems and demand a language which is highly expressive in order to deal with that complexity. Real time signal processing is a problem demanding an efficient implementation with bounded time operations. There was no language combining the features I wanted and needed for doing digital music synthesis. The SuperCollider language is most like Smalltalk. Everything is an object. It has class objects, methods, dynamic typing, full closures, default arguments, variable length argument lists, multiple assignment, etc. The implementation provides fast, constant time method lookup, real time garbage collection, and stack allocation of most function contexts while maintaining full closure semantics. The SuperCollider virtual machine is designed so that it can be run at interrupt level. There was no other language readily available that was high level, real time and capable of running at interrupt level. SuperCollider version 1.0 was completely rewritten to make it both more expressive and more efficient. This required rethinking the implementation in light of the experience of the first version. It is my opinion that the new version has benefitted significantly from this rethink. It is not simply version 1.0 with more features. Why use a text based language rather than a graphical language? There are at least two answers to this. Dynamism: Most graphical synthesis environments use statically allocated unit generators. In SuperCollider, the user can create structures which spawn events dynamically and in a nested fashion. Patches can be built dynamically and parameterized not just by floating point numbers from a static score, but by other graphs of unit generators as well. Or you can construct patches algorithmically on the fly. This kind of fluidity is not possible in a language with statically allocated unit generators. Brevity: In SuperCollider, symmetries in a patch can be exploited by eithe
Re: [linux-audio-dev]Using python for small multimedia app ?
On 2004-06-03 14:54:56 + Cournapeau David <[EMAIL PROTECTED]> wrote: I am discovering python, having looked for a matlab-like environement. I am wondering now if it is possible to do some small multimedia applications with it; more precisely, I would like to develop a scientific application for audio/video analysis. Basically, I need to show an avi video with a synchronised waveform view of the sound, and some other features views, like the pitch of the film voices (the actual pitch detection doesn't need to be computed on the fly). Python seems really great for rapid developement, but I wonder if it is possible to play different media synchronously (the media decoding itself will be of course coded in C/C++) with it? Does anyone here have any experience with multimedia and python ? www.squeak.org It's not Python {but there are bindings available {should you need them}}. ...Should take you a couple of hours. If you really have your heart set on python: http://pythoncard.sourceforge.net
Re: [linux-audio-dev]Using python for small multimedia app ?
Check out pymedia too. Simon. -- Simon Burton, B.Sc. Licensed PO Box 8066 ANU Canberra 2601 Australia Ph. 61 02 6249 6940 http://arrowtheory.com
Re: [linux-audio-dev]Using python for small multimedia app ?
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Thu, Jun 03, 2004 at 05:45:42PM +0200, Frank Barknecht wrote: > Ahem: Pure data, anyone? http://pure-data.iem.at i agree with Frank that's definitely the best for you, if you reach to get a hold with the messy documentation, you'll end up being able to build things like you said in less than 2 days. ciao - -- jaromil, dyne.org rasta coder, http://rastasoft.org -BEGIN PGP SIGNATURE- Version: GnuPG v1.2.4 (GNU/Linux) Comment: Cryptographically signed mail, see http://gnupg.org iD8DBQFAv2NkWLCC1ltubZcRAoQyAKCHWLdbnhrTwQaQAXA4iFbbgPMPYwCfWH9h 6Lv7qjfWSu8ZTCvBVjg6sxM= =y2SM -END PGP SIGNATURE-
Re: [linux-audio-dev]Using python for small multimedia app ?
On Thu Jun 3 12:58:06 2004 Paul Winkler wrote: > Numeric (c extensions that give you high-speed matrix math stuff, > might be handy for DSP) > http://www.pfdubois.com/numpy/ These extensions are also used by PyJack http://www.a2hd.com/software/ Jan -- Jan Weil My Linux Audio weblog: http://www.jawebada.de/index.cgi/blog/lad
Re: [linux-audio-dev]Using python for small multimedia app ?
On Thu, Jun 03, 2004 at 11:54:56PM +0900, Cournapeau David wrote: > Hi there, > > I am discovering python, having looked for a matlab-like > environement. I am wondering now if it is possible to do some small > multimedia applications with it; more precisely, I would like to develop a > scientific application for audio/video analysis. Basically, I need to > show an avi > video with a synchronised waveform view of the sound, and some other > features views, like the pitch of the film voices (the actual pitch > detection doesn't need to be computed on the fly). > > Python seems really great for rapid developement, but I wonder if it > is possible to play different media synchronously (the media decoding > itself will be of course coded in C/C++) with it? Does anyone here have > any experience with multimedia and python ? I'm a full-time python/zope hacker but never done any multimedia apps with python. but here's some libs you might look at: Numeric (c extensions that give you high-speed matrix math stuff, might be handy for DSP) http://www.pfdubois.com/numpy/ SciPi - extensions that give you lots of pretty fast stuff including data visualization and DSP. http://www.scipy.org pygame - libraries for doing games and apps with openGL graphics, includes a lot of handy multimedia stuff (e.g. an audio mixer). http://www.pygame.org pyUI - built on pygame, for general-purpose UIs. http://pyui.sourceforge.net/ -- Paul Winkler http://www.slinkp.com
Re: [linux-audio-dev]Using python for small multimedia app ?
I read: > Python seems really great for rapid developement, but I wonder if it is > possible to play different media synchronously (the media decoding > itself will be of course coded in C/C++) with it? Does anyone here have > any experience with multimedia and python ? http://pygame.org/ http://www.speech.kth.se/snack/ http://www.visionegg.org/ for starts, HTH x -- [EMAIL PROTECTED] Postmodernism is german romanticism with better http://pilot.fm/special effects. (Jeff Keuss / via ctheory.com)
Re: [linux-audio-dev]Using python for small multimedia app ?
Cournapeau David wrote: Should it be cross-platform or linux centric? For Linux there are gstreamer bindings for Python. Never did anything with gstreamer, but sounds very promissing and a friend is doing impressive stuff with gstreamer. Hi there, I am discovering python, having looked for a matlab-like environement. I am wondering now if it is possible to do some small multimedia applications with it; more precisely, I would like to develop a scientific application for audio/video analysis. Basically, I need to show an avi video with a synchronised waveform view of the sound, and some other features views, like the pitch of the film voices (the actual pitch detection doesn't need to be computed on the fly). Python seems really great for rapid developement, but I wonder if it is possible to play different media synchronously (the media decoding itself will be of course coded in C/C++) with it? Does anyone here have any experience with multimedia and python ? cheers, David
Re: [linux-audio-dev]Using python for small multimedia app ?
Hallo, Cournapeau David hat gesagt: // Cournapeau David wrote: > I am discovering python, having looked for a matlab-like > environement. I am wondering now if it is possible to do some small > multimedia applications with it; more precisely, I would like to develop a > scientific application for audio/video analysis. Basically, I need to > show an avi > video with a synchronised waveform view of the sound, and some other > features views, like the pitch of the film voices (the actual pitch > detection doesn't need to be computed on the fly). Ahem: Pure data, anyone? http://pure-data.iem.at But I also would say, Python is fine for every application. Just start coding, let noone stop you. Python is wonderful. Although your application above would really profit from powerful libraries for sound and video, which are included in Pd and which you might have to write on your own with Python (at least write C-to-Python-bridges) Ciao -- Frank Barknecht _ __footils.org__
[linux-audio-dev]Using python for small multimedia app ?
Hi there, I am discovering python, having looked for a matlab-like environement. I am wondering now if it is possible to do some small multimedia applications with it; more precisely, I would like to develop a scientific application for audio/video analysis. Basically, I need to show an avi video with a synchronised waveform view of the sound, and some other features views, like the pitch of the film voices (the actual pitch detection doesn't need to be computed on the fly). Python seems really great for rapid developement, but I wonder if it is possible to play different media synchronously (the media decoding itself will be of course coded in C/C++) with it? Does anyone here have any experience with multimedia and python ? cheers, David