audioconvert: add dither noise setting in dither struct

Move the noise setting in the dither struct so that it can be
handled separately.
Setup dither separately.
Set used cpu_flags in structures after setup.
This commit is contained in:
Wim Taymans 2022-06-28 10:52:31 +02:00
parent b7e26002be
commit b5e0151cc0
5 changed files with 33 additions and 20 deletions

View file

@ -396,10 +396,9 @@ int resample_native_init(struct resample *r)
build_filter(d->filter, d->filter_stride, n_taps, n_phases, scale);
d->info = find_resample_info(SPA_AUDIO_FORMAT_F32, r->cpu_flags);
if (SPA_UNLIKELY(!d->info))
{
if (SPA_UNLIKELY(d->info == NULL)) {
spa_log_error(r->log, "failed to find suitable resample format!");
return -1;
return -ENOTSUP;
}
spa_log_debug(r->log, "native %p: q:%d in:%d out:%d n_taps:%d n_phases:%d features:%08x:%08x",