Index: webrtc/audio/audio_send_stream.cc |
diff --git a/webrtc/audio/audio_send_stream.cc b/webrtc/audio/audio_send_stream.cc |
index ad6366bc8095deebe830b33c9115cf77afe83adf..7e8e426ed9a2eeb42cc8d57ffcdc38c8d7960e88 100644 |
--- a/webrtc/audio/audio_send_stream.cc |
+++ b/webrtc/audio/audio_send_stream.cc |
@@ -101,12 +101,12 @@ AudioSendStream::~AudioSendStream() { |
void AudioSendStream::Start() { |
RTC_DCHECK(thread_checker_.CalledOnValidThread()); |
- if (config_.min_bitrate_kbps != -1 && config_.max_bitrate_kbps != -1) { |
- RTC_DCHECK_GE(config_.max_bitrate_kbps, config_.min_bitrate_kbps); |
+ if (config_.min_bitrate_bps != -1 && config_.max_bitrate_bps != -1) { |
+ RTC_DCHECK_GE(config_.max_bitrate_bps, config_.min_bitrate_bps); |
rtc::Event thread_sync_event(false /* manual_reset */, false); |
worker_queue_->PostTask([this, &thread_sync_event] { |
- bitrate_allocator_->AddObserver(this, config_.min_bitrate_kbps * 1000, |
- config_.max_bitrate_kbps * 1000, 0, true); |
+ bitrate_allocator_->AddObserver(this, config_.min_bitrate_bps, |
+ config_.max_bitrate_bps, 0, true); |
thread_sync_event.Set(); |
}); |
thread_sync_event.Wait(rtc::Event::kForever); |
@@ -249,10 +249,10 @@ uint32_t AudioSendStream::OnBitrateUpdated(uint32_t bitrate_bps, |
uint8_t fraction_loss, |
int64_t rtt) { |
RTC_DCHECK_GE(bitrate_bps, |
- static_cast<uint32_t>(config_.min_bitrate_kbps * 1000)); |
+ static_cast<uint32_t>(config_.min_bitrate_bps)); |
// The bitrate allocator might allocate an higher than max configured bitrate |
// if there is room, to allow for, as example, extra FEC. Ignore that for now. |
- const uint32_t max_bitrate_bps = config_.max_bitrate_kbps * 1000; |
+ const uint32_t max_bitrate_bps = config_.max_bitrate_bps; |
if (bitrate_bps > max_bitrate_bps) |
bitrate_bps = max_bitrate_bps; |