protocol-simple: add per stream properties and formats

Add capture.props and playback.props to configure the created streams
with arbitrary properties.

Improve format parsing, make it possible to have different formats peer
stream.

Improve some of the property handling.

This can now also be used to upload a stream to a snapcast server, add
an example of this to the docs.
This commit is contained in:
Wim Taymans 2024-05-14 17:30:05 +02:00
parent 37224ac84c
commit 78fbe6f750
2 changed files with 219 additions and 95 deletions

View file

@ -958,7 +958,7 @@ int pipewire__module_init(struct pw_impl_module *module, const char *args)
if (impl->info.rate != 0 &&
pw_properties_get(props, PW_KEY_NODE_RATE) == NULL)
pw_properties_setf(props, PW_KEY_NODE_RATE,
"1/%u", impl->info.rate),
"1/%u", impl->info.rate);
copy_props(impl, props, PW_KEY_NODE_RATE);