[libcamera-devel] [PATCH v2 1/2] pipeline: rkisp1: Add output support for YUV420 and YVU420
Jacopo Mondi
jacopo at jmondi.org
Tue Jul 19 12:01:56 CEST 2022
Hi Paul,
On Tue, Jul 19, 2022 at 04:40:12PM +0900, Paul Elder via libcamera-devel wrote:
> YUV420 and YVU420 are already supported as output formats by the rkisp1
> driver. Add them to the pipeline handler to support them in libcamera as
> well.
>
> Signed-off-by: Paul Elder <paul.elder at ideasonboard.com>
Reviewed-by: Jacopo Mondi <jacopo at jmondi.org>
Thanks
j
>
> ---
> Changes in v2:
> - move to after NV formats
> - add to self path too
> ---
> src/libcamera/pipeline/rkisp1/rkisp1_path.cpp | 10 ++++++++--
> 1 file changed, 8 insertions(+), 2 deletions(-)
>
> diff --git a/src/libcamera/pipeline/rkisp1/rkisp1_path.cpp b/src/libcamera/pipeline/rkisp1/rkisp1_path.cpp
> index 6f175758..c070929d 100644
> --- a/src/libcamera/pipeline/rkisp1/rkisp1_path.cpp
> +++ b/src/libcamera/pipeline/rkisp1/rkisp1_path.cpp
> @@ -130,6 +130,8 @@ int RkISP1Path::configure(const StreamConfiguration &config,
> switch (config.pixelFormat) {
> case formats::NV12:
> case formats::NV21:
> + case formats::YUV420:
> + case formats::YVU420:
> ispFormat.mbus_code = MEDIA_BUS_FMT_YUYV8_1_5X8;
> break;
> default:
> @@ -207,24 +209,28 @@ void RkISP1Path::stop()
> namespace {
> constexpr Size RKISP1_RSZ_MP_SRC_MIN{ 32, 16 };
> constexpr Size RKISP1_RSZ_MP_SRC_MAX{ 4416, 3312 };
> -constexpr std::array<PixelFormat, 6> RKISP1_RSZ_MP_FORMATS{
> +constexpr std::array<PixelFormat, 8> RKISP1_RSZ_MP_FORMATS{
> formats::YUYV,
> formats::NV16,
> formats::NV61,
> formats::NV21,
> formats::NV12,
> + formats::YUV420,
> + formats::YVU420,
> formats::R8,
> /* \todo Add support for RAW formats. */
> };
>
> constexpr Size RKISP1_RSZ_SP_SRC_MIN{ 32, 16 };
> constexpr Size RKISP1_RSZ_SP_SRC_MAX{ 1920, 1920 };
> -constexpr std::array<PixelFormat, 8> RKISP1_RSZ_SP_FORMATS{
> +constexpr std::array<PixelFormat, 10> RKISP1_RSZ_SP_FORMATS{
> formats::YUYV,
> formats::NV16,
> formats::NV61,
> formats::NV21,
> formats::NV12,
> + formats::YUV420,
> + formats::YVU420,
> formats::R8,
> formats::RGB565,
> formats::XRGB8888,
> --
> 2.30.2
>
More information about the libcamera-devel
mailing list