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

Side by Side Diff: media/cast/logging/log_deserializer.h

Issue 1515433002: Replace uses of raw uint32's with a type-checked RtpTimeTicks data type. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Speculative workaround fix for win8_chromium_ng compile error. Created 4 years, 11 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 // 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 #ifndef MEDIA_CAST_LOGGING_LOG_DESERIALIZER_H_ 5 #ifndef MEDIA_CAST_LOGGING_LOG_DESERIALIZER_H_
6 #define MEDIA_CAST_LOGGING_LOG_DESERIALIZER_H_ 6 #define MEDIA_CAST_LOGGING_LOG_DESERIALIZER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 10
11 #include "base/memory/linked_ptr.h" 11 #include "base/memory/linked_ptr.h"
12 #include "media/cast/logging/logging_defines.h" 12 #include "media/cast/logging/logging_defines.h"
13 #include "media/cast/logging/proto/raw_events.pb.h" 13 #include "media/cast/logging/proto/raw_events.pb.h"
14 14
15 namespace media { 15 namespace media {
16 namespace cast { 16 namespace cast {
17 17
18 typedef std::map<RtpTimestamp, 18 typedef std::map<RtpTimeTicks,
19 linked_ptr<media::cast::proto::AggregatedFrameEvent> > 19 linked_ptr<media::cast::proto::AggregatedFrameEvent>>
20 FrameEventMap; 20 FrameEventMap;
21 typedef std::map<RtpTimestamp, 21 typedef std::map<RtpTimeTicks,
22 linked_ptr<media::cast::proto::AggregatedPacketEvent> > 22 linked_ptr<media::cast::proto::AggregatedPacketEvent>>
23 PacketEventMap; 23 PacketEventMap;
24 24
25 // Represents deserialized raw event logs for a particular stream. 25 // Represents deserialized raw event logs for a particular stream.
26 struct DeserializedLog { 26 struct DeserializedLog {
27 DeserializedLog(); 27 DeserializedLog();
28 ~DeserializedLog(); 28 ~DeserializedLog();
29 proto::LogMetadata metadata; 29 proto::LogMetadata metadata;
30 FrameEventMap frame_events; 30 FrameEventMap frame_events;
31 PacketEventMap packet_events; 31 PacketEventMap packet_events;
32 }; 32 };
33 33
34 // This function takes the output of LogSerializer and deserializes it into 34 // This function takes the output of LogSerializer and deserializes it into
35 // its original format. Returns true if deserialization is successful. All 35 // its original format. Returns true if deserialization is successful. All
36 // output arguments are valid if this function returns true. 36 // output arguments are valid if this function returns true.
37 // |data|: Serialized event logs with length |data_bytes|. 37 // |data|: Serialized event logs with length |data_bytes|.
38 // |compressed|: true if |data| is compressed in gzip format. 38 // |compressed|: true if |data| is compressed in gzip format.
39 // |log_metadata|: This will be populated with deserialized LogMetadata proto. 39 // |log_metadata|: This will be populated with deserialized LogMetadata proto.
40 // |audio_log|, |video_log|: These will be populated with deserialized 40 // |audio_log|, |video_log|: These will be populated with deserialized
41 // log data for audio and video streams, respectively. 41 // log data for audio and video streams, respectively.
42 bool DeserializeEvents(const char* data, 42 bool DeserializeEvents(const char* data,
43 int data_bytes, 43 int data_bytes,
44 bool compressed, 44 bool compressed,
45 DeserializedLog* audio_log, 45 DeserializedLog* audio_log,
46 DeserializedLog* video_log); 46 DeserializedLog* video_log);
47 47
48 } // namespace cast 48 } // namespace cast
49 } // namespace media 49 } // namespace media
50 50
51 #endif // MEDIA_CAST_LOGGING_LOG_DESERIALIZER_H_ 51 #endif // MEDIA_CAST_LOGGING_LOG_DESERIALIZER_H_
OLDNEW
« no previous file with comments | « media/cast/logging/encoding_event_subscriber_unittest.cc ('k') | media/cast/logging/log_deserializer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698