For p2p/adhoc/group calls, prefer voice server type based on what's running on the region

master
Roxie Linden 2024-04-19 18:52:32 -07:00
parent eac8043ee5
commit b59ff9edc0
3 changed files with 26 additions and 5 deletions

View File

@ -15155,13 +15155,13 @@
<key>VoiceServerType</key>
<map>
<key>Comment</key>
<string>The type of voice server to connect to.</string>
<string>The type of voice server to use for group, conference, and p2p calls.</string>
<key>Persist</key>
<integer>0</integer>
<key>Type</key>
<string>String</string>
<key>Value</key>
<string>webrtc</string>
<string/>
</map>
<key>WLSkyDetail</key>
<map>

View File

@ -425,7 +425,14 @@ void startConferenceCoro(std::string url,
postData["session-id"] = tempSessionId;
postData["params"] = agents;
LLSD altParams;
altParams["voice_server_type"] = gSavedSettings.getString("VoiceServerType");
std::string voice_server_type = gSavedSettings.getString("VoiceServerType");
if (voice_server_type.empty())
{
// default to the server type associated with the region we're on.
LLVoiceVersionInfo versionInfo = LLVoiceClient::getInstance()->getVersion();
voice_server_type = versionInfo.internalVoiceServerType;
}
altParams["voice_server_type"] = voice_server_type;
postData["alt_params"] = altParams;
LLSD result = httpAdapter->postAndSuspend(httpRequest, url, postData);
@ -467,7 +474,14 @@ void startP2PVoiceCoro(std::string url, LLUUID sessionID, LLUUID creatorId, LLUU
postData["session-id"] = sessionID;
postData["params"] = otherParticipantId;
LLSD altParams;
altParams["voice_server_type"] = gSavedSettings.getString("VoiceServerType");
std::string voice_server_type = gSavedSettings.getString("VoiceServerType");
if (voice_server_type.empty())
{
// default to the server type associated with the region we're on.
LLVoiceVersionInfo versionInfo = LLVoiceClient::getInstance()->getVersion();
voice_server_type = versionInfo.internalVoiceServerType;
}
altParams["voice_server_type"] = voice_server_type;
postData["alt_params"] = altParams;
LLSD result = httpAdapter->postAndSuspend(httpRequest, url, postData);

View File

@ -594,7 +594,14 @@ void LLVoiceChannelGroup::voiceCallCapCoro(std::string url)
postData["method"] = "call";
postData["session-id"] = mSessionID;
LLSD altParams;
altParams["preferred_voice_server_type"] = gSavedSettings.getString("VoiceServerType");
std::string preferred_voice_server_type = gSavedSettings.getString("VoiceServerType");
if (preferred_voice_server_type.empty())
{
// default to the server type associated with the region we're on.
LLVoiceVersionInfo versionInfo = LLVoiceClient::getInstance()->getVersion();
preferred_voice_server_type = versionInfo.internalVoiceServerType;
}
altParams["preferred_voice_server_type"] = preferred_voice_server_type;
postData["alt_params"] = altParams;
LL_INFOS("Voice", "voiceCallCapCoro") << "Generic POST for " << url << LL_ENDL;