mirror of
https://github.com/jech/galene.git
synced 2024-11-10 02:35:58 +01:00
Disable simulcast on Firefox.
This commit is contained in:
parent
be4ae56c14
commit
485b0c1b85
1 changed files with 12 additions and 2 deletions
|
@ -1165,8 +1165,8 @@ function setUpStream(c, stream) {
|
||||||
};
|
};
|
||||||
|
|
||||||
let encodings = [];
|
let encodings = [];
|
||||||
if(t.kind === 'video') {
|
|
||||||
let simulcast = doSimulcast();
|
let simulcast = doSimulcast();
|
||||||
|
if(t.kind === 'video') {
|
||||||
let bps = getMaxVideoThroughput();
|
let bps = getMaxVideoThroughput();
|
||||||
encodings.push({
|
encodings.push({
|
||||||
rid: 'h',
|
rid: 'h',
|
||||||
|
@ -1179,11 +1179,21 @@ function setUpStream(c, stream) {
|
||||||
maxBitrate: simulcastRate,
|
maxBitrate: simulcastRate,
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
c.pc.addTransceiver(t, {
|
let tr = c.pc.addTransceiver(t, {
|
||||||
direction: 'sendonly',
|
direction: 'sendonly',
|
||||||
streams: [stream],
|
streams: [stream],
|
||||||
sendEncodings: encodings,
|
sendEncodings: encodings,
|
||||||
});
|
});
|
||||||
|
// Disable simulcast on Firefox
|
||||||
|
if(t.kind === 'video') {
|
||||||
|
let p = tr.sender.getParameters();
|
||||||
|
if(!p.encodings && simulcast) {
|
||||||
|
updateSettings({simulcast: 'off'});
|
||||||
|
reflectSettings();
|
||||||
|
p.encodings = [encodings[0]];
|
||||||
|
tr.sender.setParameters(p);
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// c.stream might be different from stream if there's a filter
|
// c.stream might be different from stream if there's a filter
|
||||||
|
|
Loading…
Reference in a new issue