You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@cordova.apache.org by GitBox <gi...@apache.org> on 2021/08/06 17:38:56 UTC

[GitHub] [cordova-plugin-media] pslyman edited a comment on issue #309: [iOS] Stalled Playback

pslyman edited a comment on issue #309:
URL: https://github.com/apache/cordova-plugin-media/issues/309#issuecomment-894408559


   Thanks for the reply! 
   
   The app in question is one that has one server source, but many streaming audio tracks, kind of like a music streaming service. I am using remote files, including `206 Partial Content` delivery in parts as it should It works perfectly on web, and Android. I've tried many other audio files and they play fine, with a rare few refusing to play at all. Each track has a defined length, and is set in size.
   
   To add detail to this, I've been able to narrow down some things. First, if I do `media.pause()` before `media.seekTo()`, then resume after, seeking won't give me that `playback stalled` error. Additionally, after giving my media object a URL, if I put `media.play()` on a timeout of 150-300ms, it won't give me that error either. However, this seems to be only showing a symptom of the problem. 
   
   For instance I'll get `1: MEDIA_ERR_ABORTED` `AVPlayerItem cannot service a seek request with a completion handler until its status is AVPlayerItemStatusReadyToPlay`. That happens if I try to use a scrubber after trying to load the track, revealing that AVPlayer rather doesn't have enough buffer, or something else. The track in question is about 5-6 minutes, and 7-8MB in size. This only shows up if the track refused to play to begin with. 
   
   Is there a way to tell the plugin to wait for `AVPlayerItemStatusReadyToPlay`, or should it already? Will the player refuse to play a track if it's too big (bitrate)? I'm not sure if there's a timeout on waiting for a buffer, or a hard limit on size for AVPlayer. I'm having a difficult time narrowing this down. 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@cordova.apache.org
For additional commands, e-mail: issues-help@cordova.apache.org