[whatwg] Serving up Theora <video> in the real world
Maciej Stachowiak
mjs at apple.com
Sat Jul 11 12:10:53 PDT 2009
On Jul 10, 2009, at 6:31 PM, Robert O'Callahan wrote:
> On Sat, Jul 11, 2009 at 5:23 AM, Aryeh Gregor <Simetrical+w3c at gmail.com
> > wrote:
> Maybe you'd try testing all the video types you support, and
> if one is "maybe" while another is "probably" you'd go with
> "probably"?
>
> Right. Or you might have plugin-based fallback you can use if you
> get "maybe". Other authors with no plugin-based fallback would go
> ahead if they get "maybe".
>
> Programmers expect binary logic,
> not ternary (look at the complaints about SQL's NULL).
>
> I agree. In the past I argued for two boolean functions.
>
> Anyway, it's a little late now to change canPlayType more than we
> just did. There is already deployed content checking for
> "probably"/"maybe".
If I were designing the API from scratch, I would have two functions,
"mightPlayType()" and "canDefinitelyPlayType()". That would make it
easier to write natural boolean expressions. However, I think the
current canPlayType() is good enough - the empty string pseudo-false
return should make it mostly ok to treat canPlayType as a boolean
method. Also, it's a change that we felt we could rush into Firefox
and Safari updates without undue risk, before the even more broken
version with the "no" return got locked in. To everyone proposing more
wide-ranging changes , this API is probably past the point where we
can freely change it any way we want.
Regards,
Maciej
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.whatwg.org/pipermail/whatwg-whatwg.org/attachments/20090711/f9bb5564/attachment-0002.htm>
More information about the whatwg
mailing list