Add rtc_ prefix to the event_log_visualizer directory.
No-Try: True Bug: None Change-Id: Iaa2b273ddab6567321f11bf74a91751cbdf957a5 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/146710 Commit-Queue: Mirko Bonadei <mbonadei@webrtc.org> Reviewed-by: Björn Terelius <terelius@webrtc.org> Cr-Commit-Position: refs/heads/master@{#28681}
This commit is contained in:

committed by
Commit Bot

parent
a72d583271
commit
575998c2da
64
rtc_tools/rtc_event_log_visualizer/log_simulation.h
Normal file
64
rtc_tools/rtc_event_log_visualizer/log_simulation.h
Normal file
@ -0,0 +1,64 @@
|
||||
/*
|
||||
* Copyright 2019 The WebRTC project authors. All Rights Reserved.
|
||||
*
|
||||
* Use of this source code is governed by a BSD-style license
|
||||
* that can be found in the LICENSE file in the root of the source
|
||||
* tree. An additional intellectual property rights grant can be found
|
||||
* in the file PATENTS. All contributing project authors may
|
||||
* be found in the AUTHORS file in the root of the source tree.
|
||||
*/
|
||||
#ifndef RTC_TOOLS_RTC_EVENT_LOG_VISUALIZER_LOG_SIMULATION_H_
|
||||
#define RTC_TOOLS_RTC_EVENT_LOG_VISUALIZER_LOG_SIMULATION_H_
|
||||
|
||||
#include <deque>
|
||||
#include <functional>
|
||||
#include <map>
|
||||
#include <memory>
|
||||
#include <vector>
|
||||
|
||||
#include "api/transport/network_control.h"
|
||||
#include "logging/rtc_event_log/rtc_event_log_parser.h"
|
||||
#include "modules/congestion_controller/rtp/transport_feedback_adapter.h"
|
||||
|
||||
namespace webrtc {
|
||||
|
||||
class LogBasedNetworkControllerSimulation {
|
||||
public:
|
||||
explicit LogBasedNetworkControllerSimulation(
|
||||
std::unique_ptr<NetworkControllerFactoryInterface> factory,
|
||||
std::function<void(const NetworkControlUpdate&, Timestamp)>
|
||||
update_handler);
|
||||
~LogBasedNetworkControllerSimulation();
|
||||
void ProcessEventsInLog(const ParsedRtcEventLog& parsed_log_);
|
||||
|
||||
private:
|
||||
struct ProbingStatus {
|
||||
const LoggedBweProbeClusterCreatedEvent event;
|
||||
size_t bytes_sent;
|
||||
size_t packets_sent;
|
||||
};
|
||||
void HandleStateUpdate(const NetworkControlUpdate& update);
|
||||
void ProcessUntil(Timestamp to_time);
|
||||
|
||||
void OnProbeCreated(const LoggedBweProbeClusterCreatedEvent& probe_cluster);
|
||||
void OnPacketSent(const LoggedPacketInfo& packet);
|
||||
void OnFeedback(const LoggedRtcpPacketTransportFeedback& feedback);
|
||||
void OnReceiverReport(const LoggedRtcpPacketReceiverReport& report);
|
||||
void OnIceConfig(const LoggedIceCandidatePairConfig& candidate);
|
||||
RtcEventLogNullImpl null_event_log_;
|
||||
|
||||
const std::function<void(const NetworkControlUpdate&, Timestamp)>
|
||||
update_handler_;
|
||||
std::unique_ptr<NetworkControllerFactoryInterface> factory_;
|
||||
std::unique_ptr<NetworkControllerInterface> controller_;
|
||||
|
||||
Timestamp current_time_ = Timestamp::MinusInfinity();
|
||||
Timestamp last_process_ = Timestamp::MinusInfinity();
|
||||
TransportFeedbackAdapter transport_feedback_;
|
||||
std::deque<ProbingStatus> pending_probes_;
|
||||
std::map<uint32_t, rtcp::ReportBlock> last_report_blocks_;
|
||||
Timestamp last_report_block_time_ = Timestamp::MinusInfinity();
|
||||
};
|
||||
} // namespace webrtc
|
||||
|
||||
#endif // RTC_TOOLS_RTC_EVENT_LOG_VISUALIZER_LOG_SIMULATION_H_
|
Reference in New Issue
Block a user