]> asedeno.scripts.mit.edu Git - linux.git/commit
[media] media: imx: set and propagate default field, colorimetry
authorSteve Longerbeam <slongerbeam@gmail.com>
Wed, 7 Jun 2017 18:34:11 +0000 (15:34 -0300)
committerMauro Carvalho Chehab <mchehab@s-opensource.com>
Tue, 20 Jun 2017 11:03:57 +0000 (08:03 -0300)
commit21e54111d2558fa774aec998bba25c6fa5b61791
tree7082c60d7641692b1393479b587ab338b050da60
parentc24858c3070d7bff7f8d02c05595d4978e7198b6
[media] media: imx: set and propagate default field, colorimetry

This patch adds a call to imx_media_fill_default_mbus_fields() in the
*_try_fmt() functions at the sink pads, to set empty field order and
colorimetry parameters.

If the field order is set to ANY, choose the currently set field order
at the sink pad. If the colorspace is set to DEFAULT, choose the
current colorspace at the sink pad.  If any of xfer_func, ycbcr_enc
or quantization are set to DEFAULT, either choose the current sink pad
setting, or the default setting for the new colorspace, if non-DEFAULT
colorspace was given.

If a format is destined to be routed through the Image Converter,
fixed quantization and Y`CbCr encoding must be set.

Colorimetry is also propagated from sink to source pads anywhere
this has not already been done.

Signed-off-by: Steve Longerbeam <steve_longerbeam@mentor.com>
Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
drivers/staging/media/imx/imx-ic-prp.c
drivers/staging/media/imx/imx-ic-prpencvf.c
drivers/staging/media/imx/imx-media-csi.c
drivers/staging/media/imx/imx-media-utils.c
drivers/staging/media/imx/imx-media-vdic.c
drivers/staging/media/imx/imx-media.h