From: Steve K. <st...@st...> - 2004-09-13 23:40:43
|
Stephen Uhler wrote: >Using the jabra-250 bluetooth headset for the iaxclient doesn't work, >as it is only a mono device, and "audio_portaudio.c" requires stereo. > >However, if I simply comment out the "#ifndef MACOSX" on line 449, >it works, as does the internal mic and external speakers. Am I missing >something, or can the "#ifndef MACOSX" be safely eliminated? > > No, if you remove that, then all mac input from stereo devices will only accept the left channel. The solution to this problem, it would seem, would be to reverse the order of the audio device open tests, at least for input devices: For them, on the Mac, one should try to open the device in stereo first [two channels], and if that fails, to then try to open just one channel. The basic difference on the Mac vs other platforms is that on Windows and Linux, opening one channel will give you a monaural channel, but the mac will generally give you just the left channel. P.S. Stephen, I meant to write this separately, [and I suspect that you already know this], but it seems there is a race condition in iaxcli.c: The race is between events sent to the client from the iaxclient thread, and responses to commands from the client. Both of these can generate output, and call stdio, which probably isn't thread safe. (I haven't actually seen this, but I suspect that it can happen). With the present design, a mutex in report() will probably resolve this? -SteveK |