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

Side by Side Diff: talk/media/webrtc/webrtcvideoengine2.cc

Issue 1311533009: - Rename VoiceChannel::MuteStream() -> SetAudioSend() (incl. media channel) (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@lj_remove_typingmonitor_files
Patch Set: rebase+one more test Created 5 years, 3 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 unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * libjingle 2 * libjingle
3 * Copyright 2014 Google Inc. 3 * Copyright 2014 Google Inc.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are met: 6 * modification, are permitted provided that the following conditions are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright notice, 8 * 1. Redistributions of source code must retain the above copyright notice,
9 * this list of conditions and the following disclaimer. 9 * this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright notice, 10 * 2. Redistributions in binary form must reproduce the above copyright notice,
(...skipping 1076 matching lines...) Expand 10 before | Expand all | Expand 10 after
1087 } 1087 }
1088 if (send) { 1088 if (send) {
1089 StartAllSendStreams(); 1089 StartAllSendStreams();
1090 } else { 1090 } else {
1091 StopAllSendStreams(); 1091 StopAllSendStreams();
1092 } 1092 }
1093 sending_ = send; 1093 sending_ = send;
1094 return true; 1094 return true;
1095 } 1095 }
1096 1096
1097 bool WebRtcVideoChannel2::SetVideoSend(uint32 ssrc, bool mute,
1098 const VideoOptions* options) {
1099 if (!MuteStream(ssrc, mute)) {
1100 return false;
1101 }
1102 if (!mute && options) {
1103 return SetOptions(*options);
pthatcher1 2015/09/09 14:25:14 Should we rollback the mute state if SetOptions fa
the sun 2015/09/09 14:52:11 I decided against that (same goes for WebRtcVoiceM
1104 } else {
1105 return true;
1106 }
1107 }
1108
1097 bool WebRtcVideoChannel2::ValidateSendSsrcAvailability( 1109 bool WebRtcVideoChannel2::ValidateSendSsrcAvailability(
1098 const StreamParams& sp) const { 1110 const StreamParams& sp) const {
1099 for (uint32_t ssrc: sp.ssrcs) { 1111 for (uint32_t ssrc: sp.ssrcs) {
1100 if (send_ssrcs_.find(ssrc) != send_ssrcs_.end()) { 1112 if (send_ssrcs_.find(ssrc) != send_ssrcs_.end()) {
1101 LOG(LS_ERROR) << "Send stream with SSRC '" << ssrc << "' already exists."; 1113 LOG(LS_ERROR) << "Send stream with SSRC '" << ssrc << "' already exists.";
1102 return false; 1114 return false;
1103 } 1115 }
1104 } 1116 }
1105 return true; 1117 return true;
1106 } 1118 }
(...skipping 1666 matching lines...) Expand 10 before | Expand all | Expand 10 after
2773 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id]; 2785 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id];
2774 } 2786 }
2775 } 2787 }
2776 2788
2777 return video_codecs; 2789 return video_codecs;
2778 } 2790 }
2779 2791
2780 } // namespace cricket 2792 } // namespace cricket
2781 2793
2782 #endif // HAVE_WEBRTC_VIDEO 2794 #endif // HAVE_WEBRTC_VIDEO
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698