InstrumentPlayHandle: do not process if InstrumentTrack is muted
While regular instruments were excluded from processing when muted
this did not happen for InstrumentPlayHandle-based instruments. Muting
for exampling tracks with VSTi's inside did not decrease CPU usage.
Checking whether related InstrumentTrack is muted before calling
Instrument::play() fixes this issue.
Closes #2857426.
(cherry picked from commit 6940d19969)
This commit is contained in:
@@ -95,6 +95,15 @@ bool Instrument::isFromTrack( const track * _track ) const
|
||||
|
||||
|
||||
|
||||
|
||||
bool Instrument::isMuted() const
|
||||
{
|
||||
return m_instrumentTrack->isMuted();
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
void Instrument::applyRelease( sampleFrame * buf, const notePlayHandle * _n )
|
||||
{
|
||||
const fpp_t frames = _n->framesLeftForCurrentPeriod();
|
||||
|
||||
Reference in New Issue
Block a user