New SourcePlayer

Work in progress; Sources now have play/pause and associated play functions. Media player can play all playable sources, and adapts to control a media player when possible. Selection of play groups (to finalize)
This commit is contained in:
Bruno
2021-05-19 00:31:37 +02:00
parent ba0e25a272
commit 19ba943075
26 changed files with 1107 additions and 77 deletions

View File

@@ -14,6 +14,18 @@ bool compare_depth (Source * first, Source * second)
return ( first->depth() < second->depth() );
}
bool notplayable (const Source *s) { return !s->playable(); }
SourceList playable_only (const SourceList &list)
{
SourceList pl = list;
pl.remove_if(notplayable);
return pl;
}
SourceList depth_sorted(const SourceList &list)
{
SourceList sl = list;