Open dbuezas opened 1 year ago
I just realised the timeupdate
event may be perfect for exactly that.
// something like this:
videoElement.addEventListener("timeupdate", (event) => {
const redDotVisible = Math.round(video.currentTime)%2;
console.log(redDotVisible);
});
I'll make a PR later this week :)
Something like this:
Although maybe it is better to show a big loading indicator when the video stops updating instead? (blinking dot means video is getting updates)
Do you have any preference?
I accidentally lost the code (it wasn't much) when I upgraded webrtc. @AlexxIT I am not sure this is a "good" feature, maybe the loading indicator should be shown instead, or the connection should be watched and force reconnect. In any case, I can look into this if you think there is any value on this. Otherwise I won't, as I ended up fixing my flaky cameras by adding #async to all affected streams
One of my cameras will some times stop working for a couple of minutes, and this means I can't trust the image is live.
I'd really like to have an option to enable a blinking red dot or similar to indicate the video is running.