harmonwood / capacitor-video-player

Capacitor Video Player Plugin
MIT License
112 stars 46 forks source link

java.lang.IllegalArgumentException: playPosition can not be negative when playing a live stream #146

Open waltercruz opened 7 months ago

waltercruz commented 7 months ago

Hi! Sometimes, when I stream a live stream (HLS) to chromecast, I get a 'playPosition can not be negative when playing a live stream' Exception.

If I edit the FullScreenExoPlayerFragment.java and replace

castPlayer.setMediaItem(mediaItem, videoPosition);

with

castPlayer.setMediaItem(mediaItem);

on onCastSessionAvailable (currently on line 1331)

then this bug is mostly gone.

jepiqueau commented 7 months ago

@PhantomPainX Can you deal with that one

PhantomPainX commented 7 months ago

@jepiqueau roger that 👍🏻