|
|
@@ -30,7 +30,6 @@ function createLocalTracks(streams, options) {
|
|
30
|
30
|
function RTC(room, options) {
|
|
31
|
31
|
this.room = room;
|
|
32
|
32
|
this.localStreams = [];
|
|
33
|
|
- //FIXME: we should start removing those streams.
|
|
34
|
33
|
//FIXME: We should support multiple streams per jid.
|
|
35
|
34
|
this.remoteStreams = {};
|
|
36
|
35
|
this.localAudio = null;
|
|
|
@@ -183,6 +182,12 @@ RTC.prototype.createRemoteStream = function (data, sid, thessrc) {
|
|
183
|
182
|
return remoteStream;
|
|
184
|
183
|
};
|
|
185
|
184
|
|
|
|
185
|
+RTC.prototype.removeRemoteStream = function (resource) {
|
|
|
186
|
+ if(this.remoteStreams[resource]) {
|
|
|
187
|
+ delete this.remoteStreams[resource];
|
|
|
188
|
+ }
|
|
|
189
|
+};
|
|
|
190
|
+
|
|
186
|
191
|
RTC.getPCConstraints = function () {
|
|
187
|
192
|
return RTCUtils.pc_constraints;
|
|
188
|
193
|
};
|