Closed sarusani closed 9 months ago
Hmm yeah I can reproduce this easily as well with the steps provided. I think that camera-streamer should probably be killing off inactive streams itself, but I have added a beforeunload
event listener to stop the streams myself. The timeout should still fire in all other cases, since it prevents constant load/unload cycle when switching tabs quickly for example.
Should be released as 1.0.1, and I'm going to put this plugin on the plugin repository imminently.
Because the
stopStream
function is using the timeout when called fromonWebcamVisibilityChange
, the camera-streamer stream is not properly stopped when the user closes the browser tab or browser. (I'm testing in Chrome)If the code in
onWebcamVisibilityChange
is changed toself.stopStream(true)
(force the stop) or the stream timeout is set to 0 in the settings, everything works as expected.How to reproduce: Check CPU usage with top.