Delete method VCMJitterBuffer::RegisterStatsCallback
Unused in the legacy VideoCodingModule api since https://webrtc-review.googlesource.com/c/src/+/62101/ and unused by the VideoReceiveStream code path since https://webrtc-review.googlesource.com/c/src/+/128870 Bug: webrtc:7408 Change-Id: I800dba08a6e0e8f5de6169241d217bd5e8e5d0de Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/129961 Reviewed-by: Philip Eliasson <philipel@webrtc.org> Commit-Queue: Niels Moller <nisse@webrtc.org> Cr-Commit-Position: refs/heads/master@{#27319}
This commit is contained in:
@ -84,7 +84,9 @@ class VCMReceiveStatisticsCallback {
|
||||
virtual void OnCompleteFrame(bool is_keyframe,
|
||||
size_t size_bytes,
|
||||
VideoContentType content_type) = 0;
|
||||
// TODO(nisse): Delete.
|
||||
virtual void OnDiscardedPacketsUpdated(int discarded_packets) = 0;
|
||||
// TODO(nisse): Delete.
|
||||
virtual void OnFrameCountsUpdated(const FrameCounts& frame_counts) = 0;
|
||||
virtual void OnFrameBufferTimingsUpdated(int decode_ms,
|
||||
int max_decode_ms,
|
||||
|
@ -234,7 +234,6 @@ VCMJitterBuffer::VCMJitterBuffer(Clock* clock,
|
||||
incomplete_frames_(),
|
||||
last_decoded_state_(),
|
||||
first_packet_since_reset_(true),
|
||||
stats_callback_(nullptr),
|
||||
incoming_frame_rate_(0),
|
||||
incoming_frame_count_(0),
|
||||
time_last_incoming_frame_count_(0),
|
||||
@ -611,8 +610,6 @@ VCMFrameBufferEnum VCMJitterBuffer::InsertPacket(const VCMPacket& packet,
|
||||
if (packet.sizeBytes > 0) {
|
||||
num_discarded_packets_++;
|
||||
num_consecutive_old_packets_++;
|
||||
if (stats_callback_ != NULL)
|
||||
stats_callback_->OnDiscardedPacketsUpdated(num_discarded_packets_);
|
||||
}
|
||||
// Update last decoded sequence number if the packet arrived late and
|
||||
// belongs to a frame with a timestamp equal to the last decoded
|
||||
@ -1071,12 +1068,6 @@ void VCMJitterBuffer::DropPacketsFromNackList(
|
||||
missing_sequence_numbers_.upper_bound(last_decoded_sequence_number));
|
||||
}
|
||||
|
||||
void VCMJitterBuffer::RegisterStatsCallback(
|
||||
VCMReceiveStatisticsCallback* callback) {
|
||||
rtc::CritScope cs(&crit_sect_);
|
||||
stats_callback_ = callback;
|
||||
}
|
||||
|
||||
VCMFrameBuffer* VCMJitterBuffer::GetEmptyFrame() {
|
||||
if (free_frames_.empty()) {
|
||||
if (!TryToIncreaseJitterBufferSize()) {
|
||||
@ -1152,9 +1143,6 @@ void VCMJitterBuffer::CountFrame(const VCMFrameBuffer& frame) {
|
||||
} else {
|
||||
++receive_statistics_.delta_frames;
|
||||
}
|
||||
|
||||
if (stats_callback_ != NULL)
|
||||
stats_callback_->OnFrameCountsUpdated(receive_statistics_);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -190,8 +190,6 @@ class VCMJitterBuffer {
|
||||
// Returns a list of the sequence numbers currently missing.
|
||||
std::vector<uint16_t> GetNackList(bool* request_key_frame);
|
||||
|
||||
void RegisterStatsCallback(VCMReceiveStatisticsCallback* callback);
|
||||
|
||||
private:
|
||||
class SequenceNumberLessThan {
|
||||
public:
|
||||
@ -317,8 +315,6 @@ class VCMJitterBuffer {
|
||||
VCMDecodingState last_decoded_state_ RTC_GUARDED_BY(crit_sect_);
|
||||
bool first_packet_since_reset_;
|
||||
|
||||
// Statistics.
|
||||
VCMReceiveStatisticsCallback* stats_callback_ RTC_GUARDED_BY(crit_sect_);
|
||||
// Frame counts for each type (key, delta, ...)
|
||||
FrameCounts receive_statistics_;
|
||||
// Latest calculated frame rates of incoming stream.
|
||||
|
@ -259,9 +259,4 @@ std::vector<uint16_t> VCMReceiver::NackList(bool* request_key_frame) {
|
||||
return jitter_buffer_.GetNackList(request_key_frame);
|
||||
}
|
||||
|
||||
void VCMReceiver::RegisterStatsCallback(
|
||||
VCMReceiveStatisticsCallback* callback) {
|
||||
jitter_buffer_.RegisterStatsCallback(callback);
|
||||
}
|
||||
|
||||
} // namespace webrtc
|
||||
|
@ -79,8 +79,6 @@ class VCMReceiver {
|
||||
VCMNackMode NackMode() const;
|
||||
std::vector<uint16_t> NackList(bool* request_key_frame);
|
||||
|
||||
void RegisterStatsCallback(VCMReceiveStatisticsCallback* callback);
|
||||
|
||||
void TriggerDecoderShutdown();
|
||||
|
||||
private:
|
||||
|
@ -70,8 +70,6 @@ class VideoReceiver : public Module {
|
||||
void RegisterExternalDecoder(VideoDecoder* externalDecoder,
|
||||
uint8_t payloadType);
|
||||
int32_t RegisterReceiveCallback(VCMReceiveCallback* receiveCallback);
|
||||
int32_t RegisterReceiveStatisticsCallback(
|
||||
VCMReceiveStatisticsCallback* receiveStats);
|
||||
int32_t RegisterFrameTypeCallback(VCMFrameTypeCallback* frameTypeCallback);
|
||||
int32_t RegisterPacketRequestCallback(VCMPacketRequestCallback* callback);
|
||||
|
||||
|
@ -189,18 +189,6 @@ int32_t VideoReceiver::RegisterReceiveCallback(
|
||||
return VCM_OK;
|
||||
}
|
||||
|
||||
int32_t VideoReceiver::RegisterReceiveStatisticsCallback(
|
||||
VCMReceiveStatisticsCallback* receiveStats) {
|
||||
RTC_DCHECK_RUN_ON(&construction_thread_checker_);
|
||||
RTC_DCHECK(!IsDecoderThreadRunning() && !is_attached_to_process_thread_);
|
||||
// |_receiver| is used on both the decoder and module threads.
|
||||
// However, since we make sure that we never do anything on the module thread
|
||||
// when the decoder thread is not running, we don't need a lock for the
|
||||
// |_receiver| here.
|
||||
_receiver.RegisterStatsCallback(receiveStats);
|
||||
return VCM_OK;
|
||||
}
|
||||
|
||||
// Register an externally defined decoder object.
|
||||
void VideoReceiver::RegisterExternalDecoder(VideoDecoder* externalDecoder,
|
||||
uint8_t payloadType) {
|
||||
|
Reference in New Issue
Block a user