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

Side by Side Diff: webrtc/test/rtcp_packet_parser.h

Issue 3007763002: Move array_view.h to webrtc/api/ (Closed)
Patch Set: rebase Created 3 years, 3 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
« no previous file with comments | « webrtc/test/mock_audio_encoder.h ('k') | webrtc/voice_engine/BUILD.gn » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2014 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 11
12 #ifndef WEBRTC_TEST_RTCP_PACKET_PARSER_H_ 12 #ifndef WEBRTC_TEST_RTCP_PACKET_PARSER_H_
13 #define WEBRTC_TEST_RTCP_PACKET_PARSER_H_ 13 #define WEBRTC_TEST_RTCP_PACKET_PARSER_H_
14 14
15 #include "webrtc/api/array_view.h"
15 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/app.h" 16 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/app.h"
16 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/bye.h" 17 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/bye.h"
17 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/common_header.h" 18 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/common_header.h"
18 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/extended_jitter_report.h" 19 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/extended_jitter_report.h"
19 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/extended_reports.h" 20 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/extended_reports.h"
20 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/fir.h" 21 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/fir.h"
21 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/nack.h" 22 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/nack.h"
22 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/pli.h" 23 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/pli.h"
23 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/rapid_resync_request.h" 24 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/rapid_resync_request.h"
24 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/receiver_report.h" 25 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/receiver_report.h"
25 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/remb.h" 26 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/remb.h"
26 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/sdes.h" 27 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/sdes.h"
27 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/sender_report.h" 28 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/sender_report.h"
28 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/tmmbn.h" 29 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/tmmbn.h"
29 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/tmmbr.h" 30 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/tmmbr.h"
30 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/transport_feedback.h" 31 #include "webrtc/modules/rtp_rtcp/source/rtcp_packet/transport_feedback.h"
31 #include "webrtc/rtc_base/array_view.h"
32 #include "webrtc/rtc_base/checks.h" 32 #include "webrtc/rtc_base/checks.h"
33 33
34 namespace webrtc { 34 namespace webrtc {
35 namespace test { 35 namespace test {
36 // Parse RTCP packet of given type. Assumes RTCP header is valid and that there 36 // Parse RTCP packet of given type. Assumes RTCP header is valid and that there
37 // is excatly one packet of correct type in the buffer. 37 // is excatly one packet of correct type in the buffer.
38 template <typename Packet> 38 template <typename Packet>
39 bool ParseSinglePacket(const uint8_t* buffer, size_t size, Packet* packet) { 39 bool ParseSinglePacket(const uint8_t* buffer, size_t size, Packet* packet) {
40 rtcp::CommonHeader header; 40 rtcp::CommonHeader header;
41 RTC_CHECK(header.Parse(buffer, size)); 41 RTC_CHECK(header.Parse(buffer, size));
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
112 PacketCounter<rtcp::SenderReport> sender_report_; 112 PacketCounter<rtcp::SenderReport> sender_report_;
113 PacketCounter<rtcp::Tmmbn> tmmbn_; 113 PacketCounter<rtcp::Tmmbn> tmmbn_;
114 PacketCounter<rtcp::Tmmbr> tmmbr_; 114 PacketCounter<rtcp::Tmmbr> tmmbr_;
115 PacketCounter<rtcp::TransportFeedback> transport_feedback_; 115 PacketCounter<rtcp::TransportFeedback> transport_feedback_;
116 uint32_t sender_ssrc_ = 0; 116 uint32_t sender_ssrc_ = 0;
117 }; 117 };
118 118
119 } // namespace test 119 } // namespace test
120 } // namespace webrtc 120 } // namespace webrtc
121 #endif // WEBRTC_TEST_RTCP_PACKET_PARSER_H_ 121 #endif // WEBRTC_TEST_RTCP_PACKET_PARSER_H_
OLDNEW
« no previous file with comments | « webrtc/test/mock_audio_encoder.h ('k') | webrtc/voice_engine/BUILD.gn » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698