Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(6)

Side by Side Diff: webrtc/modules/rtp_rtcp/include/rtp_payload_registry.h

Issue 1921233002: Replace the remaining scoped_ptr with unique_ptr in webrtc/modules/ (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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
11 #ifndef WEBRTC_MODULES_RTP_RTCP_INCLUDE_RTP_PAYLOAD_REGISTRY_H_ 11 #ifndef WEBRTC_MODULES_RTP_RTCP_INCLUDE_RTP_PAYLOAD_REGISTRY_H_
12 #define WEBRTC_MODULES_RTP_RTCP_INCLUDE_RTP_PAYLOAD_REGISTRY_H_ 12 #define WEBRTC_MODULES_RTP_RTCP_INCLUDE_RTP_PAYLOAD_REGISTRY_H_
13 13
14 #include <map> 14 #include <map>
15 #include <memory>
15 16
16 #include "webrtc/base/criticalsection.h" 17 #include "webrtc/base/criticalsection.h"
17 #include "webrtc/base/scoped_ptr.h"
18 #include "webrtc/modules/rtp_rtcp/source/rtp_receiver_strategy.h" 18 #include "webrtc/modules/rtp_rtcp/source/rtp_receiver_strategy.h"
19 #include "webrtc/modules/rtp_rtcp/source/rtp_utility.h" 19 #include "webrtc/modules/rtp_rtcp/source/rtp_utility.h"
20 20
21 namespace webrtc { 21 namespace webrtc {
22 22
23 // This strategy deals with the audio/video-specific aspects 23 // This strategy deals with the audio/video-specific aspects
24 // of payload handling. 24 // of payload handling.
25 class RTPPayloadStrategy { 25 class RTPPayloadStrategy {
26 public: 26 public:
27 virtual ~RTPPayloadStrategy() {} 27 virtual ~RTPPayloadStrategy() {}
(...skipping 146 matching lines...) Expand 10 before | Expand all | Expand 10 after
174 const char payload_name[RTP_PAYLOAD_NAME_SIZE], 174 const char payload_name[RTP_PAYLOAD_NAME_SIZE],
175 const size_t payload_name_length, 175 const size_t payload_name_length,
176 const uint32_t frequency, 176 const uint32_t frequency,
177 const size_t channels, 177 const size_t channels,
178 const uint32_t rate); 178 const uint32_t rate);
179 179
180 bool IsRtxInternal(const RTPHeader& header) const; 180 bool IsRtxInternal(const RTPHeader& header) const;
181 181
182 rtc::CriticalSection crit_sect_; 182 rtc::CriticalSection crit_sect_;
183 RtpUtility::PayloadTypeMap payload_type_map_; 183 RtpUtility::PayloadTypeMap payload_type_map_;
184 rtc::scoped_ptr<RTPPayloadStrategy> rtp_payload_strategy_; 184 std::unique_ptr<RTPPayloadStrategy> rtp_payload_strategy_;
185 int8_t red_payload_type_; 185 int8_t red_payload_type_;
186 int8_t ulpfec_payload_type_; 186 int8_t ulpfec_payload_type_;
187 int8_t incoming_payload_type_; 187 int8_t incoming_payload_type_;
188 int8_t last_received_payload_type_; 188 int8_t last_received_payload_type_;
189 int8_t last_received_media_payload_type_; 189 int8_t last_received_media_payload_type_;
190 bool rtx_; 190 bool rtx_;
191 // TODO(changbin): Remove rtx_payload_type_ once interop with old clients that 191 // TODO(changbin): Remove rtx_payload_type_ once interop with old clients that
192 // only understand one RTX PT is no longer needed. 192 // only understand one RTX PT is no longer needed.
193 int rtx_payload_type_; 193 int rtx_payload_type_;
194 // Mapping rtx_payload_type_map_[rtx] = associated. 194 // Mapping rtx_payload_type_map_[rtx] = associated.
195 std::map<int, int> rtx_payload_type_map_; 195 std::map<int, int> rtx_payload_type_map_;
196 // When true, use rtx_payload_type_map_ when restoring RTX packets to get the 196 // When true, use rtx_payload_type_map_ when restoring RTX packets to get the
197 // correct payload type. 197 // correct payload type.
198 bool use_rtx_payload_mapping_on_restore_; 198 bool use_rtx_payload_mapping_on_restore_;
199 uint32_t ssrc_rtx_; 199 uint32_t ssrc_rtx_;
200 }; 200 };
201 201
202 } // namespace webrtc 202 } // namespace webrtc
203 203
204 #endif // WEBRTC_MODULES_RTP_RTCP_INCLUDE_RTP_PAYLOAD_REGISTRY_H_ 204 #endif // WEBRTC_MODULES_RTP_RTCP_INCLUDE_RTP_PAYLOAD_REGISTRY_H_
OLDNEW
« no previous file with comments | « webrtc/modules/rtp_rtcp/include/remote_ntp_time_estimator.h ('k') | webrtc/modules/rtp_rtcp/source/fec_receiver_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698