Detect host offline rendering state and if active, use the stretchsource directly instead of the thread buffered source
This commit is contained in:
parent
d900572506
commit
7238c71e66
@ -118,6 +118,8 @@ void PaulstretchpluginAudioProcessorEditor::timerCallback(int id)
|
||||
String(processor.getStretchSource()->getFFTSize());
|
||||
if (processor.m_abnormal_output_samples > 0)
|
||||
infotext += " " + String(processor.m_abnormal_output_samples) + " invalid sample values";
|
||||
if (processor.isNonRealtime())
|
||||
infotext += " (offline rendering)";
|
||||
m_info_label.setText(infotext, dontSendNotification);
|
||||
}
|
||||
if (id == 2)
|
||||
|
@ -413,9 +413,15 @@ void PaulstretchpluginAudioProcessor::processBlock (AudioSampleBuffer& buffer, M
|
||||
m_stretch_source->setFreezing(getParameter(cpi_freeze));
|
||||
m_stretch_source->setPaused(getParameter(cpi_pause_enabled));
|
||||
m_stretch_source->setProcessParameters(&m_ppar);
|
||||
|
||||
AudioSourceChannelInfo aif(buffer);
|
||||
m_buffering_source->getNextAudioBlock(aif);
|
||||
if (isNonRealtime())
|
||||
{
|
||||
m_stretch_source->getNextAudioBlock(aif);
|
||||
}
|
||||
else
|
||||
{
|
||||
m_buffering_source->getNextAudioBlock(aif);
|
||||
}
|
||||
for (int i = 0; i < buffer.getNumChannels(); ++i)
|
||||
{
|
||||
for (int j = 0; j < buffer.getNumSamples(); ++j)
|
||||
|
@ -111,6 +111,7 @@ public:
|
||||
void timerCallback(int id) override;
|
||||
double getSampleRateChecked();
|
||||
int m_abnormal_output_samples = 0;
|
||||
|
||||
private:
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user