From 074edf6016f971e3e59b806d3e00acdd9e8cd423 Mon Sep 17 00:00:00 2001 From: Zhaoliang Ma Date: Tue, 11 May 2021 16:04:46 +0800 Subject: [PATCH] Fix the VideoFrameType of super frame construction in VideoProcessor When VideoFrameType for svc upper layer is kVideoFrameDelta for key pic, the svc unittest will fail due to the wrong frame type for the super frame of first key picture. Bug: None Change-Id: Iff026aaecb73890d3c45d2c88c9654a12d6fe3bf Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/216461 Reviewed-by: Ilya Nikolaevskiy Commit-Queue: Zhaoliang Ma Cr-Commit-Position: refs/heads/master@{#33986} --- modules/video_coding/codecs/test/videoprocessor.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/modules/video_coding/codecs/test/videoprocessor.cc b/modules/video_coding/codecs/test/videoprocessor.cc index a4918ae73d..23eadfc0db 100644 --- a/modules/video_coding/codecs/test/videoprocessor.cc +++ b/modules/video_coding/codecs/test/videoprocessor.cc @@ -650,6 +650,8 @@ const webrtc::EncodedImage* VideoProcessor::BuildAndStoreSuperframe( EncodedImage copied_image = encoded_image; copied_image.SetEncodedData(buffer); + if (base_image.size()) + copied_image._frameType = base_image._frameType; // Replace previous EncodedImage for this spatial layer. merged_encoded_frames_.at(spatial_idx) = std::move(copied_image);