From 6ef3fc9a618c34e5001e05794b83bbca763f706a Mon Sep 17 00:00:00 2001 From: Hyunin Song Date: Mon, 11 Sep 2017 16:54:05 +0900 Subject: [PATCH 1/2] Don't set BB track for tracks not in the BB --- src/tracks/InstrumentTrack.cpp | 5 ++++- src/tracks/SampleTrack.cpp | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/tracks/InstrumentTrack.cpp b/src/tracks/InstrumentTrack.cpp index 71cc43fb56e..3627bf34ece 100644 --- a/src/tracks/InstrumentTrack.cpp +++ b/src/tracks/InstrumentTrack.cpp @@ -586,7 +586,10 @@ bool InstrumentTrack::play( const MidiTime & _start, const fpp_t _frames, { TrackContentObject * tco = getTCO( _tco_num ); tcos.push_back( tco ); - bb_track = BBTrack::findBBTrack( _tco_num ); + if (trackContainer() == (TrackContainer*)Engine::getBBTrackContainer()) + { + bb_track = BBTrack::findBBTrack( _tco_num ); + } } else { diff --git a/src/tracks/SampleTrack.cpp b/src/tracks/SampleTrack.cpp index 0dd491c64d5..3c16025a540 100644 --- a/src/tracks/SampleTrack.cpp +++ b/src/tracks/SampleTrack.cpp @@ -587,7 +587,10 @@ bool SampleTrack::play( const MidiTime & _start, const fpp_t _frames, return false; } tcos.push_back( getTCO( _tco_num ) ); - bb_track = BBTrack::findBBTrack( _tco_num ); + if (trackContainer() == (TrackContainer*)Engine::getBBTrackContainer()) + { + bb_track = BBTrack::findBBTrack( _tco_num ); + } } else { From 176d2e9d3d7d703f4f568697ec3a665db70209de Mon Sep 17 00:00:00 2001 From: Hyunin Song Date: Mon, 11 Sep 2017 21:38:13 +0900 Subject: [PATCH 2/2] Don't check for BB track mute state if we're playing a single pattern --- src/tracks/InstrumentTrack.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/tracks/InstrumentTrack.cpp b/src/tracks/InstrumentTrack.cpp index 3627bf34ece..48a1e4f1e06 100644 --- a/src/tracks/InstrumentTrack.cpp +++ b/src/tracks/InstrumentTrack.cpp @@ -157,7 +157,8 @@ InstrumentTrack::~InstrumentTrack() void InstrumentTrack::processAudioBuffer( sampleFrame* buf, const fpp_t frames, NotePlayHandle* n ) { // we must not play the sound if this InstrumentTrack is muted... - if( isMuted() || ( n && n->isBbTrackMuted() ) || ! m_instrument ) + if( isMuted() || ( Engine::getSong()->playMode() != Song::Mode_PlayPattern && + n && n->isBbTrackMuted() ) || ! m_instrument ) { return; }