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

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

Issue 1941343002: Manual cherry-pick of 'Propagate googScreencastMinBitrate constraint to webrtc.' (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2704
Patch Set: Rebase. 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 17a929a7f463b6abfbfcd64fe04afef4cd856b07..b7095b485acc64bea22be6d66c74e25e20a8ce22 100644
--- a/content/renderer/media/rtc_peer_connection_handler.cc
+++ b/content/renderer/media/rtc_peer_connection_handler.cc
@@ -327,12 +327,13 @@ void CopyConstraintsIntoRtcConfiguration(
configuration->suspend_below_min_bitrate = ConstraintToOptional(
constraints, &blink::WebMediaTrackConstraintSet::
googEnableVideoSuspendBelowMinBitrate);
- // 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;
- // }
+ 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