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

Unified Diff: remoting/protocol/webrtc_transport.cc

Issue 2782523003: [Remoting Host] Supporting WebRTC VP9 streaming (Closed)
Patch Set: Fix Feedback Created 3 years, 9 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 | « remoting/protocol/webrtc_frame_scheduler_simple.cc ('k') | remoting/protocol/webrtc_video_stream.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/protocol/webrtc_transport.cc
diff --git a/remoting/protocol/webrtc_transport.cc b/remoting/protocol/webrtc_transport.cc
index 693521c382bfca0ed2257de473743103d62eaaa0..fbacd2c418048397a49b83abb67c1c7f25da40c2 100644
--- a/remoting/protocol/webrtc_transport.cc
+++ b/remoting/protocol/webrtc_transport.cc
@@ -71,13 +71,17 @@ void UpdateCodecParameters(SdpMessage* sdp_message, bool incoming) {
// TODO(isheriff): The need for this should go away once we have a proper
// API to provide max bitrate for the case of handing over encoded
// frames to webrtc.
- if (sdp_message->has_video() &&
- !sdp_message->AddCodecParameter(
- "VP8", "x-google-min-bitrate=1000; x-google-max-bitrate=100000")) {
- if (incoming) {
- LOG(WARNING) << "VP8 not found in an incoming SDP.";
- } else {
- LOG(FATAL) << "VP8 not found in SDP generated by WebRTC.";
+ if (sdp_message->has_video()) {
+ bool param_added = sdp_message->AddCodecParameter(
+ "VP8", "x-google-min-bitrate=1000; x-google-max-bitrate=100000");
+ param_added |= sdp_message->AddCodecParameter(
+ "VP9", "x-google-min-bitrate=1000; x-google-max-bitrate=100000");
+ if (!param_added) {
+ if (incoming) {
+ LOG(WARNING) << "Neither of VP8/VP9 is found in an incoming SDP.";
+ } else {
+ LOG(FATAL) << "Neither of VP8/VP9 is found in SDP generated by WebRTC.";
+ }
}
}
« no previous file with comments | « remoting/protocol/webrtc_frame_scheduler_simple.cc ('k') | remoting/protocol/webrtc_video_stream.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698