Re: Implementing input IOCTLs for imx capture

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

On Mon, May 31, 2021 at 07:22:12PM +0100, Ian Arkver wrote:
> On 31/05/2021 18:55, Fabio Estevam wrote:
> > Hi,
> > 
> > On an imx6dl based board with an ADV7280, I can successfully capture
> > from an analog camera using the following Gstreamer pipeline:
> > 
> > gst-launch-1.0 v4l2src device=/dev/video2 ! kmssink
> > 
> > The next goal is to integrate it within the Qt multimedia application:
> > https://github.com/qt/qtmultimedia/blob/5.15.2/src/gsttools/qgstutils.cpp#L631-L687
> > 
> > The Qt app uses the VIDIOC_ENUMINPUT and VIDIOC_S_INPUT ioctl's, but
> > as these are not implemented by the imx-media-capture driver yet, it
> > causes the camera to not be detected.

I'd argue this should be fixed in Qt though :-) Those ioctls really
don't make sense for the IPU driver.

> Seems to me (naively, without looking into it in depth) that the v4l2 
> framework default should be to enumerate a single input, return that 
> input with g_input and succeed in setting that input with s_input.

This is done in

commit f645e6256bd1b12523b759fcc610861fb21c24c7
Author: Niklas Söderlund <niklas.soderlund+renesas@xxxxxxxxxxxx>
Date:   Tue Apr 21 15:57:38 2020 +0200

    media: v4l2-dev/ioctl: Add V4L2_CAP_IO_MC

but only when V4L2_CAP_IO_MC is set.

> Maybe there's a reason why it doesn't?
> 
> > Does anyone have any suggestions as to how to add support for
> > .vidioc_enum_input, .vidioc_g_input and .vidioc_s_input in
> > drivers/staging/media/imx/imx-media-capture.c ?
> > 
> > I tried to look at how the other drivers implement these hooks, but my
> > attempts to add support for them to the imx capture driver didn't
> > work.

-- 
Regards,

Laurent Pinchart



[Index of Archives]     [Linux Input]     [Video for Linux]     [Gstreamer Embedded]     [Mplayer Users]     [Linux USB Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]

  Powered by Linux