Clean up decoders when stopping video receive stream.

This updates VideoReceiveStream2::Stop() to symmetrically tear down
state that's built up in VideoReceiveStream2::Start().

Bug: webrtc:11993, webrtc:14486
Change-Id: I41f4feea5584e5baaeed2143432136f8b9761321
Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/272537
Commit-Queue: Tomas Gunnarsson <tommi@webrtc.org>
Reviewed-by: Danil Chapovalov <danilchap@webrtc.org>
Cr-Commit-Position: refs/heads/main@{#38244}
This commit is contained in:
Tommi
2022-09-29 12:24:02 +02:00
committed by WebRTC LUCI CQ
parent 2c1b4dac57
commit 96c1a9b9e2
14 changed files with 318 additions and 18 deletions

View File

@ -102,4 +102,14 @@ void VideoReceiver2::RegisterReceiveCodec(
codec_database_.RegisterReceiveCodec(payload_type, settings);
}
void VideoReceiver2::DeregisterReceiveCodec(uint8_t payload_type) {
RTC_DCHECK_RUN_ON(&construction_sequence_checker_);
codec_database_.DeregisterReceiveCodec(payload_type);
}
void VideoReceiver2::DeregisterReceiveCodecs() {
RTC_DCHECK_RUN_ON(&construction_sequence_checker_);
codec_database_.DeregisterReceiveCodecs();
}
} // namespace webrtc