| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_LOGGING_DEFINES_H_ | 5 #ifndef MEDIA_CAST_LOGGING_LOGGING_DEFINES_H_ |
| 6 #define MEDIA_CAST_LOGGING_LOGGING_DEFINES_H_ | 6 #define MEDIA_CAST_LOGGING_LOGGING_DEFINES_H_ |
| 7 | 7 |
| 8 #include <map> | 8 #include <map> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <vector> | 10 #include <vector> |
| 11 | 11 |
| 12 #include "base/time/time.h" | 12 #include "base/time/time.h" |
| 13 | 13 |
| 14 namespace media { | 14 namespace media { |
| 15 namespace cast { | 15 namespace cast { |
| 16 | 16 |
| 17 static const uint32 kFrameIdUnknown = 0xFFFFFFFF; | 17 static const uint32_t kFrameIdUnknown = 0xFFFFFFFF; |
| 18 | 18 |
| 19 typedef uint32 RtpTimestamp; | 19 typedef uint32_t RtpTimestamp; |
| 20 | 20 |
| 21 enum CastLoggingEvent { | 21 enum CastLoggingEvent { |
| 22 UNKNOWN, | 22 UNKNOWN, |
| 23 // Sender side frame events. | 23 // Sender side frame events. |
| 24 FRAME_CAPTURE_BEGIN, | 24 FRAME_CAPTURE_BEGIN, |
| 25 FRAME_CAPTURE_END, | 25 FRAME_CAPTURE_END, |
| 26 FRAME_ENCODED, | 26 FRAME_ENCODED, |
| 27 FRAME_ACK_RECEIVED, | 27 FRAME_ACK_RECEIVED, |
| 28 // Receiver side frame events. | 28 // Receiver side frame events. |
| 29 FRAME_ACK_SENT, | 29 FRAME_ACK_SENT, |
| (...skipping 16 matching lines...) Expand all Loading... |
| 46 VIDEO_EVENT, | 46 VIDEO_EVENT, |
| 47 UNKNOWN_EVENT, | 47 UNKNOWN_EVENT, |
| 48 EVENT_MEDIA_TYPE_LAST = UNKNOWN_EVENT | 48 EVENT_MEDIA_TYPE_LAST = UNKNOWN_EVENT |
| 49 }; | 49 }; |
| 50 | 50 |
| 51 struct FrameEvent { | 51 struct FrameEvent { |
| 52 FrameEvent(); | 52 FrameEvent(); |
| 53 ~FrameEvent(); | 53 ~FrameEvent(); |
| 54 | 54 |
| 55 RtpTimestamp rtp_timestamp; | 55 RtpTimestamp rtp_timestamp; |
| 56 uint32 frame_id; | 56 uint32_t frame_id; |
| 57 | 57 |
| 58 // Resolution of the frame. Only set for video FRAME_CAPTURE_END events. | 58 // Resolution of the frame. Only set for video FRAME_CAPTURE_END events. |
| 59 int width; | 59 int width; |
| 60 int height; | 60 int height; |
| 61 | 61 |
| 62 // Size of encoded frame in bytes. Only set for FRAME_ENCODED event. | 62 // Size of encoded frame in bytes. Only set for FRAME_ENCODED event. |
| 63 size_t size; | 63 size_t size; |
| 64 | 64 |
| 65 // Time of event logged. | 65 // Time of event logged. |
| 66 base::TimeTicks timestamp; | 66 base::TimeTicks timestamp; |
| (...skipping 19 matching lines...) Expand all Loading... |
| 86 // for a description of these values. | 86 // for a description of these values. |
| 87 double encoder_cpu_utilization; | 87 double encoder_cpu_utilization; |
| 88 double idealized_bitrate_utilization; | 88 double idealized_bitrate_utilization; |
| 89 }; | 89 }; |
| 90 | 90 |
| 91 struct PacketEvent { | 91 struct PacketEvent { |
| 92 PacketEvent(); | 92 PacketEvent(); |
| 93 ~PacketEvent(); | 93 ~PacketEvent(); |
| 94 | 94 |
| 95 RtpTimestamp rtp_timestamp; | 95 RtpTimestamp rtp_timestamp; |
| 96 uint32 frame_id; | 96 uint32_t frame_id; |
| 97 uint16 max_packet_id; | 97 uint16_t max_packet_id; |
| 98 uint16 packet_id; | 98 uint16_t packet_id; |
| 99 size_t size; | 99 size_t size; |
| 100 | 100 |
| 101 // Time of event logged. | 101 // Time of event logged. |
| 102 base::TimeTicks timestamp; | 102 base::TimeTicks timestamp; |
| 103 CastLoggingEvent type; | 103 CastLoggingEvent type; |
| 104 EventMediaType media_type; | 104 EventMediaType media_type; |
| 105 }; | 105 }; |
| 106 | 106 |
| 107 } // namespace cast | 107 } // namespace cast |
| 108 } // namespace media | 108 } // namespace media |
| 109 | 109 |
| 110 #endif // MEDIA_CAST_LOGGING_LOGGING_DEFINES_H_ | 110 #endif // MEDIA_CAST_LOGGING_LOGGING_DEFINES_H_ |
| OLD | NEW |