W3C home > Mailing lists > Public > public-html@w3.org > November 2008

Re: setting HTMLMediaElement volume and playbackRate attributes

From: Philip Jägenstedt <philipj@opera.com>
Date: Sun, 23 Nov 2008 21:27:55 +0100
To: Eric Carlson <eric.carlson@apple.com>
Cc: HTML WG <public-html@w3.org>
Message-Id: <1227472075.15537.7.camel@localhost>

playbackRate 0 is equivalent to pausing playback and in my opinion it
seems like a bad idea to have several ways to do that.

Philip

On Sun, 2008-11-23 at 10:20 -0800, Eric Carlson wrote:
> 
>    Why is it OK to set the volume to zero but it is an error to set  
> the playback rate to zero?
> 
>    The spec says the following about "volume" [1]:
> 
> 	The volume attribute must return the playback volume of any audio  
> portions of the media element,
> 	in the range 0.0 (silent) to 1.0 (loudest).
> 
>    It says the following about "playbackRate" [2]:
> 
> 	The attribute is mutable, but on setting, if the new value is 0.0, a  
> NOT_SUPPORTED_ERR exception
> 	must be raised instead of the value being changed.
> 
>    How is this helpful? Further, why is it OK to set the rate to  
> 0.00001 but an error to set it to 0 when there is no real difference  
> between the two from the user's perspective?
> 
> eric
> 
> [1] http://www.whatwg.org/specs/web-apps/current-work/multipage/video.html#dom-media-volume
> [2] http://www.whatwg.org/specs/web-apps/current-work/multipage/video.html#dom-media-playbackrate
> 
-- 
Philip Jägenstedt
Opera Software
Received on Sunday, 23 November 2008 20:28:41 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 9 May 2012 00:16:26 GMT