RE: video.getContext

Well precisely. As I understand it the audio API is already context based, so a natural integration into HTML could be the result of AudioContext c = video.getContext("AudioContext"); we could of course mint an explicit attribute on the video API, and probably the document or Window API but the point is getContext is future proofed. For example if there was ever an AudioContext2. We don’t have to anticipate everything today.

I don't think the image filters WD handles time varying content (i.e. access to past frames), which might be required for some video processing. So having a filter script context along the same lines as the audio context would probably make some sense; CSS application notwithstanding.


-----Original Message-----
From: Kornel Lesiński [mailto:kornel@geekhood.net] 
Sent: 09 March 2012 12:48
To: public-html@w3.org
Subject: Re: video.getContext

On Fri, 09 Mar 2012 12:19:32 -0000, Sean Hayes <Sean.Hayes@microsoft.com>  
wrote:

> Changing the subject line so this doesn't get drawn into the DRM  
> argument. I don’t have a dog in that fight.
>
> However I do think that video.getContext("..") might be a great hook for  
> supporting media accessibility features that require DSP like  
> computations to be injected into the pipeline, such as enhance/decrease  
> contrast, video magnifier, moving audio into frequency bands that the  
> user can hear, removing all but the center channel and so on.

If those are useful features implementable in most UAs, why not add them  
to the video itself?


Or maybe we don't need to change the <video>, and CSS/SVG filters can be  
used instead:

https://dvcs.w3.org/hg/FXTF/raw-file/tip/filters/index.html



There's also audio API in the works:

https://dvcs.w3.org/hg/audio/raw-file/tip/webaudio/specification.html


I'm not familiar with Web Audio API, but on the surface it looks that it  
could be used with <video> and <audio> if HTMLMediaElement implemented  
AudioSourceNode interface. That would enable powerful filtering  
capabilities without other changes to video/audio elements.

-- 
regards, Kornel Lesiński

Received on Friday, 9 March 2012 14:32:13 UTC