mirror of
https://github.com/cookiengineer/audacity
synced 2025-08-06 15:19:29 +02:00
Prevent stereo->mono effects from causing a crash.
This commit is contained in:
parent
ffc41f0f10
commit
6868a318d9
@ -1749,7 +1749,14 @@ bool Effect::ProcessTrack(int count,
|
||||
left->Set((samplePtr) mOutBuffer[0], floatSample, outLeftPos, outputBufferCnt);
|
||||
if (right)
|
||||
{
|
||||
right->Set((samplePtr) mOutBuffer[1], floatSample, outRightPos, outputBufferCnt);
|
||||
if (chans >= 2)
|
||||
{
|
||||
right->Set((samplePtr) mOutBuffer[1], floatSample, outRightPos, outputBufferCnt);
|
||||
}
|
||||
else
|
||||
{
|
||||
right->Set((samplePtr) mOutBuffer[0], floatSample, outRightPos, outputBufferCnt);
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (isGenerator)
|
||||
@ -1799,7 +1806,14 @@ bool Effect::ProcessTrack(int count,
|
||||
left->Set((samplePtr) mOutBuffer[0], floatSample, outLeftPos, outputBufferCnt);
|
||||
if (right)
|
||||
{
|
||||
right->Set((samplePtr) mOutBuffer[1], floatSample, outRightPos, outputBufferCnt);
|
||||
if (chans >= 2)
|
||||
{
|
||||
right->Set((samplePtr) mOutBuffer[1], floatSample, outRightPos, outputBufferCnt);
|
||||
}
|
||||
else
|
||||
{
|
||||
right->Set((samplePtr) mOutBuffer[0], floatSample, outRightPos, outputBufferCnt);
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (isGenerator)
|
||||
|
Loading…
x
Reference in New Issue
Block a user