Returns RTCError for setting unimplemented RtpParameters.
We have a number of RtpParameters that aren't implemented. If a client
is setting these values it creates unexpected results when the value
doesn't do anything for them. This change incorporates returning the
correct error if the parameter is unimplemented.
It also changes the scale_resolution_down_by and scale_framerate_down_by
RtpEncodingParameters to rtc::Optionals because they aren't implemented.
This change is part of the effort to ship get/setParameters in Chrome.
Bug: webrtc:8772
Change-Id: I9797695e5116e6aeb3c02afddbf460b2a0d7d5ab
Reviewed-on: https://webrtc-review.googlesource.com/75421
Commit-Queue: Seth Hampson <shampson@webrtc.org>
Reviewed-by: Taylor Brandstetter <deadbeef@webrtc.org>
Reviewed-by: Steve Anton <steveanton@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23314}
diff --git a/media/base/fakemediaengine.h b/media/base/fakemediaengine.h
index e9a6bd6..50ef0a3 100644
--- a/media/base/fakemediaengine.h
+++ b/media/base/fakemediaengine.h
@@ -110,7 +110,7 @@
}
send_streams_.push_back(sp);
rtp_send_parameters_[sp.first_ssrc()] =
- CreateRtpParametersWithOneEncoding();
+ CreateRtpParametersWithEncodings(sp);
return true;
}
virtual bool RemoveSendStream(uint32_t ssrc) {