Lines Matching refs:newVolume
419 static inline bool setVolumeRampVariables(float newVolume, int32_t ramp, in setVolumeRampVariables() argument
427 if (newVolume == *pSetVolume) { in setVolumeRampVariables()
430 if (newVolume < 0) { in setVolumeRampVariables()
431 newVolume = 0; // should not have negative volumes in setVolumeRampVariables()
433 switch (fpclassify(newVolume)) { in setVolumeRampVariables()
436 newVolume = 0; in setVolumeRampVariables()
446 newVolume = AudioMixer::UNITY_GAIN_FLOAT; in setVolumeRampVariables()
454 if (newVolume > AudioMixer::UNITY_GAIN_FLOAT) { in setVolumeRampVariables()
455 newVolume = AudioMixer::UNITY_GAIN_FLOAT; in setVolumeRampVariables()
467 const float inc = (newVolume - *pPrevVolume) / ramp; // could be inf, nan, subnormal in setVolumeRampVariables()
469 const float maxv = std::max(newVolume, *pPrevVolume); in setVolumeRampVariables()
488 const float scaledVolume = newVolume * AudioMixer::UNITY_GAIN_INT; // not neg, subnormal, nan in setVolumeRampVariables()
511 *pPrevVolume = newVolume; in setVolumeRampVariables()
515 *pSetVolume = newVolume; in setVolumeRampVariables()