mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-04 13:30:12 -05:00
module: use resample.prefill for coupled streams
So that we always process one complete input buffer as an output buffer without keeping leftovers in the resampler.
This commit is contained in:
parent
31f9e18edb
commit
94336cb2c9
2 changed files with 6 additions and 0 deletions
|
|
@ -2200,6 +2200,8 @@ int pipewire__module_init(struct pw_impl_module *module, const char *args)
|
|||
pw_properties_setf(props, PW_KEY_NODE_LINK_GROUP, "filter-chain-%u-%u", pid, id);
|
||||
if (pw_properties_get(props, PW_KEY_NODE_VIRTUAL) == NULL)
|
||||
pw_properties_set(props, PW_KEY_NODE_VIRTUAL, "true");
|
||||
if (pw_properties_get(props, "resample.prefill") == NULL)
|
||||
pw_properties_set(props, "resample.prefill", "true");
|
||||
if (pw_properties_get(props, PW_KEY_NODE_DESCRIPTION) == NULL)
|
||||
pw_properties_setf(props, PW_KEY_NODE_DESCRIPTION, "filter-chain-%u-%u", pid, id);
|
||||
|
||||
|
|
@ -2217,6 +2219,7 @@ int pipewire__module_init(struct pw_impl_module *module, const char *args)
|
|||
copy_props(impl, props, PW_KEY_NODE_LATENCY);
|
||||
copy_props(impl, props, PW_KEY_NODE_VIRTUAL);
|
||||
copy_props(impl, props, PW_KEY_MEDIA_NAME);
|
||||
copy_props(impl, props, "resample.prefill");
|
||||
|
||||
parse_audio_info(impl->capture_props, &impl->capture_info);
|
||||
parse_audio_info(impl->playback_props, &impl->playback_info);
|
||||
|
|
|
|||
|
|
@ -523,6 +523,8 @@ int pipewire__module_init(struct pw_impl_module *module, const char *args)
|
|||
pw_properties_setf(props, PW_KEY_NODE_LINK_GROUP, "loopback-%u-%u", pid, id);
|
||||
if (pw_properties_get(props, PW_KEY_NODE_VIRTUAL) == NULL)
|
||||
pw_properties_set(props, PW_KEY_NODE_VIRTUAL, "true");
|
||||
if (pw_properties_get(props, "resample.prefill") == NULL)
|
||||
pw_properties_set(props, "resample.prefill", "true");
|
||||
|
||||
if ((str = pw_properties_get(props, "capture.props")) != NULL)
|
||||
pw_properties_update_string(impl->capture_props, str, strlen(str));
|
||||
|
|
@ -538,6 +540,7 @@ int pipewire__module_init(struct pw_impl_module *module, const char *args)
|
|||
copy_props(impl, props, PW_KEY_NODE_LATENCY);
|
||||
copy_props(impl, props, PW_KEY_NODE_VIRTUAL);
|
||||
copy_props(impl, props, PW_KEY_MEDIA_NAME);
|
||||
copy_props(impl, props, "resample.prefill");
|
||||
|
||||
if ((str = pw_properties_get(props, PW_KEY_NODE_NAME)) == NULL) {
|
||||
pw_properties_setf(props, PW_KEY_NODE_NAME,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue