Android Live stream delay.
#1
Hello,

We are trying to use a couple of Android Kodi boxes to view a stream. the catch is that this needs to be real-time.
However we could not figure out how to stop Kodi from buffering a couple of seconds when joining the stream.
this cause the boxes to be "out of sync" with each other.
Does kodi support the function to display the video at the same time the packets are received.
or is this not implemented/technically possible.

We are using K1 android boxes in combination with ffmpeg.
the stream we are trying to read is compressed using h.265. and send over udp

Kodi version: 16.0
<advancedsettings>
<network>
<buffermode> 1 </buffermode>
<readbufferfactor> 1 </readbufferfactor>
<cachemembuffersize> 1048576 </cachemembuffersize>
</network>
</advancedsettings>

We have tried setting the buffermode to 3 and the readbufferfactor to 0. but this still causes kodi to buffer before sending video.

Thanks in advance
Reply
#2
That's the best possible for v16. I think v17 early alpha builds have lessened the time to play even further, or something to that extent. I don't know if this is something that will help out in your situation or not, but if you want to try, see nightly builds (wiki).
Reply
#3
Thanks for the quick reply,

Which settings in the advancedsettings would make the time Kodi buffers the smallest.
Even if it is not possible to eliminate the problem we would like to minimize the delay between them

And if we would switch to an rtp (instead of udp) stream. would that fix the problem or would that not have any impact on it what so ever.

Thanks in advance
Reply
#4
buffermode 3 is pretty much all you can do for v16, I think. As for protocol, that's not something I'm familiar with, sorry.
Reply
#5
Thanks for the fast reply,

I have one more question but i am not sure if i should post it in this thread or make a new one. whenever we stream we are having a lot of still images and artifacts on these boxes. when we log we get:

16:53:59 T:1912128160 DEBUG: CDVDPlayerVideo::CalcDropRequirement - hurry: 0
16:53:59 T:1912128160 DEBUG: CDVDPlayerVideo::CalcDropRequirement - hurry: 1
16:53:59 T:1912128160 DEBUG: CDVDPlayerVideo::CalcDropRequirement - hurry: 0
16:53:59 T:1912128160 DEBUG: CDVDPlayerVideo::CalcDropRequirement - hurry: 1
16:53:59 T:1912128160 DEBUG: CDVDPlayerVideo::CalcDropRequirement - hurry: 0
16:53:59 T:1912128160 DEBUG: CDVDPlayerVideo::CalcDropRequirement - hurry: 1
16:53:59 T:1912128160 DEBUG: CDVDPlayerVideo::CalcDropRequirement - hurry: 0
16:53:59 T:1912128160 DEBUG: CDVDPlayerVideo::CalcDropRequirement - hurry: 1

This repeats itself like 400 times.
Does this mean the hardware decoder is not good enough to keep up with the stream or is this something else.

Thanks in advance
Reply
#6
(2016-03-03, 15:07)siemen.meijssen Wrote: Kodi version: 16.0
<advancedsettings>
<network>
<buffermode> 1 </buffermode>
<readbufferfactor> 1 </readbufferfactor>
<cachemembuffersize> 1048576 </cachemembuffersize>
</network>
</advancedsettings>

We have tried setting the buffermode to 3 and the readbufferfactor to 0. but this still causes kodi to buffer before sending video.

Thanks in advance

What happens if you reduce the cachemembuffersize to something like, say, 10 or 2?
Reply
#7
Thanks for the reply,

Wouldn't that cause the application to write to its hard drive?

I will test that setup today to see if that fixes the problem,
Reply
#8
I have the same problem as Siemen trying to view an RTSP feed. Kodi will start out with a small lag or delay of 500 ms to 1 second (which is fine), but after a short while (5-10 minutes) this will have increased to 3-15 seconds (too long).

In order to view the stream I've created a .strm file that contains the URL. I read elsewhere about adding a space and live=true to the end of the URL, but this causes an error -- basically an invalid URL.

I'm experimenting with buffermode=0. I'll report what I find after testing.
Reply
#9
I am sorry i have not yet been able to test the setup.
Please let me know if you find anything kaared.
Reply
#10
I'm offsite right now, but I've been testing with http://vevoplaylist-live.hls.adaptive.le...leman.m3u8 and so far I'm not seeing any lag or buffering. I'm comparing what I see in Kodi to a copy of VLC running on my laptop. Kodi is maybe 2-300 ms ahead of VLC, which is great! I don't have access to the RTSP cameras from here so I'll need to test that later.

Siemen, if you have access to your RTSP sources, could you test buffermode=0 as well? I used a public RTSP source (http://vevoplaylist-live.hls.adaptive.le...leman.m3u8), but I think there's some kind of bandwidth issue or throttling policy in place -- really infrequent updates now (seconds in between) while yesterday it was really smooth, though grainy.
Reply

Logout Mark Read Team Forum Stats Members Help
Live stream delay.0