[Scummvm-cvs-logs] scummvm master -> 8a62471b2112dd178ea550f9e6b85ce13b0b18ff
bluegr
bluegr at gmail.com
Sun Mar 3 22:02:13 CET 2013
This automated email contains information about 2 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
7880323590 MT-32: Also replace cosf() (C99) with cos()
8a62471b21 MT-32: Sync with the latest changes in munt
Commit: 7880323590ae8b962e2dff776ce11d437b25734d
https://github.com/scummvm/scummvm/commit/7880323590ae8b962e2dff776ce11d437b25734d
Author: Filippos Karapetis (bluegr at gmail.com)
Date: 2013-03-03T12:59:33-08:00
Commit Message:
MT-32: Also replace cosf() (C99) with cos()
Changed paths:
audio/softsynth/mt32/LegacyWaveGenerator.cpp
diff --git a/audio/softsynth/mt32/LegacyWaveGenerator.cpp b/audio/softsynth/mt32/LegacyWaveGenerator.cpp
index d315fb4..35ca975 100644
--- a/audio/softsynth/mt32/LegacyWaveGenerator.cpp
+++ b/audio/softsynth/mt32/LegacyWaveGenerator.cpp
@@ -179,7 +179,7 @@ float LA32WaveGenerator::generateNextSample(const Bit32u ampVal, const Bit16u pi
// 1st cosine segment
if (relWavePos < cosineLen) {
- sample = -cosf(FLOAT_PI * relWavePos / cosineLen);
+ sample = -cos(FLOAT_PI * relWavePos / cosineLen);
} else
// high linear segment
@@ -189,7 +189,7 @@ float LA32WaveGenerator::generateNextSample(const Bit32u ampVal, const Bit16u pi
// 2nd cosine segment
if (relWavePos < (2 * cosineLen + hLen)) {
- sample = cosf(FLOAT_PI * (relWavePos - (cosineLen + hLen)) / cosineLen);
+ sample = cos(FLOAT_PI * (relWavePos - (cosineLen + hLen)) / cosineLen);
} else {
// low linear segment
@@ -258,7 +258,7 @@ float LA32WaveGenerator::generateNextSample(const Bit32u ampVal, const Bit16u pi
// sawtooth waves
if (sawtoothWaveform) {
- sample *= cosf(FLOAT_2PI * wavePos / waveLen);
+ sample *= cos(FLOAT_2PI * wavePos / waveLen);
}
wavePos++;
Commit: 8a62471b2112dd178ea550f9e6b85ce13b0b18ff
https://github.com/scummvm/scummvm/commit/8a62471b2112dd178ea550f9e6b85ce13b0b18ff
Author: Filippos Karapetis (bluegr at gmail.com)
Date: 2013-03-03T13:01:12-08:00
Commit Message:
MT-32: Sync with the latest changes in munt
Changed paths:
audio/softsynth/mt32/LA32WaveGenerator.cpp
diff --git a/audio/softsynth/mt32/LA32WaveGenerator.cpp b/audio/softsynth/mt32/LA32WaveGenerator.cpp
index 74dba78..5b2c900 100644
--- a/audio/softsynth/mt32/LA32WaveGenerator.cpp
+++ b/audio/softsynth/mt32/LA32WaveGenerator.cpp
@@ -55,8 +55,10 @@ void LA32Utilites::addLogSamples(LogSample &logSample1, const LogSample &logSamp
Bit32u LA32WaveGenerator::getSampleStep() {
// sampleStep = EXP2F(pitch / 4096.0f + 4.0f)
Bit32u sampleStep = LA32Utilites::interpolateExp(~pitch & 4095);
+ sampleStep &= ~1;
sampleStep <<= pitch >> 12;
sampleStep >>= 8;
+ sampleStep &= ~1;
return sampleStep;
}
More information about the Scummvm-git-logs
mailing list