зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1843786 - webrtc: Filter out non-camera nodes, r=webrtc-reviewers,pehrsons,@webrtc-reviewers
This can be helpful in various situations, such as debugging with an unrestricted Pipewire socket or for downstream projects like B2G/Capyloon. Additionally it will help once we move from the camera portal to the more generic device portal. This is intended to get upstreamed but would be nice to carry downstream already. Original patch by Fabrice Desré <fabrice@desre.org> Upstream commit: a717c7ada811411e31bd7308168b4dbee5b956fa Differential Revision: https://phabricator.services.mozilla.com/D183650
This commit is contained in:
Родитель
4e50035ffb
Коммит
15bec067ae
|
@ -361,6 +361,10 @@ void PipeWireSession::OnRegistryGlobal(void* data,
|
|||
if (!spa_dict_lookup(props, PW_KEY_NODE_DESCRIPTION))
|
||||
return;
|
||||
|
||||
auto node_role = spa_dict_lookup(props, PW_KEY_MEDIA_ROLE);
|
||||
if (!node_role || strcmp(node_role, "Camera"))
|
||||
return;
|
||||
|
||||
that->nodes_.emplace_back(that, id, props);
|
||||
that->PipeWireSync();
|
||||
}
|
||||
|
|
|
@ -0,0 +1 @@
|
|||
We cherry-picked this in bug 1843786
|
Загрузка…
Ссылка в новой задаче