[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <20190902094123.wixtn5dm2dwd62bu@uno.localdomain>
Date: Mon, 2 Sep 2019 11:41:23 +0200
From: Jacopo Mondi <jacopo@...ndi.org>
To: Pavel Machek <pavel@....cz>
Cc: Hans Verkuil <hverkuil-cisco@...all.nl>,
Laurent Pinchart <laurent.pinchart@...asonboard.com>,
Mauro Carvalho Chehab <mchehab@...nel.org>,
Sakari Ailus <sakari.ailus@...ux.intel.com>,
"open list:MEDIA INPUT INFRASTRUCTURE (V4L/DVB)"
<linux-media@...r.kernel.org>,
open list <linux-kernel@...r.kernel.org>
Subject: Re: [RFC 2/5] media: v4l2-ctrl: Document V4L2_CID_LOCATION
Hi Pavel,
On Sun, Sep 01, 2019 at 07:24:57PM +0200, Pavel Machek wrote:
> Hi!
>
> > >>>>> @@ -510,6 +510,29 @@ enum v4l2_scene_mode -
> > >>>>> value down. A value of zero stops the motion if one is in progress
> > >>>>> and has no effect otherwise.
> > >>>>>
> > >>>>> +``V4L2_CID_LOCATION (integer)``
> > >>>>
> > >>>> Maybe V4L2_CID_CAMERA_SENSOR_LOCATION ? Same for the values below.
> > >>>
> > >>> Probably a better name, if a bit long. But we might need other location
> > >>> controls in the future (e.g. flash location), so CID_LOCATION is just too
> > >>> generic.
> > >>
> > >
> > > Thanks for the feedback.
> > >
> > >> Note that the location defines themselves can most likely be used with any
> > >> LOCATION control, so V4L2_LOCATION_FRONT would be fine with any control.
> > >>
> > >
> > > What do you think instead of the control type? Would a single integer
> > > control do or an integer menu one would be better? I see merit in both
> > > proposals actually...
> >
> > Single integer. It's read-only, so it just reports the location.
> >
> > It would be different if this was a writable control: then you need to
> > know which locations are possible to set, and that requires a menu type.
> >
> > But it doesn't make sense to set the location from software. However, the
> > location might change as a result of other changes: e.g. if the camera
> > has motor control of the tilt and the tilt changes from forward facing to
> > downward facing, then the driver might change the location from FRONT
> > to DOWN. A convoluted example perhaps, but this is just brainstorming.
>
> There are phones with exactly such camera setup. And yes, it makes sense to be writable
> in that case, as software can move the camera in such case.
Nice, I had no idea!
Support for those kind of devices seems a bit far-fetched at the
moment, and as Laurent suggested, I would make the control writable
once we have a use case for that. But let's keep in mind that could
happen sooner or later!
Thanks
j
>
> Pavel
Download attachment "signature.asc" of type "application/pgp-signature" (834 bytes)
Powered by blists - more mailing lists