aboutsummaryrefslogtreecommitdiff
path: root/webrtc/modules/audio_coding/neteq/tools/rtc_event_log_source.cc
diff options
context:
space:
mode:
authorIvo Creusen <ivoc@webrtc.org>2015-10-08 18:07:41 +0200
committerIvo Creusen <ivoc@webrtc.org>2015-10-08 16:07:53 +0000
commit301aaed813b55e28c12e89bb58ae8f8d8136c47e (patch)
treea2def3443a1031d41bc030f44f91f3c056db155a /webrtc/modules/audio_coding/neteq/tools/rtc_event_log_source.cc
parent8ac544e811439f79b2ec0c676f383ddc51ef2ed5 (diff)
downloadwebrtc-301aaed813b55e28c12e89bb58ae8f8d8136c47e.tar.gz
Update to the RtcEventLog protobuf to remove the DebugEvent message.
This CL restructures the RtcEventLog protobuf format, by removing the DebugEvent message. This is done by moving the LOG_START and LOG_END events to the EventType enum and making a seperate message for audio playout events. In addition to these changes, some fields were added to the AudioReceiveConfig and AudioSendConfig messages, but these are for future use and are not currently logged yet. This is a follow-up to CL 1340283002 which adds a SSRC to AudioPlayout events in the RtcEventLog. BUG=webrtc:4741 R=henrik.lundin@webrtc.org, stefan@webrtc.org, terelius@webrtc.org Review URL: https://codereview.webrtc.org/1348113003 . Cr-Commit-Position: refs/heads/master@{#10221}
Diffstat (limited to 'webrtc/modules/audio_coding/neteq/tools/rtc_event_log_source.cc')
-rw-r--r--webrtc/modules/audio_coding/neteq/tools/rtc_event_log_source.cc19
1 files changed, 10 insertions, 9 deletions
diff --git a/webrtc/modules/audio_coding/neteq/tools/rtc_event_log_source.cc b/webrtc/modules/audio_coding/neteq/tools/rtc_event_log_source.cc
index bfd49d3cec..9b17ba8f64 100644
--- a/webrtc/modules/audio_coding/neteq/tools/rtc_event_log_source.cc
+++ b/webrtc/modules/audio_coding/neteq/tools/rtc_event_log_source.cc
@@ -47,16 +47,16 @@ const rtclog::RtpPacket* GetRtpPacket(const rtclog::Event& event) {
return &rtp_packet;
}
-const rtclog::DebugEvent* GetAudioOutputEvent(const rtclog::Event& event) {
- if (!event.has_type() || event.type() != rtclog::Event::DEBUG_EVENT)
+const rtclog::AudioPlayoutEvent* GetAudioPlayoutEvent(
+ const rtclog::Event& event) {
+ if (!event.has_type() || event.type() != rtclog::Event::AUDIO_PLAYOUT_EVENT)
return nullptr;
- if (!event.has_timestamp_us() || !event.has_debug_event())
+ if (!event.has_timestamp_us() || !event.has_audio_playout_event())
return nullptr;
- const rtclog::DebugEvent& debug_event = event.debug_event();
- if (!debug_event.has_type() ||
- debug_event.type() != rtclog::DebugEvent::AUDIO_PLAYOUT)
+ const rtclog::AudioPlayoutEvent& playout_event = event.audio_playout_event();
+ if (!playout_event.has_local_ssrc())
return nullptr;
- return &debug_event;
+ return &playout_event;
}
} // namespace
@@ -107,9 +107,10 @@ Packet* RtcEventLogSource::NextPacket() {
int64_t RtcEventLogSource::NextAudioOutputEventMs() {
while (audio_output_index_ < event_log_->stream_size()) {
const rtclog::Event& event = event_log_->stream(audio_output_index_);
- const rtclog::DebugEvent* debug_event = GetAudioOutputEvent(event);
+ const rtclog::AudioPlayoutEvent* playout_event =
+ GetAudioPlayoutEvent(event);
audio_output_index_++;
- if (debug_event)
+ if (playout_event)
return event.timestamp_us() / 1000;
}
return std::numeric_limits<int64_t>::max();