Commit 912ac6ea authored by Takumi Fujimoto's avatar Takumi Fujimoto Committed by Commit Bot

Fix hardware encoding for cast mirroring on CrOS

Fix a bug where a scoped_refptr was incorrectly scoped in an if-block,
causing encoding to fail.

Bug: 991287
Change-Id: Iebce34a1349c968bc808ac5a225ae33df6845c73
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1748079Reviewed-by: default avatarmark a. foltz <mfoltz@chromium.org>
Reviewed-by: default avatarYuri Wiitala <miu@chromium.org>
Commit-Queue: Takumi Fujimoto <takumif@chromium.org>
Cr-Commit-Position: refs/heads/master@{#686603}
parent 1ab167c2
...@@ -208,7 +208,7 @@ class ExternalVideoEncoder::VEAClientImpl ...@@ -208,7 +208,7 @@ class ExternalVideoEncoder::VEAClientImpl
input_buffers_[index].get(); input_buffers_[index].get();
DCHECK(input_buffer->first.IsValid()); DCHECK(input_buffer->first.IsValid());
DCHECK(input_buffer->second.IsValid()); DCHECK(input_buffer->second.IsValid());
scoped_refptr<media::VideoFrame> frame = VideoFrame::WrapExternalData( frame = VideoFrame::WrapExternalData(
video_frame->format(), frame_coded_size_, video_frame->visible_rect(), video_frame->format(), frame_coded_size_, video_frame->visible_rect(),
video_frame->visible_rect().size(), video_frame->visible_rect().size(),
input_buffer->second.GetMemoryAsSpan<uint8_t>().data(), input_buffer->second.GetMemoryAsSpan<uint8_t>().data(),
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment