From 36ce418854270aa5246ede7573f4cacd062752df Mon Sep 17 00:00:00 2001 From: Johannes Schickel Date: Fri, 23 Sep 2011 20:32:16 +0200 Subject: AUDIO: Sync DOSBox OPL code a bit. This only touches a line which is not used in the current setup. --- audio/softsynth/opl/dbopl.cpp | 8 ++++---- audio/softsynth/opl/dbopl.h | 4 ++-- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/audio/softsynth/opl/dbopl.cpp b/audio/softsynth/opl/dbopl.cpp index 2c46cfee75..02c2317b25 100644 --- a/audio/softsynth/opl/dbopl.cpp +++ b/audio/softsynth/opl/dbopl.cpp @@ -1,5 +1,5 @@ /* - * Copyright (C) 2002-2010 The DOSBox Team + * Copyright (C) 2002-2011 The DOSBox Team * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -32,7 +32,7 @@ //DUNNO Keyon in 4op, switch to 2op without keyoff. */ -// Last synch with DOSBox SVN trunk r3556 +// Last synch with DOSBox SVN trunk r3752 #include "dbopl.h" @@ -572,7 +572,7 @@ INLINE Bits Operator::GetWave( Bitu index, Bitu vol ) { return (waveBase[ index & waveMask ] * MulTable[ vol >> ENV_EXTRA ]) >> MUL_SH; #elif ( DBOPL_WAVE == WAVE_TABLELOG ) Bit32s wave = waveBase[ index & waveMask ]; - Bit32u total = ( wave & 0x7fff ) + ( vol << ( 3 - ENV_EXTRA ) ); + Bit32u total = ( wave & 0x7fff ) + vol << ( 3 - ENV_EXTRA ); Bit32s sig = ExpTable[ total & 0xff ]; Bit32u exp = total >> 8; Bit32s neg = wave >> 16; @@ -1236,7 +1236,7 @@ void Chip::GenerateBlock2( Bitu total, Bit32s* output ) { void Chip::GenerateBlock3( Bitu total, Bit32s* output ) { while ( total > 0 ) { Bit32u samples = ForwardLFO( total ); - memset(output, 0, sizeof(Bit32s) * 2 * samples); + memset(output, 0, sizeof(Bit32s) * samples * 2); int count = 0; for( Channel* ch = chan; ch < chan + 18; ) { count++; diff --git a/audio/softsynth/opl/dbopl.h b/audio/softsynth/opl/dbopl.h index 87d1045fab..3dbd98986d 100644 --- a/audio/softsynth/opl/dbopl.h +++ b/audio/softsynth/opl/dbopl.h @@ -1,5 +1,5 @@ /* - * Copyright (C) 2002-2010 The DOSBox Team + * Copyright (C) 2002-2011 The DOSBox Team * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by @@ -16,7 +16,7 @@ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ -// Last synch with DOSBox SVN trunk r3556 +// Last synch with DOSBox SVN trunk r3752 #ifndef SOUND_SOFTSYNTH_OPL_DBOPL_H #define SOUND_SOFTSYNTH_OPL_DBOPL_H -- cgit v1.2.3