Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(786)

Unified Diff: content/renderer/media/rtc_peer_connection_handler.cc

Issue 1931813002: Propagate googScreencastMinBitrate constraint to webrtc's RTCConfiguration. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: content/renderer/media/rtc_peer_connection_handler.cc
diff --git a/content/renderer/media/rtc_peer_connection_handler.cc b/content/renderer/media/rtc_peer_connection_handler.cc
index 6b12cd114bd4f93f728e432140268deb66da2f77..f5aec5e191627aa153d2c99b63cd9887ab8352e2 100644
--- a/content/renderer/media/rtc_peer_connection_handler.cc
+++ b/content/renderer/media/rtc_peer_connection_handler.cc
@@ -301,14 +301,13 @@ void CopyConstraintsIntoRtcConfiguration(
&configuration->enable_rtp_data_channel)) {
configuration->enable_rtp_data_channel = false;
}
- // TODO: Special treatment for screencast min bitrate, since it's an integer.
- // if (FindConstraint(constraints,
- // MediaConstraintsInterface::kScreencastMinBitrate,
- // &configuration->screencast_min_bitrate, NULL)) {
- // configuration->override_screencast_min_bitrate = true;
- // }
- // Note: If an optional is not present, webrtc decides on its own
- // what the value should be.
+ int rate;
+ if (GetConstraintValueAsInteger(
+ constraints,
+ &blink::WebMediaTrackConstraintSet::googScreencastMinBitrate,
+ &rate)) {
+ configuration->screencast_min_bitrate = rtc::Optional<int>(rate);
+ }
configuration->combined_audio_video_bwe = ConstraintToOptional(
constraints,
&blink::WebMediaTrackConstraintSet::googCombinedAudioVideoBwe);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698