[mediacapture-main] Clarification needed on HTMLMediaElement attributes that carry over (#599)

Pehrsons has just created a new issue for https://github.com/w3c/mediacapture-main:

== Clarification needed on HTMLMediaElement attributes that carry over ==
Imagine the following code:

```
let v = document.createElement("video");

v.playbackRate = 0.5;
console.log(v.playbackRate);

v.srcObject = new MediaStream();
console.log(v.playbackRate);

v.srcObject = null;
console.log(v.playbackRate);
```

Per the spec the first two logged lines will be `0.5` and `1`, respectively. But what should be returned the third time? Does it keep `1`, or is it reset to `0.5` which it had before the `MediaStream` was assigned?

The same applies to the `defaultPlaybackRate` and `preload` attributes.

The spec also says to not fire `ratechange` on setting `playbackRate` or `defaultPlaybackRate`. That makes sense since the value doesn't change. But shouldn't `ratechange` reasonably be fired if the attribute was changed to `1` when the `MediaStream` was assigned, and (possibly) when it changes back after being unassigned?

Please view or discuss this issue at https://github.com/w3c/mediacapture-main/issues/599 using your GitHub account

Received on Tuesday, 28 May 2019 08:00:37 UTC