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

Re: setting HTMLMediaElement volume and playbackRate attributes

From: Ian Hickson <ian@hixie.ch>
Date: Mon, 1 Dec 2008 10:44:24 +0000 (UTC)
To: Eric Carlson <eric.carlson@apple.com>, Philip Jägenstedt <philipj@opera.com>, Pierre-Olivier Latour <pol@apple.com>, Dave Singer <singer@apple.com>
Cc: HTML WG <public-html@w3.org>
Message-ID: <Pine.LNX.4.62.0812011029130.17414@hixie.dreamhostps.com>
On Sun, 23 Nov 2008, 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? [...] 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?

On Sun, 23 Nov 2008, Philip Jägenstedt wrote:
> playbackRate 0 is equivalent to pausing playback and in my opinion it 
> seems like a bad idea to have several ways to do that.

On Sun, 23 Nov 2008, Eric Carlson wrote:
> I agree that a "playbackRate == 0" is equivalent to "paused == true", 
> but isn't "volume == 0" is equivalent to "muted == true"?

On Mon, 24 Nov 2008, Philip Jägenstedt wrote:
> If an UI handles |playbackRate| < x by pausing I don't think anybody 
> would mind as long as x is small. But I suppose you're arguing that 
> setting playbackRate to 0 should simply be allowed. I don't feel 
> strongly about the issue, but if playbackRate 0 is allowed it should be 
> well defined which (if any) events it fired.

On Mon, 24 Nov 2008, Pierre-Olivier Latour wrote:
> I think it should just fire the regular "playbackrate changed" event, 
> like for any other value.
> Having 0.0 be allowed for both playback rate and volume makes things 
> consistent: "pause" is a conveniency override of playback rate, the same 
> way "muted" is one for "volume".

On Thu, 27 Nov 2008, Dave Singer wrote:
> I think if I am implementing a jog/shuttle controller, which allows the 
> rate to slide between +1 and -1, I don't want to worry if I happen to 
> sample it at zero and set the rate to that.  True, I am in the odd state 
> of playing at a rate of zero, but that's not so perceptibly different 
> from a rate of 0.00000001, and is not philosophically different from an 
> unmuted volume of zero.
> It's odd, but not harmful, so I don't see a reason to have the wrinkle.

I've updated the spec to allow the playback rate to be 0.0. Let me know if 
there's anything that is left undefined by this. I've tried to make it 
clear (no 'pause' events fire or anything like that).

Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'
Received on Monday, 1 December 2008 10:45:02 UTC

This archive was generated by hypermail 2.3.1 : Thursday, 29 October 2015 10:15:40 UTC