Revert "Create new API for RtcEventLogParser."
This reverts commit 9e336ec0b8a77c3461d13677cff3563c11c88daa.
Reason for revert: Code can accidentally include the deprecated parser but link with the new one, or vice versa. Reverting to fix naming.
Original change's description:
> Create new API for RtcEventLogParser.
>
> The new API stores events gathered by event type. For example, it is
> possible to ask fo a list of all incoming RTCP messages or all audio
> playout events.
>
> The new API is experimental and may change over next few weeks. Once
> it has stabilized and all unit tests and existing tools have been
> ported to the new API, the old one will be removed.
>
> This CL also updates the event_log_visualizer tool to use the new
> parser API. This is not a funcional change except for:
> - Incoming and outgoing audio level are now drawn in two separate plots.
> - Incoming and outgoing timstamps are now drawn in two separate plots.
> - RTCP count is no longer split into Video and Audio. It also counts
> all RTCP packets rather than only specific message types.
> - Slight timing difference in sendside BWE simulation due to only
> iterating over transport feedbacks and not over all RTCP packets.
> This timing changes are not visible in the plots.
>
>
> Media type for RTCP messages might not be identified correctly by
> rtc_event_log2text anymore. On the other hand, assigning a specific
> media type to an RTCP packet was a bit hacky to begin with.
>
> Bug: webrtc:8111
> Change-Id: I8e7168302beb69b2e163a097a2a142b86dd4a26b
> Reviewed-on: https://webrtc-review.googlesource.com/60865
> Reviewed-by: Minyue Li <minyue@webrtc.org>
> Reviewed-by: Sebastian Jansson <srte@webrtc.org>
> Commit-Queue: Björn Terelius <terelius@webrtc.org>
> Cr-Commit-Position: refs/heads/master@{#23015}
TBR=terelius@webrtc.org,srte@webrtc.org,minyue@webrtc.org
Change-Id: Ib4bbcf0563423675a3cc1dce59ebf665e0c5dae9
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: webrtc:8111
Reviewed-on: https://webrtc-review.googlesource.com/72500
Reviewed-by: Björn Terelius <terelius@webrtc.org>
Commit-Queue: Björn Terelius <terelius@webrtc.org>
Cr-Commit-Position: refs/heads/master@{#23026}
diff --git a/rtc_tools/event_log_visualizer/triage_notifications.h b/rtc_tools/event_log_visualizer/triage_notifications.h
index 49e0620..641e2ae 100644
--- a/rtc_tools/event_log_visualizer/triage_notifications.h
+++ b/rtc_tools/event_log_visualizer/triage_notifications.h
@@ -14,136 +14,130 @@
#include <string>
namespace webrtc {
+namespace plotting {
-class IncomingRtpReceiveTimeGap {
+class TriageNotification {
+ public:
+ TriageNotification() : time_seconds_() {}
+ explicit TriageNotification(float time_seconds)
+ : time_seconds_(time_seconds) {}
+ virtual ~TriageNotification() = default;
+ virtual std::string ToString() = 0;
+ rtc::Optional<float> Time() { return time_seconds_; }
+
+ private:
+ rtc::Optional<float> time_seconds_;
+};
+
+class IncomingRtpReceiveTimeGap : public TriageNotification {
public:
IncomingRtpReceiveTimeGap(float time_seconds, int64_t duration)
- : time_seconds_(time_seconds), duration_(duration) {}
- float Time() const { return time_seconds_; }
- std::string ToString() const {
+ : TriageNotification(time_seconds), duration_(duration) {}
+ std::string ToString() {
return std::string("No RTP packets received for ") +
std::to_string(duration_) + std::string(" ms");
}
private:
- float time_seconds_;
int64_t duration_;
};
-class IncomingRtcpReceiveTimeGap {
+class IncomingRtcpReceiveTimeGap : public TriageNotification {
public:
IncomingRtcpReceiveTimeGap(float time_seconds, int64_t duration)
- : time_seconds_(time_seconds), duration_(duration) {}
- float Time() const { return time_seconds_; }
- std::string ToString() const {
+ : TriageNotification(time_seconds), duration_(duration) {}
+ std::string ToString() {
return std::string("No RTCP packets received for ") +
std::to_string(duration_) + std::string(" ms");
}
private:
- float time_seconds_;
int64_t duration_;
};
-class OutgoingRtpSendTimeGap {
+class OutgoingRtpSendTimeGap : public TriageNotification {
public:
OutgoingRtpSendTimeGap(float time_seconds, int64_t duration)
- : time_seconds_(time_seconds), duration_(duration) {}
- float Time() const { return time_seconds_; }
- std::string ToString() const {
+ : TriageNotification(time_seconds), duration_(duration) {}
+ std::string ToString() {
return std::string("No RTP packets sent for ") + std::to_string(duration_) +
std::string(" ms");
}
private:
- float time_seconds_;
int64_t duration_;
};
-class OutgoingRtcpSendTimeGap {
+class OutgoingRtcpSendTimeGap : public TriageNotification {
public:
OutgoingRtcpSendTimeGap(float time_seconds, int64_t duration)
- : time_seconds_(time_seconds), duration_(duration) {}
- float Time() const { return time_seconds_; }
- std::string ToString() const {
+ : TriageNotification(time_seconds), duration_(duration) {}
+ std::string ToString() {
return std::string("No RTCP packets sent for ") +
std::to_string(duration_) + std::string(" ms");
}
private:
- float time_seconds_;
int64_t duration_;
};
-class IncomingSeqNumJump {
+class IncomingSeqNoJump : public TriageNotification {
public:
- IncomingSeqNumJump(float time_seconds, uint32_t ssrc)
- : time_seconds_(time_seconds), ssrc_(ssrc) {}
- float Time() const { return time_seconds_; }
- std::string ToString() const {
+ IncomingSeqNoJump(float time_seconds, uint32_t ssrc)
+ : TriageNotification(time_seconds), ssrc_(ssrc) {}
+ std::string ToString() {
return std::string("Sequence number jumps on incoming SSRC ") +
std::to_string(ssrc_);
}
private:
- float time_seconds_;
-
uint32_t ssrc_;
};
-class IncomingCaptureTimeJump {
+class IncomingCaptureTimeJump : public TriageNotification {
public:
IncomingCaptureTimeJump(float time_seconds, uint32_t ssrc)
- : time_seconds_(time_seconds), ssrc_(ssrc) {}
- float Time() const { return time_seconds_; }
- std::string ToString() const {
+ : TriageNotification(time_seconds), ssrc_(ssrc) {}
+ std::string ToString() {
return std::string("Capture timestamp jumps on incoming SSRC ") +
std::to_string(ssrc_);
}
private:
- float time_seconds_;
-
uint32_t ssrc_;
};
-class OutgoingSeqNoJump {
+class OutgoingSeqNoJump : public TriageNotification {
public:
OutgoingSeqNoJump(float time_seconds, uint32_t ssrc)
- : time_seconds_(time_seconds), ssrc_(ssrc) {}
- float Time() const { return time_seconds_; }
- std::string ToString() const {
+ : TriageNotification(time_seconds), ssrc_(ssrc) {}
+ std::string ToString() {
return std::string("Sequence number jumps on outgoing SSRC ") +
std::to_string(ssrc_);
}
private:
- float time_seconds_;
-
uint32_t ssrc_;
};
-class OutgoingCaptureTimeJump {
+class OutgoingCaptureTimeJump : public TriageNotification {
public:
OutgoingCaptureTimeJump(float time_seconds, uint32_t ssrc)
- : time_seconds_(time_seconds), ssrc_(ssrc) {}
- float Time() const { return time_seconds_; }
- std::string ToString() const {
+ : TriageNotification(time_seconds), ssrc_(ssrc) {}
+ std::string ToString() {
return std::string("Capture timestamp jumps on outgoing SSRC ") +
std::to_string(ssrc_);
}
private:
- float time_seconds_;
-
uint32_t ssrc_;
};
-class OutgoingHighLoss {
+class OutgoingHighLoss : public TriageNotification {
public:
explicit OutgoingHighLoss(double avg_loss_fraction)
: avg_loss_fraction_(avg_loss_fraction) {}
- std::string ToString() const {
+ std::string ToString() {
return std::string("High average loss (") +
std::to_string(avg_loss_fraction_ * 100) +
std::string("%) across the call.");
@@ -153,6 +147,7 @@
double avg_loss_fraction_;
};
+} // namespace plotting
} // namespace webrtc
#endif // RTC_TOOLS_EVENT_LOG_VISUALIZER_TRIAGE_NOTIFICATIONS_H_