Invoke the "resampling" filter only if the target sampling rate is really different from the file's current sampling rate.

This commit is contained in:
LoRd_MuldeR 2011-02-20 20:19:48 +01:00
parent 9e75a20158
commit c1cde1acd8

View File

@ -583,7 +583,10 @@ void ProcessingDialog::startNextJob(void)
if((m_settings->samplingRate() > 0) && !nativeResampling) if((m_settings->samplingRate() > 0) && !nativeResampling)
{ {
thread->addFilter(new ResampleFilter(SettingsModel::samplingRates[m_settings->samplingRate()])); if(SettingsModel::samplingRates[m_settings->samplingRate()] != currentFile.formatAudioSamplerate() || currentFile.formatAudioSamplerate() == 0)
{
thread->addFilter(new ResampleFilter(SettingsModel::samplingRates[m_settings->samplingRate()]));
}
} }
if((m_settings->toneAdjustBass() != 0) || (m_settings->toneAdjustTreble() != 0)) if((m_settings->toneAdjustBass() != 0) || (m_settings->toneAdjustTreble() != 0))
{ {