Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1ec0ed08 authored by Sakari Ailus's avatar Sakari Ailus Committed by Mauro Carvalho Chehab
Browse files

[media] v4l: Remove "_ACTUAL" from subdev selection API target definition names



The string "_ACTUAL" does not say anything more about the target names. Drop
it. V4L2 selection API was changed by "V4L: Remove "_ACTIVE" from the
selection target name definitions" by Sylwester Nawrocki. This patch does
the same for the V4L2 subdev API.

Signed-off-by: default avatarSakari Ailus <sakari.ailus@iki.fi>
Acked-by: default avatarSylwester Nawrocki <s.nawrocki@samsung.com>
Signed-off-by: default avatarMauro Carvalho Chehab <mchehab@redhat.com>
parent c1334823
Loading
Loading
Loading
Loading
+14 −14
Original line number Diff line number Diff line
@@ -289,9 +289,9 @@
      &v4l2-rect; by the coordinates of the top left corner and the rectangle
      size. Both the coordinates and sizes are expressed in pixels.</para>

      <para>As for pad formats, drivers store try and active
      rectangles for the selection targets of ACTUAL type <xref
      linkend="v4l2-subdev-selection-targets">.</xref></para>
      <para>As for pad formats, drivers store try and active rectangles for
      the selection targets <xref
      linkend="v4l2-subdev-selection-targets" />.</para>

      <para>On sink pads, cropping is applied relative to the
      current pad format. The pad format represents the image size as
@@ -308,7 +308,7 @@
      <para>Scaling support is optional. When supported by a subdev,
      the crop rectangle on the subdev's sink pad is scaled to the
      size configured using the &VIDIOC-SUBDEV-S-SELECTION; IOCTL
      using <constant>V4L2_SUBDEV_SEL_COMPOSE_ACTUAL</constant>
      using <constant>V4L2_SUBDEV_SEL_TGT_COMPOSE</constant>
      selection target on the same pad. If the subdev supports scaling
      but not composing, the top and left values are not used and must
      always be set to zero.</para>
@@ -333,22 +333,22 @@
      <title>Types of selection targets</title>

      <section>
	<title>ACTUAL targets</title>
	<title>Actual targets</title>

	<para>ACTUAL targets reflect the actual hardware configuration
	at any point of time. There is a BOUNDS target
	corresponding to every ACTUAL.</para>
	<para>Actual targets (without a postfix) reflect the actual
	hardware configuration at any point of time. There is a BOUNDS
	target corresponding to every actual target.</para>
      </section>

      <section>
	<title>BOUNDS targets</title>

	<para>BOUNDS targets is the smallest rectangle that contains
	all valid ACTUAL rectangles. It may not be possible to set the
	ACTUAL rectangle as large as the BOUNDS rectangle, however.
	This may be because e.g. a sensor's pixel array is not
	rectangular but cross-shaped or round. The maximum size may
	also be smaller than the BOUNDS rectangle.</para>
	<para>BOUNDS targets is the smallest rectangle that contains all
	valid actual rectangles. It may not be possible to set the actual
	rectangle as large as the BOUNDS rectangle, however. This may be
	because e.g. a sensor's pixel array is not rectangular but
	cross-shaped or round. The maximum size may also be smaller than the
	BOUNDS rectangle.</para>
      </section>

    </section>
+6 −6
Original line number Diff line number Diff line
@@ -72,10 +72,10 @@
    <section>
      <title>Types of selection targets</title>

      <para>There are two types of selection targets: actual and bounds.
      The ACTUAL targets are the targets which configure the hardware.
      The BOUNDS target will return a rectangle that contain all
      possible ACTUAL rectangles.</para>
      <para>There are two types of selection targets: actual and bounds. The
      actual targets are the targets which configure the hardware. The BOUNDS
      target will return a rectangle that contain all possible actual
      rectangles.</para>
    </section>

    <section>
