diff options
author | Avi Drissman <avi@chromium.org> | 2015-12-18 20:11:31 -0500 |
---|---|---|
committer | Avi Drissman <avi@chromium.org> | 2015-12-19 01:13:36 +0000 |
commit | 97785eaf0f3b8f017a38fe738ade818754492483 (patch) | |
tree | 6663166eaeaefbc78833bf48e89e6544e5d8d1cd /media/cast/logging | |
parent | a388b145dee01a807b80517d57c7229e34e23883 (diff) | |
download | chromium_src-97785eaf0f3b8f017a38fe738ade818754492483.zip chromium_src-97785eaf0f3b8f017a38fe738ade818754492483.tar.gz chromium_src-97785eaf0f3b8f017a38fe738ade818754492483.tar.bz2 |
Switch to standard integer types in media/.
BUG=138542
TBR=dalecurtis@chromium.org
Review URL: https://codereview.chromium.org/1534273002 .
Cr-Commit-Position: refs/heads/master@{#366242}
Diffstat (limited to 'media/cast/logging')
-rw-r--r-- | media/cast/logging/encoding_event_subscriber.cc | 5 | ||||
-rw-r--r-- | media/cast/logging/encoding_event_subscriber_unittest.cc | 2 | ||||
-rw-r--r-- | media/cast/logging/log_deserializer.cc | 8 | ||||
-rw-r--r-- | media/cast/logging/log_serializer.cc | 10 | ||||
-rw-r--r-- | media/cast/logging/logging_defines.h | 12 | ||||
-rw-r--r-- | media/cast/logging/receiver_time_offset_estimator_impl.cc | 20 | ||||
-rw-r--r-- | media/cast/logging/receiver_time_offset_estimator_impl.h | 12 | ||||
-rw-r--r-- | media/cast/logging/receiver_time_offset_estimator_impl_unittest.cc | 22 | ||||
-rw-r--r-- | media/cast/logging/serialize_deserialize_test.cc | 11 | ||||
-rw-r--r-- | media/cast/logging/simple_event_subscriber.cc | 1 | ||||
-rw-r--r-- | media/cast/logging/stats_event_subscriber.cc | 16 | ||||
-rw-r--r-- | media/cast/logging/stats_event_subscriber.h | 15 | ||||
-rw-r--r-- | media/cast/logging/stats_event_subscriber_unittest.cc | 26 |
13 files changed, 79 insertions, 81 deletions
diff --git a/media/cast/logging/encoding_event_subscriber.cc b/media/cast/logging/encoding_event_subscriber.cc index 82ec06f..a393c22 100644 --- a/media/cast/logging/encoding_event_subscriber.cc +++ b/media/cast/logging/encoding_event_subscriber.cc @@ -103,12 +103,13 @@ void EncodingEventSubscriber::OnReceiveFrameEvent( } else if (frame_event.type == FRAME_ENCODED) { event_proto->set_encoded_frame_size(frame_event.size); if (frame_event.encoder_cpu_utilization >= 0.0) { - event_proto->set_encoder_cpu_percent_utilized(base::saturated_cast<int32>( + event_proto->set_encoder_cpu_percent_utilized( + base::saturated_cast<int32_t>( frame_event.encoder_cpu_utilization * 100.0 + 0.5)); } if (frame_event.idealized_bitrate_utilization >= 0.0) { event_proto->set_idealized_bitrate_percent_utilized( - base::saturated_cast<int32>( + base::saturated_cast<int32_t>( frame_event.idealized_bitrate_utilization * 100.0 + 0.5)); } if (frame_event.media_type == VIDEO_EVENT) { diff --git a/media/cast/logging/encoding_event_subscriber_unittest.cc b/media/cast/logging/encoding_event_subscriber_unittest.cc index 123a8fe..cfcbb34 100644 --- a/media/cast/logging/encoding_event_subscriber_unittest.cc +++ b/media/cast/logging/encoding_event_subscriber_unittest.cc @@ -19,7 +19,7 @@ using media::cast::proto::LogMetadata; namespace { -int64 InMilliseconds(base::TimeTicks event_time) { +int64_t InMilliseconds(base::TimeTicks event_time) { return (event_time - base::TimeTicks()).InMilliseconds(); } diff --git a/media/cast/logging/log_deserializer.cc b/media/cast/logging/log_deserializer.cc index 5e5b189..09f74c7 100644 --- a/media/cast/logging/log_deserializer.cc +++ b/media/cast/logging/log_deserializer.cc @@ -72,7 +72,7 @@ bool PopulateDeserializedLog(base::BigEndianReader* reader, int num_frame_events = log->metadata.num_frame_events(); RtpTimestamp relative_rtp_timestamp = 0; - uint16 proto_size = 0; + uint16_t proto_size = 0; for (int i = 0; i < num_frame_events; i++) { if (!reader->ReadU16(&proto_size)) return false; @@ -146,7 +146,7 @@ bool DoDeserializeEvents(const char* data, base::BigEndianReader reader(data, data_bytes); LogMetadata metadata; - uint16 proto_size = 0; + uint16_t proto_size = 0; while (reader.remaining() > 0) { if (!reader.ReadU16(&proto_size)) return false; @@ -186,9 +186,9 @@ bool Uncompress(const char* data, int* uncompressed_bytes) { z_stream stream = {0}; - stream.next_in = reinterpret_cast<uint8*>(const_cast<char*>(data)); + stream.next_in = reinterpret_cast<uint8_t*>(const_cast<char*>(data)); stream.avail_in = data_bytes; - stream.next_out = reinterpret_cast<uint8*>(uncompressed); + stream.next_out = reinterpret_cast<uint8_t*>(uncompressed); stream.avail_out = max_uncompressed_bytes; bool success = false; diff --git a/media/cast/logging/log_serializer.cc b/media/cast/logging/log_serializer.cc index c5cb252..732be17 100644 --- a/media/cast/logging/log_serializer.cc +++ b/media/cast/logging/log_serializer.cc @@ -47,7 +47,7 @@ bool DoSerializeEvents(const LogMetadata& metadata, int proto_size = metadata.ByteSize(); DCHECK(proto_size <= kMaxSerializedProtoBytes); - if (!writer.WriteU16(static_cast<uint16>(proto_size))) + if (!writer.WriteU16(static_cast<uint16_t>(proto_size))) return false; if (!metadata.SerializeToArray(writer.ptr(), writer.remaining())) return false; @@ -73,7 +73,7 @@ bool DoSerializeEvents(const LogMetadata& metadata, DCHECK(proto_size <= kMaxSerializedProtoBytes); // Write size of the proto, then write the proto. - if (!writer.WriteU16(static_cast<uint16>(proto_size))) + if (!writer.WriteU16(static_cast<uint16_t>(proto_size))) return false; if (!frame_event.SerializeToArray(writer.ptr(), writer.remaining())) return false; @@ -97,7 +97,7 @@ bool DoSerializeEvents(const LogMetadata& metadata, DCHECK(proto_size <= kMaxSerializedProtoBytes); // Write size of the proto, then write the proto. - if (!writer.WriteU16(static_cast<uint16>(proto_size))) + if (!writer.WriteU16(static_cast<uint16_t>(proto_size))) return false; if (!packet_event.SerializeToArray(writer.ptr(), writer.remaining())) return false; @@ -124,9 +124,9 @@ bool Compress(char* uncompressed_buffer, Z_DEFAULT_STRATEGY); DCHECK_EQ(Z_OK, result); - stream.next_in = reinterpret_cast<uint8*>(uncompressed_buffer); + stream.next_in = reinterpret_cast<uint8_t*>(uncompressed_buffer); stream.avail_in = uncompressed_bytes; - stream.next_out = reinterpret_cast<uint8*>(output); + stream.next_out = reinterpret_cast<uint8_t*>(output); stream.avail_out = max_output_bytes; // Do a one-shot compression. This will return Z_STREAM_END only if |output| diff --git a/media/cast/logging/logging_defines.h b/media/cast/logging/logging_defines.h index dc29554..607ff0d 100644 --- a/media/cast/logging/logging_defines.h +++ b/media/cast/logging/logging_defines.h @@ -14,9 +14,9 @@ namespace media { namespace cast { -static const uint32 kFrameIdUnknown = 0xFFFFFFFF; +static const uint32_t kFrameIdUnknown = 0xFFFFFFFF; -typedef uint32 RtpTimestamp; +typedef uint32_t RtpTimestamp; enum CastLoggingEvent { UNKNOWN, @@ -53,7 +53,7 @@ struct FrameEvent { ~FrameEvent(); RtpTimestamp rtp_timestamp; - uint32 frame_id; + uint32_t frame_id; // Resolution of the frame. Only set for video FRAME_CAPTURE_END events. int width; @@ -93,9 +93,9 @@ struct PacketEvent { ~PacketEvent(); RtpTimestamp rtp_timestamp; - uint32 frame_id; - uint16 max_packet_id; - uint16 packet_id; + uint32_t frame_id; + uint16_t max_packet_id; + uint16_t packet_id; size_t size; // Time of event logged. diff --git a/media/cast/logging/receiver_time_offset_estimator_impl.cc b/media/cast/logging/receiver_time_offset_estimator_impl.cc index d511654..db80fc4 100644 --- a/media/cast/logging/receiver_time_offset_estimator_impl.cc +++ b/media/cast/logging/receiver_time_offset_estimator_impl.cc @@ -17,23 +17,23 @@ ReceiverTimeOffsetEstimatorImpl::BoundCalculator::BoundCalculator() ReceiverTimeOffsetEstimatorImpl::BoundCalculator::~BoundCalculator() {} void ReceiverTimeOffsetEstimatorImpl::BoundCalculator::SetSent( - uint32 rtp, - uint32 packet_id, + uint32_t rtp, + uint32_t packet_id, bool audio, base::TimeTicks t) { - uint64 key = (static_cast<uint64>(rtp) << 32) | (packet_id << 1) | - static_cast<uint64>(audio); + uint64_t key = (static_cast<uint64_t>(rtp) << 32) | (packet_id << 1) | + static_cast<uint64_t>(audio); events_[key].first = t; CheckUpdate(key); } void ReceiverTimeOffsetEstimatorImpl::BoundCalculator::SetReceived( - uint32 rtp, - uint16 packet_id, + uint32_t rtp, + uint16_t packet_id, bool audio, base::TimeTicks t) { - uint64 key = (static_cast<uint64>(rtp) << 32) | (packet_id << 1) | - static_cast<uint64>(audio); + uint64_t key = (static_cast<uint64_t>(rtp) << 32) | (packet_id << 1) | + static_cast<uint64_t>(audio); events_[key].second = t; CheckUpdate(key); } @@ -53,8 +53,8 @@ void ReceiverTimeOffsetEstimatorImpl::BoundCalculator::UpdateBound( has_bound_ = true; } -void ReceiverTimeOffsetEstimatorImpl::BoundCalculator::CheckUpdate( - uint64 key) { + void ReceiverTimeOffsetEstimatorImpl::BoundCalculator::CheckUpdate( + uint64_t key) { const TimeTickPair& ticks = events_[key]; if (!ticks.first.is_null() && !ticks.second.is_null()) { UpdateBound(ticks.first, ticks.second); diff --git a/media/cast/logging/receiver_time_offset_estimator_impl.h b/media/cast/logging/receiver_time_offset_estimator_impl.h index c2b6455..77d5275 100644 --- a/media/cast/logging/receiver_time_offset_estimator_impl.h +++ b/media/cast/logging/receiver_time_offset_estimator_impl.h @@ -58,26 +58,26 @@ class ReceiverTimeOffsetEstimatorImpl : public ReceiverTimeOffsetEstimator { class BoundCalculator { public: typedef std::pair<base::TimeTicks, base::TimeTicks> TimeTickPair; - typedef std::map<uint64, TimeTickPair> EventMap; + typedef std::map<uint64_t, TimeTickPair> EventMap; BoundCalculator(); ~BoundCalculator(); bool has_bound() const { return has_bound_; } base::TimeDelta bound() const { return bound_; } - void SetSent(uint32 rtp, - uint32 packet_id, + void SetSent(uint32_t rtp, + uint32_t packet_id, bool audio, base::TimeTicks t); - void SetReceived(uint32 rtp, - uint16 packet_id, + void SetReceived(uint32_t rtp, + uint16_t packet_id, bool audio, base::TimeTicks t); private: void UpdateBound(base::TimeTicks a, base::TimeTicks b); - void CheckUpdate(uint64 key); + void CheckUpdate(uint64_t key); private: EventMap events_; diff --git a/media/cast/logging/receiver_time_offset_estimator_impl_unittest.cc b/media/cast/logging/receiver_time_offset_estimator_impl_unittest.cc index 2cbaafd..eab8ff3 100644 --- a/media/cast/logging/receiver_time_offset_estimator_impl_unittest.cc +++ b/media/cast/logging/receiver_time_offset_estimator_impl_unittest.cc @@ -50,7 +50,7 @@ class ReceiverTimeOffsetEstimatorImplTest : public ::testing::Test { // Event C occurred at sender time 60ms. // Then the bound after all 3 events have arrived is [130-60=70, 130-20=110]. TEST_F(ReceiverTimeOffsetEstimatorImplTest, EstimateOffset) { - int64 true_offset_ms = 100; + int64_t true_offset_ms = 100; receiver_clock_.Advance(base::TimeDelta::FromMilliseconds(true_offset_ms)); base::TimeDelta lower_bound; @@ -59,7 +59,7 @@ TEST_F(ReceiverTimeOffsetEstimatorImplTest, EstimateOffset) { EXPECT_FALSE(estimator_.GetReceiverOffsetBounds(&lower_bound, &upper_bound)); RtpTimestamp rtp_timestamp = 0; - uint32 frame_id = 0; + uint32_t frame_id = 0; AdvanceClocks(base::TimeDelta::FromMilliseconds(20)); @@ -122,8 +122,8 @@ TEST_F(ReceiverTimeOffsetEstimatorImplTest, EstimateOffset) { EXPECT_TRUE(estimator_.GetReceiverOffsetBounds(&lower_bound, &upper_bound)); - int64 lower_bound_ms = lower_bound.InMilliseconds(); - int64 upper_bound_ms = upper_bound.InMilliseconds(); + int64_t lower_bound_ms = lower_bound.InMilliseconds(); + int64_t upper_bound_ms = upper_bound.InMilliseconds(); EXPECT_EQ(70, lower_bound_ms); EXPECT_EQ(110, upper_bound_ms); EXPECT_GE(true_offset_ms, lower_bound_ms); @@ -133,7 +133,7 @@ TEST_F(ReceiverTimeOffsetEstimatorImplTest, EstimateOffset) { // Same scenario as above, but event C arrives before event B. It doesn't mean // event C occurred before event B. TEST_F(ReceiverTimeOffsetEstimatorImplTest, EventCArrivesBeforeEventB) { - int64 true_offset_ms = 100; + int64_t true_offset_ms = 100; receiver_clock_.Advance(base::TimeDelta::FromMilliseconds(true_offset_ms)); base::TimeDelta lower_bound; @@ -142,7 +142,7 @@ TEST_F(ReceiverTimeOffsetEstimatorImplTest, EventCArrivesBeforeEventB) { EXPECT_FALSE(estimator_.GetReceiverOffsetBounds(&lower_bound, &upper_bound)); RtpTimestamp rtp_timestamp = 0; - uint32 frame_id = 0; + uint32_t frame_id = 0; AdvanceClocks(base::TimeDelta::FromMilliseconds(20)); @@ -208,8 +208,8 @@ TEST_F(ReceiverTimeOffsetEstimatorImplTest, EventCArrivesBeforeEventB) { EXPECT_TRUE(estimator_.GetReceiverOffsetBounds(&lower_bound, &upper_bound)); - int64 lower_bound_ms = lower_bound.InMilliseconds(); - int64 upper_bound_ms = upper_bound.InMilliseconds(); + int64_t lower_bound_ms = lower_bound.InMilliseconds(); + int64_t upper_bound_ms = upper_bound.InMilliseconds(); EXPECT_EQ(70, lower_bound_ms); EXPECT_EQ(110, upper_bound_ms); EXPECT_GE(true_offset_ms, lower_bound_ms); @@ -217,7 +217,7 @@ TEST_F(ReceiverTimeOffsetEstimatorImplTest, EventCArrivesBeforeEventB) { } TEST_F(ReceiverTimeOffsetEstimatorImplTest, MultipleIterations) { - int64 true_offset_ms = 100; + int64_t true_offset_ms = 100; receiver_clock_.Advance(base::TimeDelta::FromMilliseconds(true_offset_ms)); base::TimeDelta lower_bound; @@ -387,8 +387,8 @@ TEST_F(ReceiverTimeOffsetEstimatorImplTest, MultipleIterations) { cast_environment_->logger()->DispatchFrameEvent(ack_event.Pass()); EXPECT_TRUE(estimator_.GetReceiverOffsetBounds(&lower_bound, &upper_bound)); - int64 lower_bound_ms = lower_bound.InMilliseconds(); - int64 upper_bound_ms = upper_bound.InMilliseconds(); + int64_t lower_bound_ms = lower_bound.InMilliseconds(); + int64_t upper_bound_ms = upper_bound.InMilliseconds(); EXPECT_GT(lower_bound_ms, 90); EXPECT_LE(lower_bound_ms, true_offset_ms); EXPECT_LT(upper_bound_ms, 150); diff --git a/media/cast/logging/serialize_deserialize_test.cc b/media/cast/logging/serialize_deserialize_test.cc index f1766d0..aa4ba1d 100644 --- a/media/cast/logging/serialize_deserialize_test.cc +++ b/media/cast/logging/serialize_deserialize_test.cc @@ -31,7 +31,7 @@ const media::cast::CastLoggingEvent kVideoPacketEvents[] = { const int kWidth[] = {1280, 1280, 1280, 1280, 1920, 1920, 1920, 1920}; const int kHeight[] = {720, 720, 720, 720, 1080, 1080, 1080, 1080}; const int kEncodedFrameSize[] = {512, 425, 399, 400, 237}; -const int64 kDelayMillis[] = {15, 4, 8, 42, 23, 16}; +const int64_t kDelayMillis[] = {15, 4, 8, 42, 23, 16}; const int kEncoderCPUPercentUtilized[] = {10, 9, 42, 3, 11, 12, 15, 7}; const int kIdealizedBitratePercentUtilized[] = {9, 9, 9, 15, 36, 38, 35, 40}; @@ -55,12 +55,12 @@ class SerializeDeserializeTest : public ::testing::Test { metadata_.set_num_frame_events(10); metadata_.set_num_packet_events(10); - int64 event_time_ms = 0; + int64_t event_time_ms = 0; // Insert frame and packet events with RTP timestamps 0, 90, 180, ... for (int i = 0; i < metadata_.num_frame_events(); i++) { linked_ptr<AggregatedFrameEvent> frame_event(new AggregatedFrameEvent); frame_event->set_relative_rtp_timestamp(i * 90); - for (uint32 event_index = 0; event_index < arraysize(kVideoFrameEvents); + for (uint32_t event_index = 0; event_index < arraysize(kVideoFrameEvents); ++event_index) { frame_event->add_event_type( ToProtoEventType(kVideoFrameEvents[event_index])); @@ -90,9 +90,8 @@ class SerializeDeserializeTest : public ::testing::Test { BasePacketEvent* base_event = packet_event->add_base_packet_event(); base_event->set_packet_id(packet_id); packet_id++; - for (uint32 event_index = 0; - event_index < arraysize(kVideoPacketEvents); - ++event_index) { + for (uint32_t event_index = 0; + event_index < arraysize(kVideoPacketEvents); ++event_index) { base_event->add_event_type( ToProtoEventType(kVideoPacketEvents[event_index])); base_event->add_event_timestamp_ms(event_time_ms); diff --git a/media/cast/logging/simple_event_subscriber.cc b/media/cast/logging/simple_event_subscriber.cc index cad9956..7146f64 100644 --- a/media/cast/logging/simple_event_subscriber.cc +++ b/media/cast/logging/simple_event_subscriber.cc @@ -4,7 +4,6 @@ #include "media/cast/logging/simple_event_subscriber.h" - #include "base/logging.h" namespace media { diff --git a/media/cast/logging/stats_event_subscriber.cc b/media/cast/logging/stats_event_subscriber.cc index a254e63..ff5e6f8 100644 --- a/media/cast/logging/stats_event_subscriber.cc +++ b/media/cast/logging/stats_event_subscriber.cc @@ -35,9 +35,9 @@ bool IsReceiverEvent(CastLoggingEvent event) { } // namespace -StatsEventSubscriber::SimpleHistogram::SimpleHistogram(int64 min, - int64 max, - int64 width) +StatsEventSubscriber::SimpleHistogram::SimpleHistogram(int64_t min, + int64_t max, + int64_t width) : min_(min), max_(max), width_(width), buckets_((max - min) / width + 2) { CHECK_GT(buckets_.size(), 2u); CHECK_EQ(0, (max_ - min_) % width_); @@ -46,7 +46,7 @@ StatsEventSubscriber::SimpleHistogram::SimpleHistogram(int64 min, StatsEventSubscriber::SimpleHistogram::~SimpleHistogram() { } -void StatsEventSubscriber::SimpleHistogram::Add(int64 sample) { +void StatsEventSubscriber::SimpleHistogram::Add(int64_t sample) { if (sample < min_) { ++buckets_.front(); } else if (sample >= max_) { @@ -78,8 +78,8 @@ StatsEventSubscriber::SimpleHistogram::GetHistogram() const { if (!buckets_[i]) continue; bucket.reset(new base::DictionaryValue); - int64 lower = min_ + (i - 1) * width_; - int64 upper = lower + width_ - 1; + int64_t lower = min_ + (i - 1) * width_; + int64_t upper = lower + width_ - 1; bucket->SetInteger( base::StringPrintf("%" PRId64 "-%" PRId64, lower, upper), buckets_[i]); @@ -596,7 +596,7 @@ void StatsEventSubscriber::UpdateLastResponseTime( void StatsEventSubscriber::ErasePacketSentTime( const PacketEvent& packet_event) { - std::pair<RtpTimestamp, uint16> key( + std::pair<RtpTimestamp, uint16_t> key( std::make_pair(packet_event.rtp_timestamp, packet_event.packet_id)); packet_sent_times_.erase(key); } @@ -622,7 +622,7 @@ void StatsEventSubscriber::RecordPacketRelatedLatencies( if (!GetReceiverOffset(&receiver_offset)) return; - std::pair<RtpTimestamp, uint16> key( + std::pair<RtpTimestamp, uint16_t> key( std::make_pair(packet_event.rtp_timestamp, packet_event.packet_id)); PacketEventTimeMap::iterator it = packet_sent_times_.find(key); if (it == packet_sent_times_.end()) { diff --git a/media/cast/logging/stats_event_subscriber.h b/media/cast/logging/stats_event_subscriber.h index 36d5110..c1a1e19 100644 --- a/media/cast/logging/stats_event_subscriber.h +++ b/media/cast/logging/stats_event_subscriber.h @@ -90,20 +90,20 @@ class StatsEventSubscriber : public RawEventSubscriber { // Overflow bucket: >= max // |min| must be less than |max|. // |width| must divide |max - min| evenly. - SimpleHistogram(int64 min, int64 max, int64 width); + SimpleHistogram(int64_t min, int64_t max, int64_t width); ~SimpleHistogram(); - void Add(int64 sample); + void Add(int64_t sample); void Reset(); scoped_ptr<base::ListValue> GetHistogram() const; private: - int64 min_; - int64 max_; - int64 width_; + int64_t min_; + int64_t max_; + int64_t width_; std::vector<int> buckets_; }; @@ -183,9 +183,8 @@ class StatsEventSubscriber : public RawEventSubscriber { typedef std::map<CastStat, double> StatsMap; typedef std::map<CastStat, linked_ptr<SimpleHistogram> > HistogramMap; typedef std::map<RtpTimestamp, FrameInfo> FrameInfoMap; - typedef std::map< - std::pair<RtpTimestamp, uint16>, - std::pair<base::TimeTicks, CastLoggingEvent> > + typedef std::map<std::pair<RtpTimestamp, uint16_t>, + std::pair<base::TimeTicks, CastLoggingEvent>> PacketEventTimeMap; typedef std::map<CastLoggingEvent, FrameLogStats> FrameStatsMap; typedef std::map<CastLoggingEvent, PacketLogStats> PacketStatsMap; diff --git a/media/cast/logging/stats_event_subscriber_unittest.cc b/media/cast/logging/stats_event_subscriber_unittest.cc index d649c89..0cec20f 100644 --- a/media/cast/logging/stats_event_subscriber_unittest.cc +++ b/media/cast/logging/stats_event_subscriber_unittest.cc @@ -67,8 +67,8 @@ class StatsEventSubscriberTest : public ::testing::Test { TEST_F(StatsEventSubscriberTest, CaptureEncode) { Init(VIDEO_EVENT); - uint32 rtp_timestamp = 0; - uint32 frame_id = 0; + uint32_t rtp_timestamp = 0; + uint32_t frame_id = 0; int extra_frames = 50; // Only the first |extra_frames| frames logged will be taken into account // when computing dropped frames. @@ -147,8 +147,8 @@ TEST_F(StatsEventSubscriberTest, CaptureEncode) { TEST_F(StatsEventSubscriberTest, Encode) { Init(VIDEO_EVENT); - uint32 rtp_timestamp = 0; - uint32 frame_id = 0; + uint32_t rtp_timestamp = 0; + uint32_t frame_id = 0; int num_frames = 10; base::TimeTicks start_time = sender_clock_->NowTicks(); AdvanceClocks(base::TimeDelta::FromMicroseconds(35678)); @@ -215,8 +215,8 @@ TEST_F(StatsEventSubscriberTest, Encode) { TEST_F(StatsEventSubscriberTest, Decode) { Init(VIDEO_EVENT); - uint32 rtp_timestamp = 0; - uint32 frame_id = 0; + uint32_t rtp_timestamp = 0; + uint32_t frame_id = 0; int num_frames = 10; base::TimeTicks start_time = sender_clock_->NowTicks(); for (int i = 0; i < num_frames; i++) { @@ -251,8 +251,8 @@ TEST_F(StatsEventSubscriberTest, Decode) { TEST_F(StatsEventSubscriberTest, PlayoutDelay) { Init(VIDEO_EVENT); - uint32 rtp_timestamp = 0; - uint32 frame_id = 0; + uint32_t rtp_timestamp = 0; + uint32_t frame_id = 0; int num_frames = 10; int late_frames = 0; for (int i = 0, delay_ms = -50; i < num_frames; i++, delay_ms += 10) { @@ -286,8 +286,8 @@ TEST_F(StatsEventSubscriberTest, PlayoutDelay) { TEST_F(StatsEventSubscriberTest, E2ELatency) { Init(VIDEO_EVENT); - uint32 rtp_timestamp = 0; - uint32 frame_id = 0; + uint32_t rtp_timestamp = 0; + uint32_t frame_id = 0; int num_frames = 10; base::TimeDelta total_latency; for (int i = 0; i < num_frames; i++) { @@ -333,7 +333,7 @@ TEST_F(StatsEventSubscriberTest, E2ELatency) { TEST_F(StatsEventSubscriberTest, Packets) { Init(VIDEO_EVENT); - uint32 rtp_timestamp = 0; + uint32_t rtp_timestamp = 0; int num_packets = 10; int num_latency_recorded_packets = 0; base::TimeTicks start_time = sender_clock_->NowTicks(); @@ -557,8 +557,8 @@ TEST_F(StatsEventSubscriberTest, Histograms) { Init(VIDEO_EVENT); AdvanceClocks(base::TimeDelta::FromMilliseconds(123)); - uint32 rtp_timestamp = 123; - uint32 frame_id = 0; + uint32_t rtp_timestamp = 123; + uint32_t frame_id = 0; // 10 Frames with capture latency in the bucket of "10-14"ms. // 10 Frames with encode time in the bucket of "15-19"ms. |