I want seamless playback multiple video contents. (HLS/using queueData)
preloading is works! but when the video changes, "loading" screen is displayed.
How i can playback without "loading" screen in CAF custom player?
Even though a PRELOAD
request starts buffering the next item of your queue to reduce the loading time for the next clip, playback is never 'seamless'.
Every time the actual LOAD
request comes in, the player will (by default) switch to the BUFFERING
state and display the associated UI until it's back to PLAYING
Google's UX guidelines for autoplay are quite clear how the UI should behave on the playback of queues - and you might want to consider adhering to that if you want to publish your app. That being said:
Take a look at your HTML - are you using the <cast-media-player></cast-media-player>
custom tags? You can use CSS to set the appearance of all states of the application - check the documentation for details.
--buffering-image
and --spinner-image
are the customizable elements that you can change here. Again: Those will always pop up when the player enters buffering state, so you will have to come up with something less disturbing than the spinner and default image: A black screen, maybe?
Also, you can not simply use CSS to get rid of those: When the playback is initialized and the queue is built, you most likely still want to show them - so totally disabling them is not an option. The tricky part is finding appropriate events to dis- and re-enable them:
Consider the MediaFinishedEvent to disable them, and maybe the PLAYER_LOAD_COMPLETE
event to restore them to their default value.
(The BUFFERING event might also work but was very unreliable when I tried to use it.)