CVSROOT:        /cvs
Module name:    xenocara
Changes by:     feine...@cvs.openbsd.org        2020/07/01 00:45:24

Modified files:
        app/video      : video.c 

Log message:
Initialize v4l2_requestbuffers for better libv4l compatibility

The VIDIOC_REQBUFS ioctl requires a v4l2_requestbuffers struct with the members
count, type, and memory. In the past only count was set as the uvideo(4) kernel
driver, via uvideo_reqbufs(), is ignoring both struct members type and memory
(pointed out by mpi@).

However, using video(1) with libv4l
(LD_PRELOAD=/usr/local/lib/v4l2convert.so video)
yields "mmap: Invalid argument" as libv4l inspects the type and memory
struct members and fails if memory != V4L2_MEMORY_MMAP.

Full initialization fixes libv4l usage which allows us to view video encodings
not directly supported by video(1), e.g., MJPEG, as libv4l can convert
encodings on the fly.

OK mglocker@

Reply via email to