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

Side by Side Diff: webrtc/video/video_send_stream_tests.cc

Issue 1333483002: Wire up PacketTime to ReceiveStreams. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 5 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/video/video_receive_stream.cc ('k') | no next file » | 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) 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 #include <algorithm> // max 10 #include <algorithm> // max
(...skipping 939 matching lines...) Expand 10 before | Expand all | Expand 10 after
950 rtp_rtcp_->SetRTCPStatus(kRtcpNonCompound); 950 rtp_rtcp_->SetRTCPStatus(kRtcpNonCompound);
951 } 951 }
952 952
953 void OnStreamsCreated( 953 void OnStreamsCreated(
954 VideoSendStream* send_stream, 954 VideoSendStream* send_stream,
955 const std::vector<VideoReceiveStream*>& receive_streams) override { 955 const std::vector<VideoReceiveStream*>& receive_streams) override {
956 stream_ = send_stream; 956 stream_ = send_stream;
957 } 957 }
958 958
959 private: 959 private:
960 DeliveryStatus DeliverPacket(MediaType media_type, const uint8_t* packet, 960 DeliveryStatus DeliverPacket(MediaType media_type,
961 size_t length) override { 961 const uint8_t* packet,
962 size_t length,
963 const PacketTime& packet_time) override {
962 EXPECT_TRUE(media_type == MediaType::ANY || 964 EXPECT_TRUE(media_type == MediaType::ANY ||
963 media_type == MediaType::VIDEO); 965 media_type == MediaType::VIDEO);
964 if (RtpHeaderParser::IsRtcp(packet, length)) 966 if (RtpHeaderParser::IsRtcp(packet, length))
965 return DELIVERY_OK; 967 return DELIVERY_OK;
966 968
967 RTPHeader header; 969 RTPHeader header;
968 if (!parser_->Parse(packet, length, &header)) 970 if (!parser_->Parse(packet, length, &header))
969 return DELIVERY_PACKET_ERROR; 971 return DELIVERY_PACKET_ERROR;
970 DCHECK(stream_ != nullptr); 972 DCHECK(stream_ != nullptr);
971 VideoSendStream::Stats stats = stream_->GetStats(); 973 VideoSendStream::Stats stats = stream_->GetStats();
(...skipping 917 matching lines...) Expand 10 before | Expand all | Expand 10 after
1889 EXPECT_TRUE(vp9videoHeader->flexible_mode); 1891 EXPECT_TRUE(vp9videoHeader->flexible_mode);
1890 observation_complete_->Set(); 1892 observation_complete_->Set();
1891 } 1893 }
1892 1894
1893 } test; 1895 } test;
1894 1896
1895 RunBaseTest(&test); 1897 RunBaseTest(&test);
1896 } 1898 }
1897 1899
1898 } // namespace webrtc 1900 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/video/video_receive_stream.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698