Re: [livecode] audio source in linux

From: <zmoelnig_at_iem.at>
Date: Sat, 03 May 2008 10:50:22 +0200

Quoting AlgoMantra <algomantra_at_gmail.com>:

>>
>> Operating systems provide various interfaces (API) to pass buffers of
>> samples between the userspace program and the soundcard driver -- on Linux
>> this is usually ALSA or OSS.
>>
>
> So I have ALSA on my box. And I want to talk to my sound card through ALSA(
> do I have an option?), but in the command line or a shell script.

in unix everything is a file, even your soundcard output.
so just send the "numbers" (in binary that is) to the correct file.

like that:
# cat /dev/hda > /dev/dsp

agreed, it is not the most creative example; i like this one better:
# find /usr/src/linux-headers-2.6.24-16 -type f -exec cat '{}' \; > /dev/dsp

however, you need OSS for this (luckily there is the OSS emulation for ALSA)



mfgads.r
IOhannes

----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.
Received on Sat May 03 2008 - 08:50:34 BST

This archive was generated by hypermail 2.4.0 : Sun Aug 20 2023 - 16:02:23 BST