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 58 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
69 int sync_offset_ms = std::numeric_limits<int>::max(); | 69 int sync_offset_ms = std::numeric_limits<int>::max(); |
70 | 70 |
71 uint32_t ssrc = 0; | 71 uint32_t ssrc = 0; |
72 std::string c_name; | 72 std::string c_name; |
73 StreamDataCounters rtp_stats; | 73 StreamDataCounters rtp_stats; |
74 RtcpPacketTypeCounter rtcp_packet_type_counts; | 74 RtcpPacketTypeCounter rtcp_packet_type_counts; |
75 RtcpStatistics rtcp_stats; | 75 RtcpStatistics rtcp_stats; |
76 }; | 76 }; |
77 | 77 |
78 struct Config { | 78 struct Config { |
| 79 private: |
| 80 // Access to the copy constructor is private to force use of the Copy() |
| 81 // method for those exceptional cases where we do use it. |
| 82 Config(const Config&) = default; |
| 83 |
| 84 public: |
79 Config() = delete; | 85 Config() = delete; |
| 86 Config(Config&&) = default; |
80 explicit Config(Transport* rtcp_send_transport) | 87 explicit Config(Transport* rtcp_send_transport) |
81 : rtcp_send_transport(rtcp_send_transport) {} | 88 : rtcp_send_transport(rtcp_send_transport) {} |
82 | 89 |
| 90 Config& operator=(Config&&) = default; |
| 91 Config& operator=(const Config&) = delete; |
| 92 |
| 93 // Mostly used by tests. Avoid creating copies if you can. |
| 94 Config Copy() const { return Config(*this); } |
| 95 |
83 std::string ToString() const; | 96 std::string ToString() const; |
84 | 97 |
85 // Decoders for every payload that we can receive. | 98 // Decoders for every payload that we can receive. |
86 std::vector<Decoder> decoders; | 99 std::vector<Decoder> decoders; |
87 | 100 |
88 // Receive-stream specific RTP settings. | 101 // Receive-stream specific RTP settings. |
89 struct Rtp { | 102 struct Rtp { |
90 std::string ToString() const; | 103 std::string ToString() const; |
91 | 104 |
92 // Synchronization source (stream identifier) to be received. | 105 // Synchronization source (stream identifier) to be received. |
(...skipping 95 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
188 // TODO(pbos): Add info on currently-received codec to Stats. | 201 // TODO(pbos): Add info on currently-received codec to Stats. |
189 virtual Stats GetStats() const = 0; | 202 virtual Stats GetStats() const = 0; |
190 | 203 |
191 protected: | 204 protected: |
192 virtual ~VideoReceiveStream() {} | 205 virtual ~VideoReceiveStream() {} |
193 }; | 206 }; |
194 | 207 |
195 } // namespace webrtc | 208 } // namespace webrtc |
196 | 209 |
197 #endif // WEBRTC_VIDEO_RECEIVE_STREAM_H_ | 210 #endif // WEBRTC_VIDEO_RECEIVE_STREAM_H_ |
OLD | NEW |