aboutsummaryrefslogtreecommitdiff
path: root/audio
diff options
context:
space:
mode:
authorTorbjörn Andersson2019-02-04 07:29:49 +0100
committerFilippos Karapetis2019-02-10 16:32:02 +0200
commitcc958f70efb78ebb2e462b2e2563fb9ad6254685 (patch)
treeec886fb1933a5c9c3a1a7a6323acb984bf7f4e19 /audio
parent9785d5007a7754ab988b51a8780d6a3dcc80dce4 (diff)
downloadscummvm-rg350-cc958f70efb78ebb2e462b2e2563fb9ad6254685.tar.gz
scummvm-rg350-cc958f70efb78ebb2e462b2e2563fb9ad6254685.tar.bz2
scummvm-rg350-cc958f70efb78ebb2e462b2e2563fb9ad6254685.zip
AUDIO: Simplify _audioGain calculation
No need to explicitly set it to 1.0. (There may have been in an earlier version, to avoid any possible rounding error. But if so, that reason is long gone.)
Diffstat (limited to 'audio')
-rw-r--r--audio/decoders/ac3.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/audio/decoders/ac3.cpp b/audio/decoders/ac3.cpp
index 1b2a3bff76..170d688b23 100644
--- a/audio/decoders/ac3.cpp
+++ b/audio/decoders/ac3.cpp
@@ -67,10 +67,7 @@ private:
};
AC3Stream::AC3Stream(double decibel = 0.0) : _a52State(0), _frameSize(0), _inBufPtr(0), _flags(0), _sampleRate(0) {
- if (decibel != 0.0)
- _audioGain = pow(2, decibel / 6);
- else
- _audioGain = 1.0;
+ _audioGain = pow(2, decibel / 6);
}
AC3Stream::~AC3Stream() {