Re: DTMF API completed

I read Martin's comments and that's not what I get at all from his 
comments. Maybe I misunderstand what he's saying though.

As for Media Capture - I don't see how it perverts anything? Media 
Capture does not return that type of object and is unrelated.

I don't like dtmf objects being needlessly referenced into the main 
object as it therefor cannot be ignored. It should be "yet another 
extension". This is really a specialized type of audio track in many ways.

You can add a DTMF event handler even if it a separate object. You add 
the event handler to the dtmf media stream track object rather than the 
rtc connection. There's no issue or conflict.



> Iñaki Baz Castillo <mailto:ibc@aliax.net>
> 11 September, 2013 10:35 AM
> 2013/9/11 Robin Raymond <robin@hookflash.com <mailto:robin@hookflash.com>>
>
> I like more the vision of Martin, in which DTMF is just an adicional 
> codec over an existing audio track (see mails below). Having a 
> specialized MediaStreamTrack was the previous attempt (before last 
> commit) in which we had RTCDTMFTrack.
>
> Now let's assume such an approach based on RTCDTMFTrack which is a 
> kind of MediaStreamTrack. This is problematic as we do not want to 
> pervert the MediaCapture MediaStreamTrack, do we? Do we want 
> MediaStream.getDtmfTracks() method?
>
> In our previous approach (before last commit) RTCDTMFTrack was not a 
> kind of MediaStreamTrack at all, but a class totally separated from 
> MediaCapture (this is, you cannot add a RTCDTMFTrack into a 
> MediaStream and so on).
>
> I strongly like the current approach in which DTMF is just a separate 
> codec within an audio track ("dtmf" codec) which means that the 
> RTCTrackDescription of an audio track includes an additional "dtmf" 
> codec (along with a "opus" or "g711" codec).
>
>
> > There's absolutely no reason IMHO to have the DTMF object have any 
> methods in any of the core object.
>
> We need a way to add a DTMF hander. We can add a method to 
> RTCConnection (as we do now) or we can pervert the MediaCapture 
> MediaStream / MediaStreamTrack with this legacy and artificial stuff.
>
> We also need a way to receive DTMF. Yes, we could get rid of the 
> RTCConnection.onadddtmfhandler event, and instead force the user to 
> inspect the received RTCTrackDescription and, in case it is an audio 
> track with "dtmf" codec, then create a RTCDTMFHandler instance by 
> itself. I don't see too much benefit on that.
>
>
> -- 
> Iñaki Baz Castillo
> <ibc@aliax.net <mailto:ibc@aliax.net>>

Received on Wednesday, 11 September 2013 15:14:52 UTC