fixed compiler warnings

git-svn-id: https://lmms.svn.sf.net/svnroot/lmms/trunk/lmms@1708 0778d3d1-df1d-0410-868b-ea421aaaa00d
This commit is contained in:
Tobias Doerffel
2008-09-24 09:33:01 +00:00
parent 926df4157f
commit 513c7af9bc
4 changed files with 25 additions and 13 deletions

View File

@@ -220,13 +220,13 @@ void Filter::reset()
// ----------------------------------------------------------------------------
void Filter::writeFC_LO(reg8 fc_lo)
{
fc = fc & 0x7f8 | fc_lo & 0x007;
fc = ( fc & 0x7f8 ) | ( fc_lo & 0x007 );
set_w0();
}
void Filter::writeFC_HI(reg8 fc_hi)
{
fc = (fc_hi << 3) & 0x7f8 | fc & 0x007;
fc = ( (fc_hi << 3) & 0x7f8 ) | ( fc & 0x007 );
set_w0();
}

View File

@@ -20,6 +20,18 @@
#include "sid.h"
#include <math.h>
const int cSID::FIR_N = 125;
const int cSID::FIR_RES_INTERPOLATE = 285;
const int cSID::FIR_RES_FAST = 51473;
const int cSID::FIR_SHIFT = 15;
const int cSID::RINGSIZE = 16384;
// Fixpoint constants (16.16 bits).
const int cSID::FIXP_SHIFT = 16;
const int cSID::FIXP_MASK = 0xffff;
// ----------------------------------------------------------------------------
// Constructor.
// ----------------------------------------------------------------------------

View File

@@ -117,15 +117,15 @@ protected:
// http://www-ccrma.stanford.edu/~jos/resample/Choice_Table_Size.html
// For a resolution of 16 bits this yields L >= 285 and L >= 51473,
// respectively.
static const int FIR_N = 125;
static const int FIR_RES_INTERPOLATE = 285;
static const int FIR_RES_FAST = 51473;
static const int FIR_SHIFT = 15;
static const int RINGSIZE = 16384;
static const int FIR_N;
static const int FIR_RES_INTERPOLATE;
static const int FIR_RES_FAST;
static const int FIR_SHIFT;
static const int RINGSIZE;
// Fixpoint constants (16.16 bits).
static const int FIXP_SHIFT = 16;
static const int FIXP_MASK = 0xffff;
static const int FIXP_SHIFT;
static const int FIXP_MASK;
// Sampling variables.
sampling_method sampling;

View File

@@ -68,22 +68,22 @@ void WaveformGenerator::set_chip_model(chip_model model)
// ----------------------------------------------------------------------------
void WaveformGenerator::writeFREQ_LO(reg8 freq_lo)
{
freq = freq & 0xff00 | freq_lo & 0x00ff;
freq = ( freq & 0xff00 ) | ( freq_lo & 0x00ff );
}
void WaveformGenerator::writeFREQ_HI(reg8 freq_hi)
{
freq = (freq_hi << 8) & 0xff00 | freq & 0x00ff;
freq = ( (freq_hi << 8) & 0xff00 ) | ( freq & 0x00ff );
}
void WaveformGenerator::writePW_LO(reg8 pw_lo)
{
pw = pw & 0xf00 | pw_lo & 0x0ff;
pw = ( pw & 0xf00 ) | ( pw_lo & 0x0ff );
}
void WaveformGenerator::writePW_HI(reg8 pw_hi)
{
pw = (pw_hi << 8) & 0xf00 | pw & 0x0ff;
pw = ( (pw_hi << 8) & 0xf00 ) | ( pw & 0x0ff );
}
void WaveformGenerator::writeCONTROL_REG(reg8 control)