nativescript-audio icon indicating copy to clipboard operation
nativescript-audio copied to clipboard

Using seekTo while playing from url terminates the playback

Open zangarmarsh opened this issue 3 years ago • 1 comments

I want to play a mp3 file from a URL. Its size can be between 30MB and 200/300 MB. Playing/Pausing works fine, but every time I seek to a specific time, instead of pausing for buffering, it stops as if it had finished playing back the audio.

I tried either with a whole mp3 file and with a chunked one with several 206 responses, which works fine in the browser, but using nativescript-audio stops. The latter solution - the chunked one - would be the best one because of the aforementioned potential big size the mp3 might reach. Anyway, any solution would be very appreciated.

Thank you in advance for any tip/suggestion.

zangarmarsh avatar Apr 27 '21 22:04 zangarmarsh

according to the seekTo method, the track should not be stopped. But here's what I noticed for myself. I tried to make a player on Flutter today, seekTo works faster there. although NativeScript plugin uses native method for iOS:

https://developer.apple.com/documentation/avfoundation/avplayer/1385953-seek

Bezlepkin avatar Feb 28 '22 15:02 Bezlepkin