| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. |
| 3 * | 3 * |
| 4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
| 5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
| 6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
| 7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
| 8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
| 9 */ | 9 */ |
| 10 | 10 |
| (...skipping 150 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 161 return sender_->RegisterSendStatisticsCallback(sendStats); | 161 return sender_->RegisterSendStatisticsCallback(sendStats); |
| 162 } | 162 } |
| 163 | 163 |
| 164 int32_t RegisterProtectionCallback( | 164 int32_t RegisterProtectionCallback( |
| 165 VCMProtectionCallback* protection) override { | 165 VCMProtectionCallback* protection) override { |
| 166 return sender_->RegisterProtectionCallback(protection); | 166 return sender_->RegisterProtectionCallback(protection); |
| 167 } | 167 } |
| 168 | 168 |
| 169 int32_t SetVideoProtection(VCMVideoProtection videoProtection, | 169 int32_t SetVideoProtection(VCMVideoProtection videoProtection, |
| 170 bool enable) override { | 170 bool enable) override { |
| 171 sender_->SetVideoProtection(enable, videoProtection); | 171 // TODO(pbos): Remove enable from receive-side protection modes as well. |
| 172 if (enable) |
| 173 sender_->SetVideoProtection(videoProtection); |
| 172 return receiver_->SetVideoProtection(videoProtection, enable); | 174 return receiver_->SetVideoProtection(videoProtection, enable); |
| 173 } | 175 } |
| 174 | 176 |
| 175 int32_t AddVideoFrame(const VideoFrame& videoFrame, | 177 int32_t AddVideoFrame(const VideoFrame& videoFrame, |
| 176 const VideoContentMetrics* contentMetrics, | 178 const VideoContentMetrics* contentMetrics, |
| 177 const CodecSpecificInfo* codecSpecificInfo) override { | 179 const CodecSpecificInfo* codecSpecificInfo) override { |
| 178 return sender_->AddVideoFrame( | 180 return sender_->AddVideoFrame( |
| 179 videoFrame, contentMetrics, codecSpecificInfo); | 181 videoFrame, contentMetrics, codecSpecificInfo); |
| 180 } | 182 } |
| 181 | 183 |
| (...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 356 return new VideoCodingModuleImpl(clock, event_factory, false, nullptr, | 358 return new VideoCodingModuleImpl(clock, event_factory, false, nullptr, |
| 357 nullptr); | 359 nullptr); |
| 358 } | 360 } |
| 359 | 361 |
| 360 void VideoCodingModule::Destroy(VideoCodingModule* module) { | 362 void VideoCodingModule::Destroy(VideoCodingModule* module) { |
| 361 if (module != NULL) { | 363 if (module != NULL) { |
| 362 delete static_cast<VideoCodingModuleImpl*>(module); | 364 delete static_cast<VideoCodingModuleImpl*>(module); |
| 363 } | 365 } |
| 364 } | 366 } |
| 365 } // namespace webrtc | 367 } // namespace webrtc |
| OLD | NEW |