Skip to content
Commit 54ac3fc3 authored by Steve Longerbeam's avatar Steve Longerbeam Committed by Mauro Carvalho Chehab
Browse files

media: imx: utils: Default colorspace to SRGB



The function imx_media_init_mbus_fmt() initializes the imx subdevice
mbus colorimetry to some sane defaults when the subdevice is registered.
Currently it guesses at a colorspace based on the passed mbus pixel
format. If the format is RGB, it chooses colorspace V4L2_COLORSPACE_SRGB,
and if the format is YUV, it chooses V4L2_COLORSPACE_SMPTE170M.

While that might be a good guess, it's not necessarily true that a RGB
pixel format encoding uses a SRGB colorspace, or that a YUV encoding
uses a SMPTE170M colorspace. Instead of making this dubious guess,
just default the colorspace to SRGB.

Reported-by: default avatarHans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: default avatarSteve Longerbeam <slongerbeam@gmail.com>
Signed-off-by: default avatarHans Verkuil <hverkuil-cisco@xs4all.nl>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab+huawei@kernel.org>
parent e01bc6cb
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment