From e14432b2aca9f0ac640e9631b4faece91525053c Mon Sep 17 00:00:00 2001 From: Arrehn Date: Sun, 30 Jan 2011 03:00:02 -0500 Subject: [PATCH] Backport STORM-830 patch --HG-- branch : Firestorm_2.4.1 --- indra/llaudio/llaudioengine.cpp | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/indra/llaudio/llaudioengine.cpp b/indra/llaudio/llaudioengine.cpp index 1cc03bddb8..7e8ea017b9 100644 --- a/indra/llaudio/llaudioengine.cpp +++ b/indra/llaudio/llaudioengine.cpp @@ -97,7 +97,11 @@ void LLAudioEngine::setDefaults() } mMasterGain = 1.f; - mInternalGain = 0.f; + // Setting mInternalGain to an out of range value fixes the issue reported in STORM-830. + // There is an edge case in setMasterGain during startup which prevents setInternalGain from + // being called if the master volume setting and mInternalGain both equal 0, so using -1 forces + // the if statement in setMasterGain to execute when the viewer starts up. + mInternalGain = -1.f; mNextWindUpdate = 0.f; mStreamingAudioImpl = NULL;