mirror of
https://gitlab.freedesktop.org/pipewire/pipewire.git
synced 2025-11-01 22:58:50 -04:00
Improve negotiation
Try to link ports based on compatible formats Add methods to filter formats.
This commit is contained in:
parent
1370fafd5b
commit
df86fcec10
12 changed files with 229 additions and 95 deletions
|
|
@ -305,3 +305,19 @@ fallback:
|
|||
|
||||
return res;
|
||||
}
|
||||
|
||||
SpaResult
|
||||
spa_format_audio_filter (SpaFormatAudio *format,
|
||||
const SpaFormat *filter)
|
||||
{
|
||||
SpaFormatAudio af;
|
||||
SpaResult res;
|
||||
|
||||
if (filter == NULL)
|
||||
return SPA_RESULT_OK;
|
||||
|
||||
if ((res = spa_format_audio_parse (filter, &af)) != SPA_RESULT_OK)
|
||||
return res;
|
||||
|
||||
return SPA_RESULT_NOT_IMPLEMENTED;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -637,3 +637,19 @@ fallback:
|
|||
|
||||
return res;
|
||||
}
|
||||
|
||||
SpaResult
|
||||
spa_format_video_filter (SpaFormatVideo *format,
|
||||
const SpaFormat *filter)
|
||||
{
|
||||
SpaFormatVideo vf;
|
||||
SpaResult res;
|
||||
|
||||
if (filter == NULL)
|
||||
return SPA_RESULT_OK;
|
||||
|
||||
if ((res = spa_format_video_parse (filter, &vf)) != SPA_RESULT_OK)
|
||||
return res;
|
||||
|
||||
return SPA_RESULT_NOT_IMPLEMENTED;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue