Red recording icon stays on

1,131 views
Skip to first unread message

Adrian Albu

unread,
Jan 16, 2017, 2:46:08 AM1/16/17
to discuss-webrtc

Hi,


I use react-recorder-redux (that uses react-recorder)


to record and use that for mic activity... (in a react component).


Anyway when I go on other page or back on unmount I kill all the tracks and call the stop


command on recorder (see snippet at bottom).


All good except the top tab browser still has the red recording icon on.


Cheers,
Adrian


PS: 

componentWillUnmount() {
this.props.recorderStop();
if (this.state.stream) {
this.state.stream.getTracks().forEach((track) => {
track.stop();
});
}
this.setState({
streamUrl: '',
stream: '',
});
this.videoElement.src = '';
}

Christoffer Jansson

unread,
Jan 16, 2017, 5:40:54 AM1/16/17
to discuss-webrtc
Hi,

A stream is alive somewhere, maybe you can add some logging to the recoderStop() call and see if it actually calls track.stop() (i.e is this.state.stream === true)? Are there more than one stream on the page?

What version of Chrome are you using?

/Chris

--

---
You received this message because you are subscribed to the Google Groups "discuss-webrtc" group.
To unsubscribe from this group and stop receiving emails from it, send an email to discuss-webrt...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/discuss-webrtc/a1d5034a-269f-4ddc-9729-8541d0b158f8%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
--
/Chris

Adrian Albu

unread,
Jan 17, 2017, 2:46:22 AM1/17/17
to discuss-webrtc
Hi,

I have 2 streams in 2 react components and for both I check if the stream is active and kill the tracks and debugging it for both it shows that it does call stop for each stream on one (only)

track, one is audio the other video only, only these 2 streams are and in different components each with its own onunmout.

I have Version 55.0.2883.95 (64-bit) of Chrome for Mac. I see it dispathces the recorder stop action, will debigg it now.

Cheers,
Adrian

Adrian Albu

unread,
Jan 23, 2017, 2:34:57 AM1/23/17
to discuss-webrtc


luni, 16 ianuarie 2017, 11:40:54 UTC+1, Christoffer Jansson a scris:

Adrian Albu

unread,
Jan 24, 2017, 7:34:54 AM1/24/17
to discuss-webrtc
Reply all
Reply to author
Forward
0 new messages