Index: webrtc/video/vie_encoder.cc |
diff --git a/webrtc/video/vie_encoder.cc b/webrtc/video/vie_encoder.cc |
index adf8fe7eb4677a9e497b4292e8a7e244fe354b9f..b1b1114ae234ac3ff25ecdf994090100ce8eefe5 100644 |
--- a/webrtc/video/vie_encoder.cc |
+++ b/webrtc/video/vie_encoder.cc |
@@ -547,9 +547,16 @@ void ViEEncoder::EncodeVideoFrame(const VideoFrame& video_frame, |
<< ", texture=" << last_frame_info_->is_texture; |
} |
+ int64_t now_ms = clock_->TimeInMilliseconds(); |
if (pending_encoder_reconfiguration_) { |
ReconfigureEncoder(); |
+ } else if (!last_parameters_update_ms_ || |
+ now_ms - *last_parameters_update_ms_ >= |
+ vcm::VCMProcessTimer::kDefaultProcessIntervalMs) { |
+ video_sender_.UpdateChannelParemeters(rate_allocator_.get(), |
+ bitrate_observer_); |
} |
+ last_parameters_update_ms_.emplace(now_ms); |
if (EncoderPaused()) { |
TraceFrameDropStart(); |