Commit d452aaa5 authored by Fritz Koenig's avatar Fritz Koenig Committed by Chromium LUCI CQ

media/gpu/v4l2: Remove unused parameter

V4L2PixFmtToVideoCodecProfiles doesn't need to
know if the caller is an encoder or decoder,
it will do the same thing regardless.

BUG=none
TEST=none

Change-Id: Ib1676b52f58fc63be4d9ee0432b3d60eff8f8305
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2634052
Commit-Queue: Fritz Koenig <frkoenig@chromium.org>
Commit-Queue: Miguel Casas <mcasas@chromium.org>
Auto-Submit: Fritz Koenig <frkoenig@chromium.org>
Reviewed-by: default avatarMiguel Casas <mcasas@chromium.org>
Cr-Commit-Position: refs/heads/master@{#844331}
parent 41abd938
...@@ -1534,8 +1534,7 @@ VideoCodecProfile V4L2Device::V4L2ProfileToVideoCodecProfile(VideoCodec codec, ...@@ -1534,8 +1534,7 @@ VideoCodecProfile V4L2Device::V4L2ProfileToVideoCodecProfile(VideoCodec codec,
} }
std::vector<VideoCodecProfile> V4L2Device::V4L2PixFmtToVideoCodecProfiles( std::vector<VideoCodecProfile> V4L2Device::V4L2PixFmtToVideoCodecProfiles(
uint32_t pix_fmt, uint32_t pix_fmt) {
bool is_encoder) {
auto get_supported_profiles = [this]( auto get_supported_profiles = [this](
VideoCodec codec, VideoCodec codec,
std::vector<VideoCodecProfile>* profiles) { std::vector<VideoCodecProfile>* profiles) {
...@@ -2086,7 +2085,7 @@ V4L2Device::EnumerateSupportedDecodeProfiles(const size_t num_formats, ...@@ -2086,7 +2085,7 @@ V4L2Device::EnumerateSupportedDecodeProfiles(const size_t num_formats,
&profile.max_resolution); &profile.max_resolution);
const auto video_codec_profiles = const auto video_codec_profiles =
V4L2PixFmtToVideoCodecProfiles(pixelformat, false); V4L2PixFmtToVideoCodecProfiles(pixelformat);
for (const auto& video_codec_profile : video_codec_profiles) { for (const auto& video_codec_profile : video_codec_profiles) {
profile.profile = video_codec_profile; profile.profile = video_codec_profile;
...@@ -2117,7 +2116,7 @@ V4L2Device::EnumerateSupportedEncodeProfiles() { ...@@ -2117,7 +2116,7 @@ V4L2Device::EnumerateSupportedEncodeProfiles() {
&profile.max_resolution); &profile.max_resolution);
const auto video_codec_profiles = const auto video_codec_profiles =
V4L2PixFmtToVideoCodecProfiles(pixelformat, true); V4L2PixFmtToVideoCodecProfiles(pixelformat);
for (const auto& video_codec_profile : video_codec_profiles) { for (const auto& video_codec_profile : video_codec_profiles) {
profile.profile = video_codec_profile; profile.profile = video_codec_profile;
......
...@@ -602,8 +602,7 @@ class MEDIA_GPU_EXPORT V4L2Device ...@@ -602,8 +602,7 @@ class MEDIA_GPU_EXPORT V4L2Device
static VideoCodecProfile V4L2ProfileToVideoCodecProfile(VideoCodec codec, static VideoCodecProfile V4L2ProfileToVideoCodecProfile(VideoCodec codec,
uint32_t profile); uint32_t profile);
std::vector<VideoCodecProfile> V4L2PixFmtToVideoCodecProfiles( std::vector<VideoCodecProfile> V4L2PixFmtToVideoCodecProfiles(
uint32_t pix_fmt, uint32_t pix_fmt);
bool is_encoder);
static uint32_t V4L2PixFmtToDrmFormat(uint32_t format); static uint32_t V4L2PixFmtToDrmFormat(uint32_t format);
// Calculates the largest plane's allocation size requested by a V4L2 device. // Calculates the largest plane's allocation size requested by a V4L2 device.
static gfx::Size AllocatedSizeFromV4L2Format( static gfx::Size AllocatedSizeFromV4L2Format(
......
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