[PATCH] gstreamer: Add Y444 format support to the YUV list

Nicolas Dufresne nicolas at ndufresne.ca
Tue Mar 18 18:09:44 CET 2025


Le lundi 17 mars 2025 à 17:10 +0100, Antoine Bouyer a écrit :
> 'imx8-isi' pipeline provides support for 'YUV444' PixelFormat with
> YUV
> streams, but it cannot be played with gstreamer adapter whereas
> gstreamer's video format 'Y444' value suggests that it also supports
> this format.
> 
> To add support of Planar 4:4:4 YUV format in gstreamer adapter, this
> patch
> maps 'Y444' gstreamer video format with 'YUV444' libcamera
> PixelFormat.
> 
> Then below command example can be used to capture a stream with imx8-
> isi
> pipeline:
> 
>   gst-launch-1.0 \
>       libcamerasrc camera-name=<your_camera_name> ! \
>       video/x-raw, format=Y444, width=1280, height=800 ! \
>       queue ! \
>       filesink location=/tmp/output
> 
> Signed-off-by: Antoine Bouyer <antoine.bouyer at nxp.com>
> ---
>  src/gstreamer/gstlibcamera-utils.cpp | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/src/gstreamer/gstlibcamera-utils.cpp
> b/src/gstreamer/gstlibcamera-utils.cpp
> index a466b30..41eea7d 100644
> --- a/src/gstreamer/gstlibcamera-utils.cpp
> +++ b/src/gstreamer/gstlibcamera-utils.cpp
> @@ -74,6 +74,7 @@ static struct {
>  	{ GST_VIDEO_FORMAT_I420, formats::YUV420 },
>  	{ GST_VIDEO_FORMAT_YV12, formats::YVU420 },
>  	{ GST_VIDEO_FORMAT_Y42B, formats::YUV422 },
> +	{ GST_VIDEO_FORMAT_Y444, formats::YUV444 },

Thanks.

Reviewed-by: Nicolas Dufresne <nicolas.dufresne at collabora.com>

>  
>  	/* YUV Packed */
>  	{ GST_VIDEO_FORMAT_UYVY, formats::UYVY },



More information about the libcamera-devel mailing list