2016-10-27, 11:06
Hello!
So I've been having this problem with Kodi when I watch online TV streams with Retrospect. At some points during a stream, apparently randomly but almost always at least once during a 30-min episode, the playback freezes, apparently to buffer. Now, a little buffering isn't something that would annoy me all that much if it wasn't for the fact that when resuming, the video skips ahead the same amount of time that Kodi spent buffering. It simply skips part of the show. Which is incredibly annoying.
When this happened, these messages appeared in the logfile. The stream froze at 18:40:12 for a few seconds before skipping ahead. (Full kodi and retrospect debug logs)
According to this thread the problem can be caused by the network, but even if so, I don't see why Kodi would skip ahead over parts of the stream.
I tried to increase the size of the cache by setting the following settings in advancedsettings.xml
but no luck. I opened the same stream (copied URI from log) in VLC and it played perfectly.
According to this thread it might have something to do with the stream format (.m3u8 HLS) being handled by ffmpeg directly and ffmpeg is the one at fault because of some bug in its libraries, but apparently it was fixed and the thread is quite old so one would think that the fix would be pulled up to by now. Is this not the case?
Any thoughts on the cause of this is appreciated, as I said it's incredibly infuriating with these intermittent skips.
So I've been having this problem with Kodi when I watch online TV streams with Retrospect. At some points during a stream, apparently randomly but almost always at least once during a 30-min episode, the playback freezes, apparently to buffer. Now, a little buffering isn't something that would annoy me all that much if it wasn't for the fact that when resuming, the video skips ahead the same amount of time that Kodi spent buffering. It simply skips part of the show. Which is incredibly annoying.
When this happened, these messages appeared in the logfile. The stream froze at 18:40:12 for a few seconds before skipping ahead. (Full kodi and retrospect debug logs)
Code:
18:40:04 T:140031993419520 DEBUG: ffmpeg[7F5BBD399700]: [hls,applehttp] HLS request for url 'http://tv4play-i.akamaihd.net/i/mp4root/2016-09-04/pid200015271(3503713_,T3MP445,T3MP435,T3MP425,T3MP415,T3MP48,T3MP43,T3MP41
30,).mp4.csmil/segment23_0_av.ts', offset 0, playlist 0
18:40:04 T:140031993419520 DEBUG: ffmpeg[7F5BBD399700]: Using network protocols without global network initialization. Please use avformat_network_init(), this will become mandatory later.
18:40:04 T:140031993419520 DEBUG: ffmpeg[7F5BBD399700]: [http] No trailing CRLF found in HTTP header.
18:40:04 T:140031993419520 DEBUG: ffmpeg[7F5BBD399700]: Using network protocols without global network initialization. Please use avformat_network_init(), this will become mandatory later.
18:40:12 T:140031326336768 WARNING: CDVDMessageQueue(audio)::Get - asked for new data packet, with nothing available
18:40:12 T:140031334729472 WARNING: CDVDMessageQueue(video)::Get - asked for new data packet, with nothing available
18:40:13 T:140031334729472 INFO: CDVDPlayerVideo - Stillframe detected, switching to forced 25.000000 fps
18:40:13 T:140031334729472 DEBUG: CPullupCorrection: pattern lost on diff 200000.000000, number of losses 1
18:40:14 T:140031993419520 DEBUG: CDVDPlayer::SetCaching - caching state 1
18:40:14 T:140031993419520 DEBUG: CDVDPlayer::HandleMessages - player started 1
18:40:14 T:140031993419520 DEBUG: CDVDPlayer::HandleMessages - player started 2
18:40:14 T:140031993419520 DEBUG: ffmpeg[7F5BBD399700]: [NULL] Current profile doesn't provide more RBSP data in PPS, skipping
18:40:14 T:140032965740608 DEBUG: ------ Window Init (DialogSeekBar.xml) ------
18:40:15 T:140031993419520 DEBUG: ffmpeg[7F5BBD399700]: [NULL] Current profile doesn't provide more RBSP data in PPS, skipping
18:40:15 T:140031993419520 DEBUG: Previous line repeats 1 times.
18:40:15 T:140031993419520 DEBUG: CDVDPlayer::SetCaching - caching state 4
18:40:15 T:140031334729472 INFO: CDVDPlayerVideo - Stillframe left, switching to normal playback
18:40:15 T:140031326336768 NOTICE: CDVDPlayerAudio::OutputPacket skipping a packets of duration 21
18:40:15 T:140031993419520 NOTICE: Previous line repeats 92 times.
18:40:15 T:140031993419520 DEBUG: CDVDPlayer::SetCaching - caching state 0
18:40:15 T:140031993419520 DEBUG: ffmpeg[7F5BBD399700]: [hls,applehttp] HLS request for url 'http://tv4play-i.akamaihd.net/i/mp4root/2016-09-04/pid200015271(3503713_,T3MP445,T3MP435,T3MP425,T3MP415,T3MP48,T3MP43,T3MP4130,).mp4.csmil/segment24_0_av.ts', offset 0, playlist 0
18:40:15 T:140031993419520 DEBUG: ffmpeg[7F5BBD399700]: Using network protocols without global network initialization. Please use avformat_network_init(), this will become mandatory later.
18:40:15 T:140031993419520 DEBUG: ffmpeg[7F5BBD399700]: [http] No trailing CRLF found in HTTP header.
18:40:15 T:140031993419520 DEBUG: ffmpeg[7F5BBD399700]: Using network protocols without global network initialization. Please use avformat_network_init(), this will become mandatory later.
18:40:15 T:140031326336768 NOTICE: CDVDPlayerAudio::OutputPacket skipping a packets of duration 21
18:40:15 T:140031326336768 NOTICE: Previous line repeats 1 times.
18:40:15 T:140031326336768 DEBUG: CDVDPlayerAudio::HandleSyncError - average error -19324.816748 below threshold of 50000.000000
18:40:15 T:140032965740608 DEBUG: ------ Window Deinit (DialogSeekBar.xml) ------
18:40:15 T:140031993419520 DEBUG: ffmpeg[7F5BBD399700]: [NULL] Current profile doesn't provide more RBSP data in PPS, skipping
According to this thread the problem can be caused by the network, but even if so, I don't see why Kodi would skip ahead over parts of the stream.
I tried to increase the size of the cache by setting the following settings in advancedsettings.xml
Code:
<network>
<buffermode>1</buffermode>
<cachemembuffersize>419430400</cachemembuffersize>
<readbufferfactor>20.0</readbufferfactor>
</network>
but no luck. I opened the same stream (copied URI from log) in VLC and it played perfectly.
According to this thread it might have something to do with the stream format (.m3u8 HLS) being handled by ffmpeg directly and ffmpeg is the one at fault because of some bug in its libraries, but apparently it was fixed and the thread is quite old so one would think that the fix would be pulled up to by now. Is this not the case?
Any thoughts on the cause of this is appreciated, as I said it's incredibly infuriating with these intermittent skips.