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 #include <algorithm> | 10 #include <algorithm> |
(...skipping 387 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
398 capturer_(nullptr), | 398 capturer_(nullptr), |
399 rtp_start_timestamp_set_(false), | 399 rtp_start_timestamp_set_(false), |
400 rtp_start_timestamp_(0) {} | 400 rtp_start_timestamp_(0) {} |
401 | 401 |
402 private: | 402 private: |
403 test::PacketTransport* CreateSendTransport(Call* sender_call) override { | 403 test::PacketTransport* CreateSendTransport(Call* sender_call) override { |
404 return new test::PacketTransport( | 404 return new test::PacketTransport( |
405 sender_call, this, test::PacketTransport::kSender, net_config_); | 405 sender_call, this, test::PacketTransport::kSender, net_config_); |
406 } | 406 } |
407 | 407 |
| 408 test::PacketTransport* CreateReceiveTransport() override { |
| 409 return new test::PacketTransport( |
| 410 nullptr, this, test::PacketTransport::kReceiver, net_config_); |
| 411 } |
| 412 |
408 void RenderFrame(const VideoFrame& video_frame, | 413 void RenderFrame(const VideoFrame& video_frame, |
409 int time_to_render_ms) override { | 414 int time_to_render_ms) override { |
410 rtc::CritScope lock(&crit_); | 415 rtc::CritScope lock(&crit_); |
411 if (video_frame.ntp_time_ms() <= 0) { | 416 if (video_frame.ntp_time_ms() <= 0) { |
412 // Haven't got enough RTCP SR in order to calculate the capture ntp | 417 // Haven't got enough RTCP SR in order to calculate the capture ntp |
413 // time. | 418 // time. |
414 return; | 419 return; |
415 } | 420 } |
416 | 421 |
417 int64_t now_ms = clock_->TimeInMilliseconds(); | 422 int64_t now_ms = clock_->TimeInMilliseconds(); |
(...skipping 327 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
745 int encoder_inits_; | 750 int encoder_inits_; |
746 uint32_t last_set_bitrate_; | 751 uint32_t last_set_bitrate_; |
747 VideoSendStream* send_stream_; | 752 VideoSendStream* send_stream_; |
748 VideoEncoderConfig encoder_config_; | 753 VideoEncoderConfig encoder_config_; |
749 } test; | 754 } test; |
750 | 755 |
751 RunBaseTest(&test); | 756 RunBaseTest(&test); |
752 } | 757 } |
753 | 758 |
754 } // namespace webrtc | 759 } // namespace webrtc |
OLD | NEW |