OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2015 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2015 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 160 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
171 } | 171 } |
172 | 172 |
173 void FakeVideoSendStream::OnFrame(const webrtc::VideoFrame& frame) { | 173 void FakeVideoSendStream::OnFrame(const webrtc::VideoFrame& frame) { |
174 ++num_swapped_frames_; | 174 ++num_swapped_frames_; |
175 if (frame.width() != last_frame_.width() || | 175 if (frame.width() != last_frame_.width() || |
176 frame.height() != last_frame_.height() || | 176 frame.height() != last_frame_.height() || |
177 frame.rotation() != last_frame_.rotation()) { | 177 frame.rotation() != last_frame_.rotation()) { |
178 video_streams_ = encoder_config_.video_stream_factory->CreateEncoderStreams( | 178 video_streams_ = encoder_config_.video_stream_factory->CreateEncoderStreams( |
179 frame.width(), frame.height(), encoder_config_); | 179 frame.width(), frame.height(), encoder_config_); |
180 } | 180 } |
181 last_frame_.ShallowCopy(frame); | 181 last_frame_ = frame; |
182 } | 182 } |
183 | 183 |
184 void FakeVideoSendStream::SetStats( | 184 void FakeVideoSendStream::SetStats( |
185 const webrtc::VideoSendStream::Stats& stats) { | 185 const webrtc::VideoSendStream::Stats& stats) { |
186 stats_ = stats; | 186 stats_ = stats; |
187 } | 187 } |
188 | 188 |
189 webrtc::VideoSendStream::Stats FakeVideoSendStream::GetStats() { | 189 webrtc::VideoSendStream::Stats FakeVideoSendStream::GetStats() { |
190 return stats_; | 190 return stats_; |
191 } | 191 } |
(...skipping 323 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
515 } | 515 } |
516 | 516 |
517 void FakeCall::OnSentPacket(const rtc::SentPacket& sent_packet) { | 517 void FakeCall::OnSentPacket(const rtc::SentPacket& sent_packet) { |
518 last_sent_packet_ = sent_packet; | 518 last_sent_packet_ = sent_packet; |
519 if (sent_packet.packet_id >= 0) { | 519 if (sent_packet.packet_id >= 0) { |
520 last_sent_nonnegative_packet_id_ = sent_packet.packet_id; | 520 last_sent_nonnegative_packet_id_ = sent_packet.packet_id; |
521 } | 521 } |
522 } | 522 } |
523 | 523 |
524 } // namespace cricket | 524 } // namespace cricket |
OLD | NEW |