help-octave
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Sound


From: Jonathan King
Subject: Re: Sound
Date: Thu, 6 Jul 2000 14:26:00 -0500 (CDT)

[I just put this back to help-octave alone to prevent people from getting
 multiple copies]

On Thu, 6 Jul 2000, John W. Eaton wrote:
>
> On  6-Jul-2000, Jonathan King <address@hidden> wrote:
> 
> | But the basic approach would be to grab the vector, fopen/fwrite/fclose a
> | temp file, and call system() with the correct magic incantation to play.
> | Somebody out there may have already done this...
> 
> I think that's what Octave's playaudio function already does.

I knew it; I do a help -i for "play" and "sound", but not for "audio", so 
I didn't find playaudio. :-/

Well, I just used the source for playaudio, and it does the tmpfile
shuffle, but it basically cats the result to /dev/dsp (for a vector) or
/dev/audio (if possible, for a file).  There are, as JWE points out in the
source, some limits to this approach.

It would appear that SoX could be a better basis for this kind of thing
(better abstraction in general, much more flexible for playing and
encoding output files, works with Win32 stuff, would make it easier to be
more Matlab compatible).  And, it would be handy for me to have,
personally.

But, I suspect that there would be an issue with making SoX Yet
Another Dependency for building Octave.  If I got this working, does
anybody else think it would be worth it?  (You can send me email if you
want to spare the list...)  

jking




-----------------------------------------------------------------------
Octave is freely available under the terms of the GNU GPL.

Octave's home on the web:  http://www.che.wisc.edu/octave/octave.html
How to fund new projects:  http://www.che.wisc.edu/octave/funding.html
Subscription information:  http://www.che.wisc.edu/octave/archive.html
-----------------------------------------------------------------------



reply via email to

[Prev in Thread] Current Thread [Next in Thread]