How and why v4l2src able to take YV12 format?

jeyp4 jaiforfriend at gmail.com
Thu Nov 14 18:12:39 UTC 2019


My USB camera has 2 pixel formats, MJPG & YUYV

jai at jai:~$ v4l2-ctl -d /dev/video0 --list-formats-ext
ioctl: VIDIOC_ENUM_FMT
	Index       : 0
	Type        : Video Capture
	Pixel Format: 'MJPG' (compressed)
	Name        : Motion-JPEG
		Size: Discrete 1920x1080
			Interval: Discrete 0.017s (60.000 fps)
		Size: Discrete 1280x720
			Interval: Discrete 0.017s (60.000 fps)
		Size: Discrete 640x480
			Interval: Discrete 0.017s (60.000 fps)

	Index       : 1
	Type        : Video Capture
	Pixel Format: 'YUYV'
	Name        : YUYV 4:2:2
		Size: Discrete 1920x1080
			Interval: Discrete 0.017s (60.000 fps)
		Size: Discrete 1280x720
			Interval: Discrete 0.017s (60.000 fps)
		Size: Discrete 640x480
			Interval: Discrete 0.017s (60.000 fps)


But v4l2src is able to except YUV2, YV12 as well as I420. How?
gst-launch-1.0 -v v4l2src device=/dev/video0 ! 'video/x-raw,
format=YV12,width=1280, height=720, framerate=60/1' ! fpsdisplaysink
video-sink=fakesink text-overlay=false -v

Above pipeline works fine.

Actually it's a positive aspect for me. I am worried because if I connect
camera to jetson, v4l2src can only take mjpg and YUV2. I want jetson also to
take YV12 and I420.

Intel computer's GStreamer 1.8.3.
Jetson's GStreamer 1.14.5




--
Sent from: http://gstreamer-devel.966125.n4.nabble.com/


More information about the gstreamer-devel mailing list