-
Notifications
You must be signed in to change notification settings - Fork 6k
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
Prepare progressive streams in MediaSource.prepare #4727
Comments
Looking at the "workaround" you proposed above, it looks like you already figured out the reason behind this behaviour. To show a multi-window time bar, the player has to know all durations of all items in the playlist. For traditional progressive streams (i.e. not DASH, HLS, or SmoothStreaming), the duration only becomes known after we actually started loading the stream. That means, we won't know all durations until the player at least started prebuffering all items at least once. You'll notice that the multi-window timebar works correctly after reaching the last item in the playlist. And also continues to work correctly after that. To fix/workaround the issue, you can do one of the following:
Finally, it's actually our intention to support immediate preparation of all playlist items until the duration is known to prevent the issue you describe here (and other issues). I mark this as an enhancement to track adding this feature. |
Yes, you are absolutely right about the lack of duration for that video, and that is the case for the third video, though I would argue whether it's an enhancement or a 100% bug on the player side.
|
It's an "enhancement" because it's something we'd like to implement but haven't done so far.
|
@tonihei Sorry for the delayed response. Yes, the workaround by wrapping each item in a |
@tonihei me too facing the same issue. would be really helpful if this enhancement ticket is taken on priority or if there any good workaround then it will be much appreciated. |
The |
Updated the title to better reflect what this issue is tracking. Once progressive streams support full preparation they can be used with a fully atomic ConcatenatingMediaSource as tracked by #4868 instead of the current |
I am using the functionality of
ConcatenatingMediaSource
together withsetShowMultiWindowTimeBar(true)
.My goal is to play multiple videos on the same window with one long seekbar, one period, and multi-window time bar of all videos in total.
When I concatenate 2 videos it works as expected - calculates the total length and enables seeking over the whole concatenated video, but I have noticed that in case of more
than 2 videos it will only concatenate the, but won't play them on the same window with all related support, so once video A ends B starts immediately and so on, which means that concatenating works without
multiWindowSupport
in this case.To reproduce that quickly in the demo app , I added the following code in
PlayerActivity
media.exolist.json
Go to menu and choose PlayLists >> Cats ->Dogs.
When using only two videos (dizzy.mp4 ,main-1280x720.mkv ) it works as expected, but in case of 3 videos as in my example,
setShowMultiWindowTimeBar(true)
does not work.In this example the combination above fails, but changing the third video to a different source passes.
Why is this happening? Am I missing any restrictions on the total length of the videos?
This happens while concatenating 5+ different length private unique videos in my app, while any random pairs of 2,3,4 videos work perfect until comes the last video and disables
MultiWindowTimeBar
. Added example above with videos from demo app for easy testing. All videos are not corrupted mp4 since I'm able to use each one of them in a pair with other.I am wondering what causes that?
Using version 2.8.4
Running on Android 6,7,8 , Galaxy S7,S8
Did the next workaround in demo app to test, all 3 videos came out as expected with correct time bar and a singular window.
PlaybackControlView
The text was updated successfully, but these errors were encountered: