Måns Rullgård wrote:
If you are playing fairly short pieces of sound you might be able to use this function I wrote some time ago:
function playsnd(y,fs,bits)
wf = tempname; ws = warning; warning off wavwrite(y, fs, bits, wf); warning ws wf = [wf '.wav']; [s,o] = unix(sprintf('aplay %s', wf)); delete(wf);
Well, I precisely want to avoid writing to a temporary file :)
But right now, my function seems to work, I just used UNIX signals to close cleanly the audio device, it was much simpler than what I thought at first.
Cheers,
David
------------------------------------------------------- This SF.Net email is sponsored by: Oracle 10g Get certified on the hottest thing ever to hit the market... Oracle 10g. Take an Oracle 10g class now, and we'll give you the exam FREE. http://ads.osdn.com/?ad_id149&alloc_id66&op=click _______________________________________________ Alsa-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/alsa-devel