Baseflow / Baseflow/XamarinMediaManager
Queue/Playlist Support Just in Time IMediaItem over Propritary WebService
- Dominant language
- C#
- Stars
- 763
- Forks
- 299
- PR merge metrics
- No merged PRs in 30d
Description
## 🚀 Feature Requests
In my App I have song playlists, but the songs in the playlists are not yet downloaded, they just get downloaded when the songs are played or about to be played. The Song Metadata I have already.
I pass URLs to the Media Items since I receive the Audio files over a proprietary Webservice.
Now so far I was always playing a song and when it finished (using IPlaybackManager.MediaItemFinished), played the next Song.
The Problem is that this ways Next and Previous song buttons on the Android UI do not work, as well as the Before and After Buttons on Bluetooth Speaks/Receivers.
Now it would be nice to Download the Files just when they are required. (The Metadata Info I could actually already provide).
As a workarround I just thought building a wrapper arround the currently used IMediaPlayer and override
```
Task Play(IMediaItem mediaItem);
Task Play(IMediaItem mediaItem, TimeSpan startAt, TimeSpan? stopAt = null);
```
Only issue I saw so far is that the Android QueryDataAdapter immidatly calls ToMediaSource() for all Queue Items to pass them to ExoPlayer, so it seems I need to resolve to adding the previous and next item to the Replay Queue, that the Buttons Work...
It would be nice if there was a native feature for that.
Also maybe Just in Time Streaming of Media files when they are about to be played.
### Platforms affected (mark all that apply)
- [X] :iphone: iOS
- [X] :robot: Android
- [ ] :checkered_flag: WPF
- [X] :earth_americas: UWP
- [ ] :apple: MacOS
- [ ] :tv: tvOS
- [ ] :monkey: Xamarin.Forms
Contributor guide
Assessment
This issue has not been assessed yet.