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 #ifndef WEBRTC_TEST_DIRECT_TRANSPORT_H_ | 10 #ifndef WEBRTC_TEST_DIRECT_TRANSPORT_H_ |
(...skipping 28 matching lines...) Expand all Loading... |
39 | 39 |
40 virtual void StopSending(); | 40 virtual void StopSending(); |
41 // TODO(holmer): Look into moving this to the constructor. | 41 // TODO(holmer): Look into moving this to the constructor. |
42 virtual void SetReceiver(PacketReceiver* receiver); | 42 virtual void SetReceiver(PacketReceiver* receiver); |
43 | 43 |
44 bool SendRtp(const uint8_t* data, | 44 bool SendRtp(const uint8_t* data, |
45 size_t length, | 45 size_t length, |
46 const PacketOptions& options) override; | 46 const PacketOptions& options) override; |
47 bool SendRtcp(const uint8_t* data, size_t length) override; | 47 bool SendRtcp(const uint8_t* data, size_t length) override; |
48 | 48 |
| 49 int GetAverageDelayMs(); |
| 50 |
49 private: | 51 private: |
50 static bool NetworkProcess(void* transport); | 52 static bool NetworkProcess(void* transport); |
51 bool SendPackets(); | 53 bool SendPackets(); |
52 | 54 |
53 rtc::CriticalSection lock_; | 55 rtc::CriticalSection lock_; |
54 Call* const send_call_; | 56 Call* const send_call_; |
55 rtc::Event packet_event_; | 57 rtc::Event packet_event_; |
56 rtc::PlatformThread thread_; | 58 rtc::PlatformThread thread_; |
57 Clock* const clock_; | 59 Clock* const clock_; |
58 | 60 |
59 bool shutting_down_; | 61 bool shutting_down_; |
60 | 62 |
61 FakeNetworkPipe fake_network_; | 63 FakeNetworkPipe fake_network_; |
62 }; | 64 }; |
63 } // namespace test | 65 } // namespace test |
64 } // namespace webrtc | 66 } // namespace webrtc |
65 | 67 |
66 #endif // WEBRTC_TEST_DIRECT_TRANSPORT_H_ | 68 #endif // WEBRTC_TEST_DIRECT_TRANSPORT_H_ |
OLD | NEW |