AlgoMantra wrote:
> Geeks, tuxians and audioslaves!
> I need some help here. I got a bit freaked when I saw that
> the libsndfile example files contained a program nearly 1000 lines long to
> simply play a file. But perhaps it's intended for a higher level of
> geekery.
That file contains code to play audio using :
Linux with ALSA
Linux with OSS
Apple using CoreAudio
Windows using the native Win32 API
Solaris using its' Solaris specific API.
> My task: I just want to load a few samples(wav)
Sounds like a task for libsndfile.
> which are represented on a
> GUI (using SDL) and when they knock about on the screen, sound (music)
> is generated using some rules.I need them to mix, of course.
>
> I was using SDL_mixer for this. But my problem was that I want to write to
> file (record) a whole session of the running program as a single wav. SDL_mixer
> does not seem to have writing options.
So use libsndfile.
> Now is there a way I can do this in some reasonably efficient manner using
> libsndfile?
libsndfile is for reading and writing sound files, not audio playback.
It reads/writes audio files as efficiently as possible,
> I could load using libsndfile too, skipping SDL_mixer altogether. It's
> already installed.
You will still need something for audio I/O. libsndfile won't do that
for you.
For audio I/O there are at least three possibilities, from what is
probably easiest to hardest:
PortAudio
Jack
ALSA
Hope this helps,
Erik
PS: its probably not a good idea to address more than one mailing
list per email. One reason this is bad is that people may not be
subscribed to both lists and if they reply to all, they will get
their email bounced back from the list they are not subscibed to.
-- ----------------------------------------------------------------- Erik de Castro Lopo ----------------------------------------------------------------- "Incompetence, like misery, seeks company." -- Erik Naggum _______________________________________________ Linux-audio-dev mailing list Linux-audio-dev@email-addr-hidden http://lists.linuxaudio.org/mailman/listinfo/linux-audio-devReceived on Fri Oct 24 16:15:02 2008
This archive was generated by hypermail 2.1.8 : Fri Oct 24 2008 - 16:15:02 EEST