Add functionality to set min/max bitrate per simulcast layer through RtpEncodingParameters.

Target bitrate is set to 0.75 of the max bitrate.

Bug: webrtc:9341, webrtc:8655
Change-Id: I9a8c8bb95bb1532d45f05578832418464452340e
Reviewed-on: https://webrtc-review.googlesource.com/79821
Commit-Queue: Åsa Persson <asapersson@webrtc.org>
Reviewed-by: Taylor Brandstetter <deadbeef@webrtc.org>
Reviewed-by: Rasmus Brandt <brandtr@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23676}
diff --git a/api/rtpparameters.h b/api/rtpparameters.h
index 0725ec7..e2405d3 100644
--- a/api/rtpparameters.h
+++ b/api/rtpparameters.h
@@ -401,14 +401,6 @@
   // bitrate. Currently this is implemented for the entire rtp sender by using
   // the value of the first encoding parameter.
   //
-  // TODO(webrtc.bugs.org/8655): Implement this per encoding parameter.
-  // Current implementation for a sender:
-  // The max bitrate is decided by taking the minimum of the first encoding
-  // parameter's max_bitrate_bps and the max bitrate specified by the sdp with
-  // the b=AS attribute. In the case of simulcast video, default values are used
-  // for each simulcast layer, and if there is some bitrate left over from the
-  // sender's max bitrate then it will roll over into the highest quality layer.
-  //
   // Just called "maxBitrate" in ORTC spec.
   //
   // TODO(deadbeef): With ORTC RtpSenders, this currently sets the total
@@ -417,7 +409,9 @@
   // fixed.
   rtc::Optional<int> max_bitrate_bps;
 
-  // TODO(asapersson): Not implemented.
+  // Specifies the minimum bitrate in bps for video.
+  // TODO(asapersson): Not implemented for ORTC API.
+  // TODO(asapersson): Not implemented for single layer.
   rtc::Optional<int> min_bitrate_bps;
 
   // TODO(deadbeef): Not implemented.
diff --git a/api/rtpsenderinterface.h b/api/rtpsenderinterface.h
index e933614..66267c7 100644
--- a/api/rtpsenderinterface.h
+++ b/api/rtpsenderinterface.h
@@ -57,6 +57,7 @@
   virtual RtpParameters GetParameters() = 0;
   // Note that only a subset of the parameters can currently be changed. See
   // rtpparameters.h
+  // The encodings are in increasing quality order for simulcast.
   virtual RTCError SetParameters(const RtpParameters& parameters) = 0;
 
   // Returns null for a video sender.