Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical

Re: reading sound input

by thunders (Priest)
on Jan 21, 2010 at 04:26 UTC ( #818627=note: print w/replies, xml ) Need Help??

in reply to reading sound input

Which operating system are you on? For *NIX there is a device handle called /dev/dsp that you can read data from, the module Audio::DSP allows an easier interface to setting that up, on windows there's something called Win32::SoundRec. Once you have the data there is another module called PDL::Audio that should allow for manipulation and writing of the file.

What do you want to do with the sound? For real time recording/manipulation/output perl may not be the best tool for the job, especially if you don't have much experience with perl. Do you have experience with manipulation of sound files?

Replies are listed 'Best First'.
Re^2: reading sound input
by bcrowell2 (Friar) on Mar 04, 2011 at 19:59 UTC

    AFAIK, the available options are all lousy, and I wouldn't suggest starting any new project in perl using sound input until the situation improves.

    Audio::DSP leaks memory, and the bug report on the memory-leak bug has been open since 2003.

    Audio::OSS depends on OSS, but OSS emulation on Linux has been deteriorating rapidly in quality. It was removed by default in ubuntu 10.10, and you have to jump through extra hoops to get it to work (e.g., installing the also-oss package and invoking your program foo as "aoss foo"). I have experienced a lot of problems with bugs and poor performance, and these can be difficult to test for, since they depend, e.g., on what version of ubuntu you're running.

    What is really missing right now is any kind of ALSA interface for linux. Either that or you could wait five years and hope that the quality of OSS emulation becomes acceptable.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://818627]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others taking refuge in the Monastery: (6)
As of 2020-07-08 11:08 GMT
Find Nodes?
    Voting Booth?

    No recent polls found