-
Notifications
You must be signed in to change notification settings - Fork 139
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Playback Skipping: Custom Resource Loader with file cache #2247
Playback Skipping: Custom Resource Loader with file cache #2247
Conversation
…arallel stream and download
Generated by 🚫 Danger |
…s resource loader
@SergioEstevao thanks for this PR! I made the test covering all the scenarios. This is what I found (but perhaps is expected):
not sure if it's an expected one. The episode continued to play.
|
It's expected to detect a small pause on playback when download is complete, because we are switching players and opening the downloaded file. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
✅ I tested streaming, downloading, and switching between episodes
|
App Name | ||
Build Number | pr2247-57e9a91 | |
Version | 7.75 | |
Bundle ID | au.com.shiftyjelly.podcasts.prototype | |
Commit | 57e9a91 | |
App Center Build | Pocket Casts - Prototype Builds #36 |
| 📘 Part of: #44 |
|:---:|
Fixes #44
Implements a custom
AVAssetResourceLoaderDelegate
that as a memory buffer and a file cache. Use the custom delegate to to handle parallel stream and downloads of episode files.The custom delegate is based on the code in this library, but adapted to our needs.
The PR is a bit large but as said above the majority of code comes from a separate library, and the core work is done on integrating it.
To test
streamAndCachePlayingEpisode
activeScenario 1 - Start streaming then start download
Scenario 2 - Start downloading then start playing the episode
Scenario 3 - Start downloading, the start playing, then cancel download
Scenario 4 - Start streaming on multiple episodes
DownloadManager export session: start exporting ...
in the logs.Scenario 5 - Auto-Downloads
Scenario 6 - Auto-Downloads and AutoPlay
Checklist
CHANGELOG.md
if necessary.