- From: guest271314 via GitHub <sysbot+gh@w3.org>
- Date: Sat, 27 Apr 2019 18:56:40 +0000
- To: public-webrtc@w3.org
guest271314 has just created a new issue for https://github.com/w3c/mediacapture-fromelement: == MediaStreamTrack does not dispatch "ended" event at Chromium when src of HTMLMediaElement is changed, Firefox does dispatch "ended" event; which implementation is correct? == At Chromium 73 `ended` event is not dispatched at `HTMLVideoElement` when `src` attribute is changed. `mute` event is dispatched at Chromium 73. Firefox 68 does dispatch `ended` event when `src` attribute of `HTMLVideoElement` is changed. Chromium bug https://bugs.chromium.org/p/chromium/issues/detail?id=957340. Relevant specifications: https://www.w3.org/TR/mediacapture-fromelement/ A captured MediaStreamTrack ends when playback ends (and the ended event fires) or when the track that it captures is no longer selected or enabled for playback. A track is no longer selected or enabled if the source is changed by setting the src or srcObject attributes of the media element. The steps in MediaStreamTrack.stop() are performed on the MediaStreamTrack when it ends. https://www.w3.org/TR/mediacapture-streams/ A MediaStreamTrack object is said to end when the source of the track is disconnected or exhausted. When a MediaStreamTrack track ends for any reason other than the stop() method being invoked, the User Agent MUST queue a task that runs the following steps: 1. If the track's readyState attribute has the value ended already, then abort these steps. 2. Set track's readyState attribute to ended. 3. Notify track's source that track is ended so that the source may be stopped, unless other MediaStreamTrack objects depend on it. 4. Fire a simple event named ended at the object. Related: https://github.com/w3c/mediacapture-fromelement/issues/77 Which implementation of the specifications is correct? Please view or discuss this issue at https://github.com/w3c/mediacapture-fromelement/issues/78 using your GitHub account
Received on Saturday, 27 April 2019 18:56:46 UTC