Remove unneeded echo buffer hacks.

This commit is contained in:
Brandon Wright 2011-06-27 10:23:58 -05:00
parent ebc9e721f6
commit 7be5976159
2 changed files with 27 additions and 39 deletions

View File

@ -605,11 +605,7 @@ VOICE_CLOCK(V9_V6_V3) { voice_V9(v); voice_V6(v+1); voice_V3(v+2); }
inline void SPC_DSP::echo_read( int ch )
{
int s;
if ( m.t_echo_ptr >= 0xffc0 && rom_enabled )
s = GET_LE16SA( &hi_ram [m.t_echo_ptr + ch * 2 - 0xffc0] );
else
s = GET_LE16SA( ECHO_PTR( ch ) );
int s = GET_LE16SA( ECHO_PTR( ch ) );
// second copy simplifies wrap-around handling
ECHO_FIR( 0 ) [ch] = ECHO_FIR( 8 ) [ch] = s >> 1;
}
@ -720,12 +716,7 @@ ECHO_CLOCK( 28 )
inline void SPC_DSP::echo_write( int ch )
{
if ( !(m.t_echo_enabled & 0x20) )
{
if ( m.t_echo_ptr >= 0xffc0 && rom_enabled )
SET_LE16A( &hi_ram [m.t_echo_ptr + ch * 2 - 0xffc0], m.t_echo_out [ch] );
else
SET_LE16A( ECHO_PTR( ch ), m.t_echo_out [ch] );
}
SET_LE16A( ECHO_PTR( ch ), m.t_echo_out [ch] );
m.t_echo_out [ch] = 0;
}
@ -837,7 +828,6 @@ void SPC_DSP::init( void* ram_64k )
stereo_switch = 0xffff;
take_spc_snapshot = 0;
spc_snapshot_callback = 0;
rom_enabled = 0;
#ifndef NDEBUG
// be sure this sign-extends

View File

@ -69,8 +69,6 @@ public:
int stereo_switch;
int take_spc_snapshot;
int rom_enabled; // mirror
uint8_t *rom, *hi_ram; // mirror
void (*spc_snapshot_callback) (void);
void set_spc_snapshot_callback( void (*callback) (void) );