All of lore.kernel.org
 help / color / mirror / Atom feed
From: Louis Chauvet <louis.chauvet@bootlin.com>
To: Bagas Sanjaya <bagasdotme@gmail.com>
Cc: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
	Maxime Ripard <mripard@kernel.org>,
	Thomas Zimmermann <tzimmermann@suse.de>,
	David Airlie <airlied@gmail.com>, Daniel Vetter <daniel@ffwll.ch>,
	dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org,
	seanpaul@google.com, marcheu@google.com,
	nicolejadeyee@google.com, pekka.paalanen@collabora.com,
	thomas.petazzoni@bootlin.com
Subject: Re: [PATCH 2/3] drm: drm_blend.c: Improve drm_plane_create_rotation_property kernel doc
Date: Wed, 17 Apr 2024 00:30:58 +0200	[thread overview]
Message-ID: <Zh78InZWwvkEqul6@localhost.localdomain> (raw)
In-Reply-To: <Zh05hqtB9owzjjez@archie.me>

Le 15/04/24 - 21:28, Bagas Sanjaya a écrit :
> On Tue, Apr 09, 2024 at 12:04:06PM +0200, Louis Chauvet wrote:
> > @@ -266,8 +257,41 @@ EXPORT_SYMBOL(drm_plane_create_alpha_property);
> >   *
> >   * Rotation is the specified amount in degrees in counter clockwise direction,
> >   * the X and Y axis are within the source rectangle, i.e.  the X/Y axis before
> > - * rotation. After reflection, the rotation is applied to the image sampled from
> > - * the source rectangle, before scaling it to fit the destination rectangle.
> > + * rotation.
> > + *
> > + * Here are some examples of rotation and reflections:
> > + *
> > + * |o  +|  REFLECT_X  |+  o|
> > + * |    |  ========>  |    |
> > + * |    |             |    |
> > + *
> > + * |o   |  REFLECT_Y  |+   |
> > + * |    |  ========>  |    |
> > + * |+   |             |o   |
> > + *
> > + * |o  +|  ROTATE_90  |+   |
> > + * |    |  ========>  |    |
> > + * |    |             |o   |
> > + *
> > + * |o   |  ROTATE_180 |   +|
> > + * |    |  ========>  |    |
> > + * |+   |             |   o|
> > + *
> > + * |o   |  ROTATE_270 |+  o|
> > + * |    |  ========>  |    |
> > + * |+   |             |    |
> > + *
> > + * Rotation and reflection can be combined to handle more situations. In this condition, the
> > + * reflection is applied first and the rotation in second.
> > + *
> > + * For example the expected result for DRM_MODE_ROTATE_90 | DRM_MODE_REFLECT_X is:
> > + *
> > + * |o  +|  REFLECT_X  |+  o|  ROTATE_90  |o   |
> > + * |    |  ========>  |    |  ========>  |    |
> > + * |    |             |    |             |+   |
> > + *
> > + * It is not possible to pass multiple rotation at the same time. (i.e ROTATE_90 | ROTATE_180 is
> > + * not the same as ROTATE_270 and is not accepted).
> 
> Sphinx reports htmldocs warnings on these transformation diagrams:
> 
> Documentation/gpu/drm-kms:389: ./drivers/gpu/drm/drm_blend.c:265: ERROR: Undefined substitution referenced: "o +".
> Documentation/gpu/drm-kms:389: ./drivers/gpu/drm/drm_blend.c:265: ERROR: Undefined substitution referenced: "+ o".
> Documentation/gpu/drm-kms:389: ./drivers/gpu/drm/drm_blend.c:273: ERROR: Undefined substitution referenced: "o +".
> Documentation/gpu/drm-kms:389: ./drivers/gpu/drm/drm_blend.c:277: ERROR: Undefined substitution referenced: "o | ROTATE_180 | +".
> Documentation/gpu/drm-kms:389: ./drivers/gpu/drm/drm_blend.c:277: ERROR: Undefined substitution referenced: "+ | | o".
> Documentation/gpu/drm-kms:389: ./drivers/gpu/drm/drm_blend.c:281: ERROR: Undefined substitution referenced: "o | ROTATE_270 |+ o".
> Documentation/gpu/drm-kms:389: ./drivers/gpu/drm/drm_blend.c:290: ERROR: Undefined substitution referenced: "o +".
> Documentation/gpu/drm-kms:389: ./drivers/gpu/drm/drm_blend.c:290: ERROR: Undefined substitution referenced: "+ o".
> 
> I have to wrap them in literal blocks:
> 
> ---- >8 ----
> diff --git a/drivers/gpu/drm/drm_blend.c b/drivers/gpu/drm/drm_blend.c
> index 6fbb8730d8b022..f2cbf8d8efbbbc 100644
> --- a/drivers/gpu/drm/drm_blend.c
> +++ b/drivers/gpu/drm/drm_blend.c
> @@ -259,36 +259,36 @@ EXPORT_SYMBOL(drm_plane_create_alpha_property);
>   * the X and Y axis are within the source rectangle, i.e.  the X/Y axis before
>   * rotation.
>   *
> - * Here are some examples of rotation and reflections:
> + * Here are some examples of rotation and reflections::
>   *
> - * |o  +|  REFLECT_X  |+  o|
> - * |    |  ========>  |    |
> - * |    |             |    |
> + *	|o  +|  REFLECT_X  |+  o|
> + *	|    |  ========>  |    |
> + *	|    |             |    |
>   *
> - * |o   |  REFLECT_Y  |+   |
> - * |    |  ========>  |    |
> - * |+   |             |o   |
> + *	|o   |  REFLECT_Y  |+   |
> + *	|    |  ========>  |    |
> + *	|+   |             |o   |
>   *
> - * |o  +|  ROTATE_90  |+   |
> - * |    |  ========>  |    |
> - * |    |             |o   |
> + *	|o  +|  ROTATE_90  |+   |
> + *	|    |  ========>  |    |
> + *	|    |             |o   |
>   *
> - * |o   |  ROTATE_180 |   +|
> - * |    |  ========>  |    |
> - * |+   |             |   o|
> + *	|o   |  ROTATE_180 |   +|
> + *	|    |  ========>  |    |
> + *	|+   |             |   o|
>   *
> - * |o   |  ROTATE_270 |+  o|
> - * |    |  ========>  |    |
> - * |+   |             |    |
> + *	|o   |  ROTATE_270 |+  o|
> + *	|    |  ========>  |    |
> + *	|+   |             |    |
>   *
>   * Rotation and reflection can be combined to handle more situations. In this condition, the
>   * reflection is applied first and the rotation in second.
>   *
> - * For example the expected result for DRM_MODE_ROTATE_90 | DRM_MODE_REFLECT_X is:
> + * For example the expected result for DRM_MODE_ROTATE_90 | DRM_MODE_REFLECT_X is::
>   *
> - * |o  +|  REFLECT_X  |+  o|  ROTATE_90  |o   |
> - * |    |  ========>  |    |  ========>  |    |
> - * |    |             |    |             |+   |
> + *	|o  +|  REFLECT_X  |+  o|  ROTATE_90  |o   |
> + *	|    |  ========>  |    |  ========>  |    |
> + *	|    |             |    |             |+   |
>   *
>   * It is not possible to pass multiple rotation at the same time. (i.e ROTATE_90 | ROTATE_180 is
>   * not the same as ROTATE_270 and is not accepted).
> 
> Thanks.
> 
> -- 
> An old man doll... just what I always wanted! - Clara

