audioconvert: always allow peaks resampler

When we're using the peaks resampler, allow resampling, even when it is
disabled in the config.

The peaks resampler is just for GUI and would not really change the
signal, so we can allow this.
This commit is contained in:
Wim Taymans 2023-04-27 17:10:41 +02:00
parent ab0cee29dd
commit b262812643

View file

@ -1563,7 +1563,7 @@ static int setup_resample(struct impl *this)
out->format.info.raw.channels, out->format.info.raw.channels,
out->format.info.raw.rate); out->format.info.raw.rate);
if (this->props.resample_disabled && if (this->props.resample_disabled && !this->resample_peaks &&
in->format.info.raw.rate != out->format.info.raw.rate) in->format.info.raw.rate != out->format.info.raw.rate)
return -EPERM; return -EPERM;