Stefan Sayer wrote:
you can use AmAudioQueue (AmAdvancedAudio.h) to write audio to two
AmAudio devices.
put both the audio_connector and the AmAudioFile in the write queue,
and it will write to both. You don't even have to modify the
AmAudioConnector, you just catch the b2abconnectaudio event, and after
it is connected, you get the output with getOutput() and put it in the
queue, like
MySession::onB2ABEvent(ev) {
AmB2ABCallerSession::onB2ABEvent(ev);
if (ev-event-id==B2ABConnectAudio) {
lockAudio();
audio_queue.pushAudio(getOutput(), AmAudioQueue::OutputQueue,
AmAudioQueue::Back, true, false);
audio_queue.pushAudio(my_audio_file, AmAudioQueue::OutputQueue,
AmAudioQueue::Back, true, false);
setOutput(audio_queue);
unlockAudio();
}
Now, with r1203 you can use the AmAudioMixIn to mix the audio from two
AmAudios by using AUDIO_MIXIN_IMMEDIATE_START | AUDIO_MIXIN_ONCE as
flags. Additionally, you can use AmAudioBridge to connect read and
write (input and output), this way by using getInput() and with an
extra AmAudioQueue you can do the whole thing in the caller session
easily I guess.
I'm not sure that i get it well. So in Your solution both legs of the
b2abua call all recorded to diffrent files ? So, there is now way to
write contents from one AmAudio to another ?
Can You explain a little more that idea with AmAudioMixIn ? I guess that
it was intented to mix AmAudio with a static file. An AmAudioFile object
is especially AmAudio so i can mix two files, but what then ? I get
another AmAudio object which i don't know how to write to disk :(
Best regards,
--
Wojciech Wrona
_______________________________________________
Semsdev mailing list
[email protected]
http://lists.iptel.org/mailman/listinfo/semsdev