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

Unified Diff: media/cast/logging/logging_impl.cc

Issue 270493003: Cast: Deduplicate event types in cast library. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 6 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « media/cast/logging/logging_impl.h ('k') | media/cast/logging/logging_impl_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: media/cast/logging/logging_impl.cc
diff --git a/media/cast/logging/logging_impl.cc b/media/cast/logging/logging_impl.cc
index 7d975e268e158df4670061105c65d5e2540da74c..1143d1be217bb833cc4872a317caa46a8dad16e9 100644
--- a/media/cast/logging/logging_impl.cc
+++ b/media/cast/logging/logging_impl.cc
@@ -19,33 +19,39 @@ LoggingImpl::LoggingImpl() {
LoggingImpl::~LoggingImpl() {}
void LoggingImpl::InsertFrameEvent(const base::TimeTicks& time_of_event,
- CastLoggingEvent event, uint32 rtp_timestamp,
+ CastLoggingEvent event,
+ EventMediaType event_media_type,
+ uint32 rtp_timestamp,
uint32 frame_id) {
DCHECK(thread_checker_.CalledOnValidThread());
- raw_.InsertFrameEvent(time_of_event, event, rtp_timestamp, frame_id);
+ raw_.InsertFrameEvent(time_of_event, event, event_media_type,
+ rtp_timestamp, frame_id);
}
void LoggingImpl::InsertEncodedFrameEvent(const base::TimeTicks& time_of_event,
CastLoggingEvent event,
+ EventMediaType event_media_type,
uint32 rtp_timestamp,
uint32 frame_id, int frame_size,
bool key_frame,
int target_bitrate) {
DCHECK(thread_checker_.CalledOnValidThread());
- raw_.InsertEncodedFrameEvent(time_of_event, event, rtp_timestamp, frame_id,
- frame_size, key_frame, target_bitrate);
+ raw_.InsertEncodedFrameEvent(time_of_event, event, event_media_type,
+ rtp_timestamp, frame_id, frame_size, key_frame, target_bitrate);
}
void LoggingImpl::InsertFrameEventWithDelay(
const base::TimeTicks& time_of_event, CastLoggingEvent event,
- uint32 rtp_timestamp, uint32 frame_id, base::TimeDelta delay) {
+ EventMediaType event_media_type, uint32 rtp_timestamp, uint32 frame_id,
+ base::TimeDelta delay) {
DCHECK(thread_checker_.CalledOnValidThread());
- raw_.InsertFrameEventWithDelay(time_of_event, event, rtp_timestamp,
- frame_id, delay);
+ raw_.InsertFrameEventWithDelay(time_of_event, event, event_media_type,
+ rtp_timestamp, frame_id, delay);
}
void LoggingImpl::InsertSinglePacketEvent(const base::TimeTicks& time_of_event,
CastLoggingEvent event,
+ EventMediaType event_media_type,
const Packet& packet) {
DCHECK(thread_checker_.CalledOnValidThread());
@@ -64,6 +70,7 @@ void LoggingImpl::InsertSinglePacketEvent(const base::TimeTicks& time_of_event,
// rtp_timestamp is enough - no need for frame_id as well.
InsertPacketEvent(time_of_event,
event,
+ event_media_type,
rtp_timestamp,
kFrameIdUnknown,
packet_id,
@@ -73,22 +80,25 @@ void LoggingImpl::InsertSinglePacketEvent(const base::TimeTicks& time_of_event,
void LoggingImpl::InsertPacketListEvent(const base::TimeTicks& time_of_event,
CastLoggingEvent event,
+ EventMediaType event_media_type,
const PacketList& packets) {
DCHECK(thread_checker_.CalledOnValidThread());
for (PacketList::const_iterator it = packets.begin(); it != packets.end();
++it) {
- InsertSinglePacketEvent(time_of_event, event, (*it)->data);
+ InsertSinglePacketEvent(time_of_event, event, event_media_type,
+ (*it)->data);
}
}
void LoggingImpl::InsertPacketEvent(const base::TimeTicks& time_of_event,
CastLoggingEvent event,
+ EventMediaType event_media_type,
uint32 rtp_timestamp, uint32 frame_id,
uint16 packet_id, uint16 max_packet_id,
size_t size) {
DCHECK(thread_checker_.CalledOnValidThread());
- raw_.InsertPacketEvent(time_of_event, event, rtp_timestamp, frame_id,
- packet_id, max_packet_id, size);
+ raw_.InsertPacketEvent(time_of_event, event, event_media_type,
+ rtp_timestamp, frame_id, packet_id, max_packet_id, size);
}
void LoggingImpl::AddRawEventSubscriber(RawEventSubscriber* subscriber) {
« no previous file with comments | « media/cast/logging/logging_impl.h ('k') | media/cast/logging/logging_impl_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698