- From: Martin Thomson <martin.thomson@gmail.com>
- Date: Tue, 14 Apr 2015 13:56:32 -0700
- To: Erik Lagerway <erik@hookflash.com>
- Cc: Peter Thatcher <pthatcher@google.com>, Jan-Ivar Bruaroey <jib@mozilla.com>, "public-webrtc@w3.org" <public-webrtc@w3.org>
On 14 April 2015 at 13:40, Erik Lagerway <erik@hookflash.com> wrote: >> 1. Why not just setTrack instead of replaceTrack? I don't mean to >> bikeshed, but we have lots of setters in the code, and no "replacers" >> in the API. > > > +1 > > In addition to Peter's comments, there are at least a few implementations > elsewhere that are well along now using setTrack. For us, changing it to > replaceTrack now would introduce a lot of work. I don't mean to be rude, but that's a bad reason to pick the wrong name. If setTrack() was an acceptable name, then we would be better off with: sender.track = theReplacement; As I understand it, replaceTrack can fail, asynchronously, if the underlying track is incapable of producing a compatible RTP stream. That might not be the case in current implementations, but those implementations are probably not using encoding cameras that can't change codecs.
Received on Tuesday, 14 April 2015 20:56:59 UTC