modules: always add the Props param

We always need to add the Props param because it contains the
debug.aec.wav-path key, which is always available, even when the AEC
implementation has no properties.

Also add the debug.aec.wav-path PropInfo.
This commit is contained in:
Wim Taymans 2023-12-11 12:02:58 +01:00
parent 658b624a83
commit 6cda416e71

View file

@ -962,9 +962,19 @@ static int setup_streams(struct impl *impl)
offsets[n_params++] = b.b.state.offset;
spa_audio_aec_enum_props(impl->aec, i, &b.b);
}
get_props_param(impl, &b.b);
}
offsets[n_params++] = b.b.state.offset;
spa_pod_builder_add_object(&b.b,
SPA_TYPE_OBJECT_PropInfo, SPA_PARAM_PropInfo,
SPA_PROP_INFO_name, SPA_POD_String("debug.aec.wav-path"),
SPA_PROP_INFO_description, SPA_POD_String("Path to WAV file"),
SPA_PROP_INFO_type, SPA_POD_String(impl->wav_path),
SPA_PROP_INFO_params, SPA_POD_Bool(true));
offsets[n_params++] = b.b.state.offset;
get_props_param(impl, &b.b);
for (i = 0; i < n_params; i++)
params[i] = spa_pod_builder_deref(&b.b, offsets[i]);