mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2026-06-17 14:33:04 -04:00
module-rtp: allow dynamically enable or disable announcements
This commit is contained in:
parent
f935eb255c
commit
7f7fc2f77a
2 changed files with 10 additions and 0 deletions
|
|
@ -1376,6 +1376,9 @@ static int rule_matched(void *data, const char *location, const char *action,
|
||||||
|
|
||||||
session_new_announce(i->impl, i->node, props);
|
session_new_announce(i->impl, i->node, props);
|
||||||
}
|
}
|
||||||
|
else if (i->node && i->node->session && spa_streq(action, "deannounce-stream")) {
|
||||||
|
session_free(i->node->session);
|
||||||
|
}
|
||||||
return res;
|
return res;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -404,6 +404,13 @@ static void stream_props_changed(struct impl *impl, uint32_t id, const struct sp
|
||||||
}
|
}
|
||||||
pw_properties_setf(impl->stream_props, key, "%d", value_int);
|
pw_properties_setf(impl->stream_props, key, "%d", value_int);
|
||||||
items[n_items++] = SPA_DICT_ITEM_INIT(key, pw_properties_get(impl->stream_props, key));
|
items[n_items++] = SPA_DICT_ITEM_INIT(key, pw_properties_get(impl->stream_props, key));
|
||||||
|
} else if (spa_streq(key, "sess.sap.announce")) {
|
||||||
|
if (!value_str) {
|
||||||
|
pw_log_error("invalid sess.sap.announce");
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
pw_properties_setf(impl->stream_props, key, "%s", value_str);
|
||||||
|
items[n_items++] = SPA_DICT_ITEM_INIT(key, pw_properties_get(impl->stream_props, key));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue