mirror of
https://github.com/overte-org/overte.git
synced 2025-04-23 12:13:40 +02:00
Modify slider function
This commit is contained in:
parent
8bb200902f
commit
dcff873cd4
2 changed files with 2 additions and 2 deletions
|
@ -296,7 +296,7 @@ void AudioMixerSlave::addStreamToMix(AudioMixerClientData& listenerNodeData, con
|
|||
float distance = glm::max(glm::length(relativePosition), EPSILON);
|
||||
|
||||
// figure out the gain for this source at the listener
|
||||
float gain = gainForSource(listeningNodeStream, streamToAdd, relativePosition, isEcho) + (perAvatarGain - 1.0f);
|
||||
float gain = gainForSource(listeningNodeStream, streamToAdd, relativePosition, isEcho) * perAvatarGain;
|
||||
|
||||
// figure out the azimuth to this source at the listener
|
||||
float azimuth = isEcho ? 0.0f : azimuthForSource(listeningNodeStream, listeningNodeStream, relativePosition);
|
||||
|
|
|
@ -166,7 +166,7 @@ Row {
|
|||
function updateGainFromQML(avatarUuid, gainValue) {
|
||||
var data = {
|
||||
sessionId: avatarUuid,
|
||||
gain: (Math.exp(gainValue) - 1) / (Math.E - 1)
|
||||
gain: (Math.pow(20, gainValue) - 1) / (20 - 1)
|
||||
};
|
||||
pal.sendToScript({method: 'updateGain', params: data});
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue