Commit b6b37210 authored by Alexandre Courbot's avatar Alexandre Courbot Committed by Commit Bot

media/gpu/v4l2: use config instead of member variable

Using video_profile_ here is not necessary since we also have access
to the configuration. Doing this will let us remove profile_ in the
next CL.

BUG=b:149663704
TEST=vdatest passes on Hana.

Change-Id: I34c6466fb1c6d800d743bfae047f014d39a15342
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2130454
Commit-Queue: Alexandre Courbot <acourbot@chromium.org>
Auto-Submit: Alexandre Courbot <acourbot@chromium.org>
Reviewed-by: default avatarChih-Yu Huang <akahuang@chromium.org>
Cr-Commit-Position: refs/heads/master@{#755303}
parent ac30af98
......@@ -260,7 +260,7 @@ void V4L2VideoDecodeAccelerator::InitializeTask(const Config& config,
if (!config_result)
return;
if (video_profile_ >= H264PROFILE_MIN && video_profile_ <= H264PROFILE_MAX) {
if (config.profile >= H264PROFILE_MIN && config.profile <= H264PROFILE_MAX) {
decoder_h264_parser_.reset(new H264Parser());
}
......@@ -288,7 +288,7 @@ bool V4L2VideoDecodeAccelerator::CheckConfig(const Config& config) {
DCHECK(decoder_thread_.task_runner()->BelongsToCurrentThread());
input_format_fourcc_ =
V4L2Device::VideoCodecProfileToV4L2PixFmt(video_profile_, false);
V4L2Device::VideoCodecProfileToV4L2PixFmt(config.profile, false);
if (!input_format_fourcc_ ||
!device_->Open(V4L2Device::Type::kDecoder, input_format_fourcc_)) {
......
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