[PATCH weston 1/2] clients/dmabuf-v4l: explain vivid setup

Pekka Paalanen ppaalanen at gmail.com
Mon Jul 4 13:25:15 UTC 2016


From: Pekka Paalanen <pekka.paalanen at collabora.co.uk>

Add very short explanation on how to set up Vivid driver, when you don't
have suitable V4L2 device to use.

Using the XR24 (DRM_FORMAT_XRGB8888) format practically guarantees that
you can test direct scanout on a hardware overlay, too. At least on PC
hardware that has overlays. Tested to work on Intel.

Signed-off-by: Pekka Paalanen <pekka.paalanen at collabora.co.uk>
---
 clients/simple-dmabuf-v4l.c | 17 +++++++++++++++++
 1 file changed, 17 insertions(+)

diff --git a/clients/simple-dmabuf-v4l.c b/clients/simple-dmabuf-v4l.c
index 7ee5cce..060b4fa 100644
--- a/clients/simple-dmabuf-v4l.c
+++ b/clients/simple-dmabuf-v4l.c
@@ -866,6 +866,23 @@ usage(const char *argv0)
 	       "The default for both formats is YUYV.\n"
 	       "If the V4L2 and DRM formats differ, the data is simply "
 	       "reinterpreted rather than converted.\n", argv0);
+
+	printf("\n"
+	       "How to set up Vivid the virtual video driver for testing:\n"
+	       "- build your kernel with CONFIG_VIDEO_VIVID=m\n"
+	       "- add this to a /etc/modprobe.d/ file:\n"
+	       "    options vivid node_types=0x1 num_inputs=1 input_types=0x00\n"
+	       "- modprobe vivid and check which device was created,\n"
+	       "  here we assume /dev/video0\n"
+	       "- set the pixel format:\n"
+	       "    $ v4l2-ctl -d /dev/video0 --set-fmt-video=width=640,pixelformat=XR24\n"
+	       "- launch the demo:\n"
+	       "    $ %s /dev/video0 XR24 XR24\n"
+	       "You should see a test pattern with color bars, and some text.\n"
+	       "\n"
+	       "More about vivid: https://www.kernel.org/doc/Documentation/video4linux/vivid.txt\n"
+	       "\n", argv0);
+
 	exit(0);
 }
 
-- 
2.7.3



More information about the wayland-devel mailing list