Message ID | 20190823123737.7774-3-ribalda@kernel.org (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | [v3,1/7] media: add V4L2_CID_UNIT_CELL_SIZE control | expand |
On Fri, 2019-08-23 at 14:37 +0200, Ricardo Ribalda Delgado wrote: > A struct v4l2_area containing the width and the height of a rectangular > area. > > Signed-off-by: Ricardo Ribalda Delgado <ribalda@kernel.org> > Suggested-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> > --- > Documentation/media/uapi/v4l/vidioc-queryctrl.rst | 6 ++++++ > 1 file changed, 6 insertions(+) > > diff --git a/Documentation/media/uapi/v4l/vidioc-queryctrl.rst b/Documentation/media/uapi/v4l/vidioc-queryctrl.rst > index a3d56ffbf4cc..c09d06ef2b08 100644 > --- a/Documentation/media/uapi/v4l/vidioc-queryctrl.rst > +++ b/Documentation/media/uapi/v4l/vidioc-queryctrl.rst > @@ -443,6 +443,12 @@ See also the examples in :ref:`control`. > - n/a > - A struct :c:type:`v4l2_ctrl_mpeg2_quantization`, containing MPEG-2 > quantization matrices for stateless video decoders. > + * - ``V4L2_CTRL_TYPE_AREA`` > + - n/a > + - n/a > + - n/a > + - A struct :c:type:`v4l2_area`, containing the width and the height > + of a rectangular area. Maybe explicitly mention that units depend on the use case? regards Philipp
Hi Ricardo, On Fri, Aug 23, 2019 at 02:37:33PM +0200, Ricardo Ribalda Delgado wrote: > A struct v4l2_area containing the width and the height of a rectangular > area. > > Signed-off-by: Ricardo Ribalda Delgado <ribalda@kernel.org> > Suggested-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> > --- > Documentation/media/uapi/v4l/vidioc-queryctrl.rst | 6 ++++++ > 1 file changed, 6 insertions(+) > > diff --git a/Documentation/media/uapi/v4l/vidioc-queryctrl.rst b/Documentation/media/uapi/v4l/vidioc-queryctrl.rst > index a3d56ffbf4cc..c09d06ef2b08 100644 > --- a/Documentation/media/uapi/v4l/vidioc-queryctrl.rst > +++ b/Documentation/media/uapi/v4l/vidioc-queryctrl.rst > @@ -443,6 +443,12 @@ See also the examples in :ref:`control`. > - n/a > - A struct :c:type:`v4l2_ctrl_mpeg2_quantization`, containing MPEG-2 > quantization matrices for stateless video decoders. > + * - ``V4L2_CTRL_TYPE_AREA`` > + - n/a Can an area be negative ? I would set these fields to ">= 0" ">= 1" and ">= 0" respectively. Thanks j > + - n/a > + - n/a > + - A struct :c:type:`v4l2_area`, containing the width and the height > + of a rectangular area. > * - ``V4L2_CTRL_TYPE_H264_SPS`` > - n/a > - n/a > -- > 2.23.0.rc1 >
HI Jacopo (Sorry for the late reply, I have been in holidays plus with plenty of family matters) On Mon, Aug 26, 2019 at 9:39 AM Jacopo Mondi <jacopo@jmondi.org> wrote: > > Hi Ricardo, > > On Fri, Aug 23, 2019 at 02:37:33PM +0200, Ricardo Ribalda Delgado wrote: > > A struct v4l2_area containing the width and the height of a rectangular > > area. > > > > Signed-off-by: Ricardo Ribalda Delgado <ribalda@kernel.org> > > Suggested-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> > > --- > > Documentation/media/uapi/v4l/vidioc-queryctrl.rst | 6 ++++++ > > 1 file changed, 6 insertions(+) > > > > diff --git a/Documentation/media/uapi/v4l/vidioc-queryctrl.rst b/Documentation/media/uapi/v4l/vidioc-queryctrl.rst > > index a3d56ffbf4cc..c09d06ef2b08 100644 > > --- a/Documentation/media/uapi/v4l/vidioc-queryctrl.rst > > +++ b/Documentation/media/uapi/v4l/vidioc-queryctrl.rst > > @@ -443,6 +443,12 @@ See also the examples in :ref:`control`. > > - n/a > > - A struct :c:type:`v4l2_ctrl_mpeg2_quantization`, containing MPEG-2 > > quantization matrices for stateless video decoders. > > + * - ``V4L2_CTRL_TYPE_AREA`` > > + - n/a > > Can an area be negative ? > I would set these fields to ">= 0" ">= 1" and ">= 0" respectively. > Dont min, max and step only make sense for integer controls? > Thanks > j > > > + - n/a > > + - n/a > > + - A struct :c:type:`v4l2_area`, containing the width and the height > > + of a rectangular area. > > * - ``V4L2_CTRL_TYPE_H264_SPS`` > > - n/a > > - n/a > > -- > > 2.23.0.rc1 > >
On 9/12/19 12:51 PM, Ricardo Ribalda Delgado wrote: > HI Jacopo > > (Sorry for the late reply, I have been in holidays plus with plenty of > family matters) > > On Mon, Aug 26, 2019 at 9:39 AM Jacopo Mondi <jacopo@jmondi.org> wrote: >> >> Hi Ricardo, >> >> On Fri, Aug 23, 2019 at 02:37:33PM +0200, Ricardo Ribalda Delgado wrote: >>> A struct v4l2_area containing the width and the height of a rectangular >>> area. >>> >>> Signed-off-by: Ricardo Ribalda Delgado <ribalda@kernel.org> >>> Suggested-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> >>> --- >>> Documentation/media/uapi/v4l/vidioc-queryctrl.rst | 6 ++++++ >>> 1 file changed, 6 insertions(+) >>> >>> diff --git a/Documentation/media/uapi/v4l/vidioc-queryctrl.rst b/Documentation/media/uapi/v4l/vidioc-queryctrl.rst >>> index a3d56ffbf4cc..c09d06ef2b08 100644 >>> --- a/Documentation/media/uapi/v4l/vidioc-queryctrl.rst >>> +++ b/Documentation/media/uapi/v4l/vidioc-queryctrl.rst >>> @@ -443,6 +443,12 @@ See also the examples in :ref:`control`. >>> - n/a >>> - A struct :c:type:`v4l2_ctrl_mpeg2_quantization`, containing MPEG-2 >>> quantization matrices for stateless video decoders. >>> + * - ``V4L2_CTRL_TYPE_AREA`` >>> + - n/a >> >> Can an area be negative ? >> I would set these fields to ">= 0" ">= 1" and ">= 0" respectively. >> > > Dont min, max and step only make sense for integer controls? It's up to us to define this :-) I think it would make sense here as well where the range applies to both width and height values. Obviously, the range will be a superset of the range of each field separately, but it does help validation and prevent negative values. Regards, Hans > >> Thanks >> j >> >>> + - n/a >>> + - n/a >>> + - A struct :c:type:`v4l2_area`, containing the width and the height >>> + of a rectangular area. >>> * - ``V4L2_CTRL_TYPE_H264_SPS`` >>> - n/a >>> - n/a >>> -- >>> 2.23.0.rc1 >>>
diff --git a/Documentation/media/uapi/v4l/vidioc-queryctrl.rst b/Documentation/media/uapi/v4l/vidioc-queryctrl.rst index a3d56ffbf4cc..c09d06ef2b08 100644 --- a/Documentation/media/uapi/v4l/vidioc-queryctrl.rst +++ b/Documentation/media/uapi/v4l/vidioc-queryctrl.rst @@ -443,6 +443,12 @@ See also the examples in :ref:`control`. - n/a - A struct :c:type:`v4l2_ctrl_mpeg2_quantization`, containing MPEG-2 quantization matrices for stateless video decoders. + * - ``V4L2_CTRL_TYPE_AREA`` + - n/a + - n/a + - n/a + - A struct :c:type:`v4l2_area`, containing the width and the height + of a rectangular area. * - ``V4L2_CTRL_TYPE_H264_SPS`` - n/a - n/a
A struct v4l2_area containing the width and the height of a rectangular area. Signed-off-by: Ricardo Ribalda Delgado <ribalda@kernel.org> Suggested-by: Hans Verkuil <hverkuil-cisco@xs4all.nl> --- Documentation/media/uapi/v4l/vidioc-queryctrl.rst | 6 ++++++ 1 file changed, 6 insertions(+)