@@ -93,7 +93,7 @@
        &cs-def;
	<tbody valign="top">
	  <row>
	    <entry><constant>V4L2_SUBDEV_SEL_TGT_CROP_ACTUAL</constant></entry>
	    <entry><constant>V4L2_SUBDEV_SEL_TGT_CROP</constant></entry>
	    <entry>0x0000</entry>
	    <entry>Actual crop. Defines the cropping
	    performed by the processing step.</entry>
@@ -104,7 +104,7 @@
	    <entry>Bounds of the crop rectangle.</entry>
	  </row>
	  <row>
	    <entry><constant>V4L2_SUBDEV_SEL_TGT_COMPOSE_ACTUAL</constant></entry>
	    <entry><constant>V4L2_SUBDEV_SEL_TGT_COMPOSE</constant></entry>
	    <entry>0x0100</entry>
	    <entry>Actual compose rectangle. Used to configure scaling
	    on sink pads and composition on source pads.</entry>
+2 −2
Original line number Diff line number Diff line
@@ -2024,7 +2024,7 @@ static int ccdc_get_selection(struct v4l2_subdev *sd, struct v4l2_subdev_fh *fh,
		ccdc_try_crop(ccdc, format, &sel->r);
		break;

	case V4L2_SUBDEV_SEL_TGT_CROP_ACTUAL:
	case V4L2_SUBDEV_SEL_TGT_CROP:
		sel->r = *__ccdc_get_crop(ccdc, fh, sel->which);
		break;

@@ -2052,7 +2052,7 @@ static int ccdc_set_selection(struct v4l2_subdev *sd, struct v4l2_subdev_fh *fh,
	struct isp_ccdc_device *ccdc = v4l2_get_subdevdata(sd);
	struct v4l2_mbus_framefmt *format;

	if (sel->target != V4L2_SUBDEV_SEL_TGT_CROP_ACTUAL ||
	if (sel->target != V4L2_SUBDEV_SEL_TGT_CROP ||
	    sel->pad != CCDC_PAD_SOURCE_OF)
		return -EINVAL;

+2 −2
Original line number Diff line number Diff line
@@ -1960,7 +1960,7 @@ static int preview_get_selection(struct v4l2_subdev *sd,
		preview_try_crop(prev, format, &sel->r);
		break;

	case V4L2_SUBDEV_SEL_TGT_CROP_ACTUAL:
	case V4L2_SUBDEV_SEL_TGT_CROP:
		sel->r = *__preview_get_crop(prev, fh, sel->which);
		break;

@@ -1988,7 +1988,7 @@ static int preview_set_selection(struct v4l2_subdev *sd,
	struct isp_prev_device *prev = v4l2_get_subdevdata(sd);
	struct v4l2_mbus_framefmt *format;

	if (sel->target != V4L2_SUBDEV_SEL_TGT_CROP_ACTUAL ||
	if (sel->target != V4L2_SUBDEV_SEL_TGT_CROP ||
	    sel->pad != PREV_PAD_SINK)
		return -EINVAL;

+2 −2
Original line number Diff line number Diff line
@@ -1259,7 +1259,7 @@ static int resizer_get_selection(struct v4l2_subdev *sd,
		resizer_calc_ratios(res, &sel->r, format_source, &ratio);
		break;

	case V4L2_SUBDEV_SEL_TGT_CROP_ACTUAL:
	case V4L2_SUBDEV_SEL_TGT_CROP:
		sel->r = *__resizer_get_crop(res, fh, sel->which);
		resizer_calc_ratios(res, &sel->r, format_source, &ratio);
		break;
@@ -1293,7 +1293,7 @@ static int resizer_set_selection(struct v4l2_subdev *sd,
	struct v4l2_mbus_framefmt *format_sink, *format_source;
	struct resizer_ratio ratio;

	if (sel->target != V4L2_SUBDEV_SEL_TGT_CROP_ACTUAL ||
	if (sel->target != V4L2_SUBDEV_SEL_TGT_CROP ||
	    sel->pad != RESZ_PAD_SINK)
		return -EINVAL;

Loading