A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://github.com/whatwg/html/issues/2754 below:

Throw exception when HTMLMediaElement’s defaultPlaybackRate or playbackRate are set to negative values if unsupported by the user agent. · Issue #2754 · whatwg/html · GitHub

cc @jernoble @foolip @mounirlamouri @cpearce

Setting a video's defaultPlaybackRate or playbackRate to a negative value does not have uniform behavior across the major browsers:

Browser defaultPlaybackRate = -1 playbackRate = -1 Chrome defaultPlaybackRate set to -1, plays at 1 playbackRate set to -1, plays at 1 Edge defaultPlaybackRate set to 1 playbackRate set to 1 Firefox NS_ERROR_NOT_IMPLEMENTED NS_ERROR_NOT_IMPLEMENTED Safari implements if set before load time implements

The spec does not currently specify the desired behavior in the case when the value set is negative.

While some non-negative values are unsupported by some implementations, they are usually approximated or capped, making the problem different (e.g. 10x as 5x, 0.001x as 0.1x). Negative values are uncommon, can’t be approximated, and unlikely to be used.

We propose to throw a RangeError when the value of playbackRate or defaultPlaybackRate is
negative.

edit: updated safari behavior per jernoble's comment.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4