summaryrefslogtreecommitdiff
path: root/indra/newview/llvoicevivox.cpp
diff options
context:
space:
mode:
authorRider Linden <rider@lindenlab.com>2016-03-07 12:54:49 -0800
committerRider Linden <rider@lindenlab.com>2016-03-07 12:54:49 -0800
commit7a0fb4fece5a92627caa08622e9584a903a3fa1d (patch)
treea02db13477404ce3f50a2bec245da139ad963c2f /indra/newview/llvoicevivox.cpp
parentd51a5a615ab4c1c52b4e8c2eaa1f88bf785f3f66 (diff)
MAINT-6172: Send the render and mic devices to a session when they are dirty, not just in Tuning mode.
Diffstat (limited to 'indra/newview/llvoicevivox.cpp')
-rwxr-xr-xindra/newview/llvoicevivox.cpp19
1 files changed, 19 insertions, 0 deletions
diff --git a/indra/newview/llvoicevivox.cpp b/indra/newview/llvoicevivox.cpp
index c8bfc63a6a..660ca9e5b7 100755
--- a/indra/newview/llvoicevivox.cpp
+++ b/indra/newview/llvoicevivox.cpp
@@ -1470,6 +1470,7 @@ bool LLVivoxVoiceClient::runSession(const sessionStatePtr_t &session)
while (mVoiceEnabled && !mSessionTerminateRequested && !mTuningMode)
{
+ sendCaptureAndRenderDevices();
if (mAudioSession && mAudioSession->mParticipantsChanged)
{
mAudioSession->mParticipantsChanged = false;
@@ -1557,6 +1558,24 @@ bool LLVivoxVoiceClient::runSession(const sessionStatePtr_t &session)
return true;
}
+void LLVivoxVoiceClient::sendCaptureAndRenderDevices()
+{
+ if (mCaptureDeviceDirty || mRenderDeviceDirty)
+ {
+ std::ostringstream stream;
+
+ buildSetCaptureDevice(stream);
+ buildSetRenderDevice(stream);
+
+ if (!stream.str().empty())
+ {
+ writeString(stream.str());
+ }
+
+ llcoro::suspendUntilTimeout(UPDATE_THROTTLE_SECONDS);
+ }
+}
+
void LLVivoxVoiceClient::recordingAndPlaybackMode()
{
LL_INFOS("Voice") << "In voice capture/playback mode." << LL_ENDL;