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

Side by Side Diff: media/cast/net/rtcp/rtcp_utility.cc

Issue 575683002: [Cast] Fix RtcpParser to parse negative playout delay deltas in receiver reports. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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 | « no previous file | media/cast/net/rtcp/rtcp_utility_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "media/cast/net/rtcp/rtcp_utility.h" 5 #include "media/cast/net/rtcp/rtcp_utility.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "media/cast/net/cast_transport_defines.h" 8 #include "media/cast/net/cast_transport_defines.h"
9 9
10 namespace media { 10 namespace media {
(...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 event_log.type = TranslateToLogEventFromWireFormat( 208 event_log.type = TranslateToLogEventFromWireFormat(
209 static_cast<uint8>(event_type_and_timestamp_delta >> 12)); 209 static_cast<uint8>(event_type_and_timestamp_delta >> 12));
210 event_log.event_timestamp = 210 event_log.event_timestamp =
211 event_timestamp_base + 211 event_timestamp_base +
212 base::TimeDelta::FromMilliseconds( 212 base::TimeDelta::FromMilliseconds(
213 event_type_and_timestamp_delta & 0xfff); 213 event_type_and_timestamp_delta & 0xfff);
214 if (event_log.type == PACKET_RECEIVED) { 214 if (event_log.type == PACKET_RECEIVED) {
215 event_log.packet_id = delay_delta_or_packet_id; 215 event_log.packet_id = delay_delta_or_packet_id;
216 } else { 216 } else {
217 event_log.delay_delta = base::TimeDelta::FromMilliseconds( 217 event_log.delay_delta = base::TimeDelta::FromMilliseconds(
218 delay_delta_or_packet_id); 218 static_cast<int16>(delay_delta_or_packet_id));
219 } 219 }
220 frame_log.event_log_messages_.push_back(event_log); 220 frame_log.event_log_messages_.push_back(event_log);
221 } 221 }
222 222
223 receiver_log_.push_back(frame_log); 223 receiver_log_.push_back(frame_log);
224 } 224 }
225 225
226 return true; 226 return true;
227 } 227 }
228 228
(...skipping 147 matching lines...) Expand 10 before | Expand all | Expand 10 after
376 default: 376 default:
377 // If the sender adds new log messages we will end up here until we add 377 // If the sender adds new log messages we will end up here until we add
378 // the new messages in the receiver. 378 // the new messages in the receiver.
379 VLOG(1) << "Unexpected log message received: " << static_cast<int>(event); 379 VLOG(1) << "Unexpected log message received: " << static_cast<int>(event);
380 return UNKNOWN; 380 return UNKNOWN;
381 } 381 }
382 } 382 }
383 383
384 } // namespace cast 384 } // namespace cast
385 } // namespace media 385 } // namespace media
OLDNEW
« no previous file with comments | « no previous file | media/cast/net/rtcp/rtcp_utility_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698