[Issue] Issue with player.isPlaying api , where this api is giving false when content is playing

Hi Support Team

I am facing one issue in which player.isPlaying API is giving wrong value {false} event content is playing

Steps

  1. Play content with any HLS URL
  2. Play till the end of the content
  3. When content end - IsPlaying APi is giving correct value {false}
    4.Use Seek method to player.seek(0.0) , content starts playing , but we are getting the incorrect value isPlaying to false

Please help me to fix this issue

Hi @iamvivekprox,

on which platform do you see this behaviour?


Regardless of the platform, you do not need to manually seek back to start (player.seek(time: 0)) after playback is finished. Replay will be initiated automatically by just calling player.play().

Hi @davidsteinacher

I am using in android stack , I am using kotlin language

In my requirement , I have a button of pressing play from start where we seek content at 0.0 by using player.seek(0.0)

I have one button , Play/Pause Button where I am calling play and pause method

I am updating UI on callback , I am getting incorrect status of using player.isPlaying API on this scenario .

Please provide another way how to fix it

Hi @iamvivekprox,
I managed to reproduce the described behaviour and it turns out to be a bug in the player. We are tracking this internally and will let you know when a fix is available.

In the mean time there are two workarounds that come to my mind:

  1. don’t seek to the start of the source on playback finished but rather use Player.play() to replay the source
  2. keep track of the playback state externally

I hope this helps.

Best regards, Lukas

Hi @Lukas,

Thank you for your valuable feedback.

I tried a workaround to mitigate this issue and this is working fine as of now
. I am calling the play() API just after seek(0.0) (to play from the start) when the content has ended.

In the normal case, while content is playing and the user wants to play from the start, I call play() and then seek(0.0). So far, no side effects have been observed.

We will wait for next release of bitmovin so that i can intigrate in application

Regards,
Vivek Kumar

1 Like