From acb4cba5b1a36e226717827036811c49e846499c Mon Sep 17 00:00:00 2001 From: Sergey Silkin Date: Tue, 8 May 2018 17:16:39 +0200 Subject: [PATCH] Ignore spatial index. This workaround allows to decode VP9 SVC streams with partially enabled inter-layer prediction. This change won't affect conventional SVC (inter-layer prediction is enabled for all frames) since spatial index was always zero in this case. Bug: webrtc:9249 Change-Id: If6ff26a18b7cf543ec9e7f70b9239e9edff250b5 Reviewed-on: https://webrtc-review.googlesource.com/74924 Commit-Queue: Sergey Silkin Reviewed-by: Philip Eliasson Reviewed-by: Stefan Holmer Cr-Commit-Position: refs/heads/master@{#23177} --- video/video_receive_stream.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/video/video_receive_stream.cc b/video/video_receive_stream.cc index bf4038eb98..0e596beae3 100644 --- a/video/video_receive_stream.cc +++ b/video/video_receive_stream.cc @@ -354,6 +354,10 @@ void VideoReceiveStream::RequestKeyFrame() { void VideoReceiveStream::OnCompleteFrame( std::unique_ptr frame) { + // TODO(webrtc:9249): Workaround to allow decoding of VP9 SVC stream with + // partially enabled inter-layer prediction. + frame->id.spatial_layer = 0; + int64_t last_continuous_pid = frame_buffer_->InsertFrame(std::move(frame)); if (last_continuous_pid != -1) rtp_video_stream_receiver_.FrameContinuous(last_continuous_pid);