|
From: Christian S. <chr...@ep...> - 2003-12-23 11:36:47
|
Es geschah am Montag, 22. Dezember 2003 14:59 als Kenneth Lee schrieb:
> Many thanks for great works that has been done!
> Even only Alsa for the time being is readlly wonderful
> already.
You're welcome
>
> LinuxSampler to become a Jack client would be a big
> project. For short term solution, do you have any
> suggestion to record audio output from LinuxSampler
> into audio format for the time being?
There is one dirty hack you could do to approach this: edit
src/audiothread.cpp and drop this in line 87:
int fRawOut = open("/tmp/lsaudio.raw", O_WRONLY);
so it looks like this:
...
int AudioThread::Main() {
dmsg(2,("Audio thread running\n"));
int fRawOut = open("/tmp/lsaudio.raw", O_WRONLY);
...
and in insert between line 146 and 147 this:
write(fRawOut,pAudioIO->pOutputBuffer,pAudioIO->FragmentSize * pAudioIO->Channels * sizeof(short));
so it looks like:
...
// call audio driver to output sound
int res = this->pAudioIO->Output();
if (res < 0) exit(EXIT_FAILURE);
write(fRawOut,pAudioIO->pOutputBuffer,pAudioIO->FragmentSize * pAudioIO->Channels * sizeof(short));
}
...
That way LinuxSampler constantly writes the audio output to the file
/tmp/lsaudio.raw (you can adjust path and file name of course) while it's
running and you can load that raw audio file later with the sample editor of
your choice and convert it to a sample format you like.
CU
Christian
|