| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (c) 2013 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2013 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 107 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 118 codec.width = 320; | 118 codec.width = 320; |
| 119 codec.height = 180; | 119 codec.height = 180; |
| 120 codec.startBitrate = codec.minBitrate = codec.maxBitrate = | 120 codec.startBitrate = codec.minBitrate = codec.maxBitrate = |
| 121 Call::Config::kDefaultStartBitrateBps / 1000; | 121 Call::Config::kDefaultStartBitrateBps / 1000; |
| 122 | 122 |
| 123 return codec; | 123 return codec; |
| 124 } | 124 } |
| 125 } // namespace | 125 } // namespace |
| 126 | 126 |
| 127 VideoReceiveStream::VideoReceiveStream(int num_cpu_cores, | 127 VideoReceiveStream::VideoReceiveStream(int num_cpu_cores, |
| 128 int base_channel_id, | |
| 129 ChannelGroup* channel_group, | 128 ChannelGroup* channel_group, |
| 130 int channel_id, | 129 int channel_id, |
| 131 const VideoReceiveStream::Config& config, | 130 const VideoReceiveStream::Config& config, |
| 132 newapi::Transport* transport, | 131 newapi::Transport* transport, |
| 133 webrtc::VoiceEngine* voice_engine) | 132 webrtc::VoiceEngine* voice_engine) |
| 134 : transport_adapter_(transport), | 133 : transport_adapter_(transport), |
| 135 encoded_frame_proxy_(config.pre_decode_callback), | 134 encoded_frame_proxy_(config.pre_decode_callback), |
| 136 config_(config), | 135 config_(config), |
| 137 clock_(Clock::GetRealTimeClock()), | 136 clock_(Clock::GetRealTimeClock()), |
| 138 channel_group_(channel_group), | 137 channel_group_(channel_group), |
| 139 channel_id_(channel_id) { | 138 channel_id_(channel_id) { |
| 140 CHECK(channel_group_->CreateReceiveChannel(channel_id_, 0, base_channel_id, | 139 CHECK(channel_group_->CreateReceiveChannel( |
| 141 &transport_adapter_, num_cpu_cores, | 140 channel_id_, 0, &transport_adapter_, num_cpu_cores)); |
| 142 true)); | |
| 143 | 141 |
| 144 vie_channel_ = channel_group_->GetChannel(channel_id_); | 142 vie_channel_ = channel_group_->GetChannel(channel_id_); |
| 145 | 143 |
| 146 // TODO(pbos): This is not fine grained enough... | 144 // TODO(pbos): This is not fine grained enough... |
| 147 vie_channel_->SetProtectionMode(config_.rtp.nack.rtp_history_ms > 0, false, | 145 vie_channel_->SetProtectionMode(config_.rtp.nack.rtp_history_ms > 0, false, |
| 148 -1, -1); | 146 -1, -1); |
| 149 vie_channel_->SetKeyFrameRequestMethod(kKeyFrameReqPliRtcp); | 147 vie_channel_->SetKeyFrameRequestMethod(kKeyFrameReqPliRtcp); |
| 150 SetRtcpMode(config_.rtp.rtcp_mode); | 148 SetRtcpMode(config_.rtp.rtcp_mode); |
| 151 | 149 |
| 152 DCHECK(config_.rtp.remote_ssrc != 0); | 150 DCHECK(config_.rtp.remote_ssrc != 0); |
| (...skipping 182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 335 case newapi::kRtcpCompound: | 333 case newapi::kRtcpCompound: |
| 336 vie_channel_->SetRTCPMode(kRtcpCompound); | 334 vie_channel_->SetRTCPMode(kRtcpCompound); |
| 337 break; | 335 break; |
| 338 case newapi::kRtcpReducedSize: | 336 case newapi::kRtcpReducedSize: |
| 339 vie_channel_->SetRTCPMode(kRtcpNonCompound); | 337 vie_channel_->SetRTCPMode(kRtcpNonCompound); |
| 340 break; | 338 break; |
| 341 } | 339 } |
| 342 } | 340 } |
| 343 } // namespace internal | 341 } // namespace internal |
| 344 } // namespace webrtc | 342 } // namespace webrtc |
| OLD | NEW |