google / ExoPlayer

This project is deprecated and stale. The latest ExoPlayer code is available in https://github.com/androidx/media
https://developer.android.com/media/media3/exoplayer
Apache License 2.0
21.69k stars 6.01k forks source link

HLS Stream freezes after a few seconds #2992

Closed krok55 closed 7 years ago

krok55 commented 7 years ago

Hello,

Description: Picture freezes after several seconds. The sound continues in the background. I believe that this issue has a different root-cause than other problems with a similar symptom (such as #659, #695, #1027 and more)

Technical Information: ExoPlayer Version: 1.5.16 Android: 5.1 Hardware: MXQ Pro (Rockchip based, Amlogic S905, Quad Core)

I've added a printing in HlsSampleSource.readData() and found out that after a few seconds (and sometimes right in the beginning) I get some abnormal sample timeTag values. For example:

Read data for track=2 with timeTag=6554635000 with pos=0 Read data for track=2 with timeTag=507000 with pos=0 Read data for track=2 with timeTag=387000 with pos=0 ...

I highly suspect that this is parsing issue. I.e. that the parsing mechanism of the *.ts fails sometimes to determine the correct timeTag value. I can base my suspicion on the following:

  1. The given stream plays perfectly on other players such as VLC and some other embedded flash players
  2. The origin of the stream is good and reliable
  3. The "abnormal" timeTag sample occurs once in a while and it always contains very large long values (some times negative). It looks like if some value was added to the parsed timeTag, or perhaps this is a result of bad casting.

Input Data: The problematic *.m3u8 stream was sent to dev.exoplayer@gmail.com

I would appreciate some help on this.

Thanks!

ojw28 commented 7 years ago

Significant improvements were made to the HLS implementation in ExoPlayer V2. It's quite a lot more robust than the V1 implementation. Please test with a recent V2 build instead, and let us know if there's still an issue.

ojw28 commented 7 years ago

Marking wontfix (obsolete) as this is about ExoPlayer V1.