lulop-k / kurento-rtsp2webrtc

This example shows how to transform a RTSP feed or an HTTP feed into a low latency WebRTC stream in a simple and seamless manner.
565 stars 155 forks source link

Is it possible to show loader during video stutter? #13

Open pratibhasharma5 opened 6 years ago

pratibhasharma5 commented 6 years ago

I need to show a loader while stream form ip cam is buffering as video quality degrades too much and video starts to stutter. I have googled a lot but found nothing. Please suggest any method to show loader before video stutter.

sampleref commented 6 years ago

PlayerEndpoint has event handler and media status check methods like,

https://doc-kurento.readthedocs.io/en/6.6.2/_static/langdoc/javadoc/org/kurento/client/PlayerEndpoint.html

https://doc-kurento.readthedocs.io/en/6.6.2/_static/langdoc/javadoc/org/kurento/client/MediaElement.html#isMediaFlowingOut(org.kurento.client.MediaType)

May be the client code can check periodically and update a queue or to web-socket as message, say like PLAYING, PAUSED etc... and you can show it on browser as loading, playing etc