зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1350912: Set min and start bandwidth according to b=TIAS, instead of only max r=drno
MozReview-Commit-ID: DH1rFn53sNN
This commit is contained in:
Родитель
41c4f44c15
Коммит
340f43be8a
|
@ -1409,6 +1409,15 @@ WebrtcVideoConduit::SelectBitrates(
|
|||
out_max = std::max(static_cast<int>(out_max * ((10 - (framerate / 2)) / 30)), cap);
|
||||
}
|
||||
|
||||
// Note: mNegotiatedMaxBitrate is the max transport bitrate - it applies to
|
||||
// a single codec encoding, but should also apply to the sum of all
|
||||
// simulcast layers in this encoding! So sum(layers.maxBitrate) <=
|
||||
// mNegotiatedMaxBitrate
|
||||
// Note that out_max already has had mPrefMaxBitrate applied to it
|
||||
out_max = MinIgnoreZero((int)mNegotiatedMaxBitrate, out_max);
|
||||
out_min = std::min(out_min, out_max);
|
||||
out_start = std::min(out_start, out_max);
|
||||
|
||||
if (mMinBitrate && mMinBitrate > out_min) {
|
||||
out_min = mMinBitrate;
|
||||
}
|
||||
|
@ -1419,13 +1428,6 @@ WebrtcVideoConduit::SelectBitrates(
|
|||
}
|
||||
out_start = std::max(out_start, out_min);
|
||||
|
||||
// Note: mNegotiatedMaxBitrate is the max transport bitrate - it applies to
|
||||
// a single codec encoding, but should also apply to the sum of all
|
||||
// simulcast layers in this encoding! So sum(layers.maxBitrate) <=
|
||||
// mNegotiatedMaxBitrate
|
||||
// Note that out_max already has had mPrefMaxBitrate applied to it
|
||||
out_max = MinIgnoreZero((int)mNegotiatedMaxBitrate, out_max);
|
||||
|
||||
MOZ_ASSERT(mPrefMaxBitrate == 0 || out_max <= mPrefMaxBitrate);
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче