diff --git a/plugins/opl2/opl2instrument.cpp b/plugins/opl2/opl2instrument.cpp index b84edf0b9..8e95d83a6 100644 --- a/plugins/opl2/opl2instrument.cpp +++ b/plugins/opl2/opl2instrument.cpp @@ -141,9 +141,6 @@ opl2instrument::opl2instrument( InstrumentTrack * _instrument_track ) : vib_depth_mdl(false, this, tr( "Vibrato Depth" ) ), trem_depth_mdl(false, this, tr( "Tremolo Depth" ) ) { - // Connect the plugin to the mixer... - InstrumentPlayHandle * iph = new InstrumentPlayHandle( this, _instrument_track ); - Engine::mixer()->addPlayHandle( iph ); // Create an emulator - samplerate, 16 bit, mono emulatorMutex.lock(); @@ -220,6 +217,10 @@ opl2instrument::opl2instrument( InstrumentTrack * _instrument_track ) : MOD_CON( fm_mdl ); MOD_CON( vib_depth_mdl ); MOD_CON( trem_depth_mdl ); + + // Connect the plugin to the mixer... + InstrumentPlayHandle * iph = new InstrumentPlayHandle( this, _instrument_track ); + Engine::mixer()->addPlayHandle( iph ); } opl2instrument::~opl2instrument() { diff --git a/plugins/sf2_player/sf2_player.cpp b/plugins/sf2_player/sf2_player.cpp index f2acd2f07..e94c40b6e 100644 --- a/plugins/sf2_player/sf2_player.cpp +++ b/plugins/sf2_player/sf2_player.cpp @@ -118,9 +118,6 @@ sf2Instrument::sf2Instrument( InstrumentTrack * _instrument_track ) : // everytime we load a new soundfont. m_synth = new_fluid_synth( m_settings ); - InstrumentPlayHandle * iph = new InstrumentPlayHandle( this, _instrument_track ); - Engine::mixer()->addPlayHandle( iph ); - loadFile( ConfigManager::inst()->defaultSoundfont() ); updateSampleRate(); @@ -152,6 +149,8 @@ sf2Instrument::sf2Instrument( InstrumentTrack * _instrument_track ) : connect( &m_chorusSpeed, SIGNAL( dataChanged() ), this, SLOT( updateChorus() ) ); connect( &m_chorusDepth, SIGNAL( dataChanged() ), this, SLOT( updateChorus() ) ); + InstrumentPlayHandle * iph = new InstrumentPlayHandle( this, _instrument_track ); + Engine::mixer()->addPlayHandle( iph ); }