/* * Copyright (c) 2020 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.
*/
namespace internal { // Declared in video_receive_stream2.h. struct VideoFrameMetaData;
class ReceiveStatisticsProxy : public VideoStreamBufferControllerStatsObserver, public RtcpCnameCallback, public RtcpPacketTypeCounterObserver { public:
ReceiveStatisticsProxy(uint32_t remote_ssrc,
Clock* clock,
TaskQueueBase* worker_thread);
~ReceiveStatisticsProxy() override;
// Called asyncronously on the worker thread as a result of a call to the // above OnDecodedFrame method, which is called back on the thread where // the actual decoding happens. void OnDecodedFrame(const VideoFrameMetaData& frame_meta,
std::optional<uint8_t> qp,
TimeDelta decode_time,
TimeDelta processing_delay,
TimeDelta assembly_time,
VideoContentType content_type,
VideoFrameType frame_type);
// Notification methods that are used to check our internal state and validate // threading assumptions. These are called by VideoReceiveStreamInterface. void DecoderThreadStarting(); void DecoderThreadStopped();
// Produce histograms. Must be called after DecoderThreadStopped(), typically // at the end of the call. void UpdateHistograms(std::optional<int> fraction_lost, const StreamDataCounters& rtp_stats, const StreamDataCounters* rtx_stats);
// Note: The `stats_.rtp_stats` member is not used or populated by this class. mutable VideoReceiveStreamInterface::Stats stats_
RTC_GUARDED_BY(main_thread_); // Same as stats_.ssrc, but const (no lock required). const uint32_t remote_ssrc_;
RateStatistics decode_fps_estimator_ RTC_GUARDED_BY(main_thread_);
RateStatistics renders_fps_estimator_ RTC_GUARDED_BY(main_thread_);
rtc::RateTracker render_fps_tracker_ RTC_GUARDED_BY(main_thread_);
rtc::RateTracker render_pixel_tracker_ RTC_GUARDED_BY(main_thread_);
rtc::SampleCounter sync_offset_counter_ RTC_GUARDED_BY(main_thread_);
rtc::SampleCounter decode_time_counter_ RTC_GUARDED_BY(main_thread_);
rtc::SampleCounter jitter_delay_counter_ RTC_GUARDED_BY(main_thread_);
rtc::SampleCounter target_delay_counter_ RTC_GUARDED_BY(main_thread_);
rtc::SampleCounter current_delay_counter_ RTC_GUARDED_BY(main_thread_);
rtc::SampleCounter oneway_delay_counter_ RTC_GUARDED_BY(main_thread_);
std::unique_ptr<VideoQualityObserver> video_quality_observer_
RTC_GUARDED_BY(main_thread_); mutable rtc::MovingMaxCounter<int> interframe_delay_max_moving_
RTC_GUARDED_BY(main_thread_);
std::map<VideoContentType, ContentSpecificStats> content_specific_stats_
RTC_GUARDED_BY(main_thread_);
MaxCounter freq_offset_counter_ RTC_GUARDED_BY(main_thread_);
QpCounters qp_counters_ RTC_GUARDED_BY(main_thread_);
int64_t avg_rtt_ms_ RTC_GUARDED_BY(main_thread_) = 0; mutable std::map<int64_t, size_t> frame_window_ RTC_GUARDED_BY(main_thread_);
VideoContentType last_content_type_ RTC_GUARDED_BY(&main_thread_);
VideoCodecType last_codec_type_ RTC_GUARDED_BY(main_thread_);
std::optional<int64_t> first_frame_received_time_ms_
RTC_GUARDED_BY(main_thread_);
std::optional<int64_t> first_decoded_frame_time_ms_
RTC_GUARDED_BY(main_thread_);
std::optional<int64_t> last_decoded_frame_time_ms_
RTC_GUARDED_BY(main_thread_);
size_t num_delayed_frames_rendered_ RTC_GUARDED_BY(main_thread_);
int64_t sum_missed_render_deadline_ms_ RTC_GUARDED_BY(main_thread_); // Mutable because calling Max() on MovingMaxCounter is not const. Yet it is // called from const GetStats(). mutable rtc::MovingMaxCounter<TimingFrameInfo> timing_frame_info_counter_
RTC_GUARDED_BY(main_thread_);
std::optional<int> num_unique_frames_ RTC_GUARDED_BY(main_thread_);
std::optional<int64_t> last_estimated_playout_ntp_timestamp_ms_
RTC_GUARDED_BY(main_thread_);
std::optional<int64_t> last_estimated_playout_time_ms_
RTC_GUARDED_BY(main_thread_);
// The thread on which this instance is constructed and some of its main // methods are invoked on such as GetStats().
TaskQueueBase* const worker_thread_;
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.