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

Side by Side Diff: webrtc/pc/rtptransport.h

Issue 2889453002: Move bundle filter from BaseChannel to RtpTransport. (Closed)
Patch Set: Created 3 years, 7 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 2017 The WebRTC project authors. All Rights Reserved. 2 * Copyright 2017 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_PC_RTPTRANSPORT_H_ 11 #ifndef WEBRTC_PC_RTPTRANSPORT_H_
12 #define WEBRTC_PC_RTPTRANSPORT_H_ 12 #define WEBRTC_PC_RTPTRANSPORT_H_
13 13
14 #include "webrtc/api/ortc/rtptransportinterface.h" 14 #include "webrtc/api/ortc/rtptransportinterface.h"
15 #include "webrtc/base/sigslot.h" 15 #include "webrtc/base/sigslot.h"
16 #include "webrtc/pc/bundlefilter.h"
16 17
17 namespace rtc { 18 namespace rtc {
18 19
19 class CopyOnWriteBuffer; 20 class CopyOnWriteBuffer;
20 struct PacketOptions; 21 struct PacketOptions;
21 class PacketTransportInternal; 22 class PacketTransportInternal;
22 23
23 } // namespace rtc 24 } // namespace rtc
24 25
25 namespace webrtc { 26 namespace webrtc {
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
57 // than just "writable"; it means the last send didn't return ENOTCONN. 58 // than just "writable"; it means the last send didn't return ENOTCONN.
58 sigslot::signal1<bool> SignalReadyToSend; 59 sigslot::signal1<bool> SignalReadyToSend;
59 60
60 bool IsWritable(bool rtcp) const; 61 bool IsWritable(bool rtcp) const;
61 62
62 bool SendPacket(bool rtcp, 63 bool SendPacket(bool rtcp,
63 const rtc::CopyOnWriteBuffer* packet, 64 const rtc::CopyOnWriteBuffer* packet,
64 const rtc::PacketOptions& options, 65 const rtc::PacketOptions& options,
65 int flags); 66 int flags);
66 67
68 bool HandlesPacket(const uint8_t* data, size_t len);
69
70 bool HandlesPayloadType(int payload_type);
71
72 void AddHandledPayloadType(int payload_type);
73
67 protected: 74 protected:
68 // TODO(zstein): Remove this when we remove RtpTransportAdapter. 75 // TODO(zstein): Remove this when we remove RtpTransportAdapter.
69 RtpTransportAdapter* GetInternal() override; 76 RtpTransportAdapter* GetInternal() override;
70 77
71 private: 78 private:
72 void OnReadyToSend(rtc::PacketTransportInternal* transport); 79 void OnReadyToSend(rtc::PacketTransportInternal* transport);
73 80
74 // Updates "ready to send" for an individual channel and fires 81 // Updates "ready to send" for an individual channel and fires
75 // SignalReadyToSend. 82 // SignalReadyToSend.
76 void SetReadyToSend(bool rtcp, bool ready); 83 void SetReadyToSend(bool rtcp, bool ready);
77 84
78 void MaybeSignalReadyToSend(); 85 void MaybeSignalReadyToSend();
79 86
80 bool rtcp_mux_enabled_; 87 bool rtcp_mux_enabled_;
81 88
82 rtc::PacketTransportInternal* rtp_packet_transport_ = nullptr; 89 rtc::PacketTransportInternal* rtp_packet_transport_ = nullptr;
83 rtc::PacketTransportInternal* rtcp_packet_transport_ = nullptr; 90 rtc::PacketTransportInternal* rtcp_packet_transport_ = nullptr;
84 91
85 bool ready_to_send_ = false; 92 bool ready_to_send_ = false;
86 bool rtp_ready_to_send_ = false; 93 bool rtp_ready_to_send_ = false;
87 bool rtcp_ready_to_send_ = false; 94 bool rtcp_ready_to_send_ = false;
88 95
89 RtcpParameters rtcp_parameters_; 96 RtcpParameters rtcp_parameters_;
97
98 cricket::BundleFilter bundle_filter_;
90 }; 99 };
91 100
92 } // namespace webrtc 101 } // namespace webrtc
93 102
94 #endif // WEBRTC_PC_RTPTRANSPORT_H_ 103 #endif // WEBRTC_PC_RTPTRANSPORT_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698