It will be fixed in the next version, thanks!

Louis Chauvet

-- 
Louis Chauvet, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

  reply	other threads:[~2024-04-16 22:31 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-09 10:04 [PATCH 0/3] drm: Multiple documentation update Louis Chauvet
2024-04-09 10:04 ` [PATCH 1/3] drm: drm_blend.c: Add precision in drm_rotation_simplify kernel doc Louis Chauvet
2024-04-15 14:30   ` Bagas Sanjaya
2024-04-09 10:04 ` [PATCH 2/3] drm: drm_blend.c: Improve drm_plane_create_rotation_property " Louis Chauvet
2024-04-15 11:36   ` Pekka Paalanen
2024-04-16 22:30     ` Louis Chauvet
2024-04-17 11:34       ` Pekka Paalanen
2024-04-15 14:28   ` Bagas Sanjaya
2024-04-16 22:30     ` Louis Chauvet [this message]
2024-04-09 10:04 ` [PATCH 3/3] drm/fourcc: Add documentation around drm_format_info Louis Chauvet
2024-04-15 12:00   ` Pekka Paalanen
2024-04-16 22:30     ` Louis Chauvet
2024-04-17 11:44       ` Pekka Paalanen
2024-04-15 14:16   ` Bagas Sanjaya
2024-04-09 10:18 ` [PATCH 0/3] drm: Multiple documentation update Jani Nikula
2024-04-09 12:38   ` Louis Chauvet

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Zh78InZWwvkEqul6@localhost.localdomain \
    --to=louis.chauvet@bootlin.com \
    --cc=airlied@gmail.com \
    --cc=bagasdotme@gmail.com \
    --cc=daniel@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=marcheu@google.com \
    --cc=mripard@kernel.org \
    --cc=nicolejadeyee@google.com \
    --cc=pekka.paalanen@collabora.com \
    --cc=seanpaul@google.com \
    --cc=thomas.petazzoni@bootlin.com \
    --cc=tzimmermann@suse.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.