Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Overhaul Transform3D documentation #87334

Merged
merged 1 commit into from
Mar 4, 2024

Conversation

Mickeon
Copy link
Contributor

@Mickeon Mickeon commented Jan 18, 2024

Related to #87181

This PR aims to completely overhaul the Transform3D type's documentation.
The reasoning and changelog are extremely similar to the "Overhaul Basis Documentation" PR, so I'm not sure I should bother repeating them twice.

More specific notes:

  • Elaborate on orthonormalized, inverse, and affline_inverse a lot more.
  • Use global scope lerp's description as a base for interpolate_with.
  • ...

@Mickeon Mickeon requested a review from a team as a code owner January 18, 2024 13:20
@Mickeon Mickeon marked this pull request as draft January 18, 2024 13:20
@AThousandShips AThousandShips added enhancement documentation cherrypick:4.1 Considered for cherry-picking into a future 4.1.x release cherrypick:4.2 Considered for cherry-picking into a future 4.2.x release labels Jan 19, 2024
@AThousandShips AThousandShips added this to the 4.x milestone Jan 19, 2024
doc/classes/Transform3D.xml Show resolved Hide resolved
doc/classes/Transform3D.xml Show resolved Hide resolved
doc/classes/Transform3D.xml Outdated Show resolved Hide resolved
Returns the inverse of the transform, under the assumption that the transformation basis is orthonormal (i.e. rotation/reflection is fine, scaling/skew is not). Use [method affine_inverse] for non-orthonormal transforms (e.g. with scaling).
Returns the inversed version of this transform.
For this method to return correctly, the transform's [member basis] needs to be orthonormal (see [method Basis.orthonormalized]). In short, the basis should only represent a rotation. If it does not, use [method affine_inverse], instead.
Copy link
Member

@AThousandShips AThousandShips Jan 19, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A bit verbose IMO, will think of a more consise suggestion, but I'd suggest something like "Requires that..."

@Mickeon Mickeon force-pushed the doc-peeves-trans-rights branch from 4ee2d08 to 438b987 Compare January 19, 2024 11:58
@Mickeon Mickeon force-pushed the doc-peeves-trans-rights branch from 438b987 to ee7d2e9 Compare February 18, 2024 14:20
@Mickeon Mickeon marked this pull request as ready for review February 18, 2024 14:20
@Mickeon Mickeon marked this pull request as draft February 18, 2024 14:21
@Mickeon Mickeon mentioned this pull request Feb 18, 2024
4 tasks
@Mickeon Mickeon force-pushed the doc-peeves-trans-rights branch from ee7d2e9 to 592781d Compare February 19, 2024 14:34
@Mickeon Mickeon marked this pull request as ready for review February 19, 2024 14:35
Copy link
Contributor Author

@Mickeon Mickeon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe the PR is in a good state to be taken a look at, with a few caveats.

If you know more people that would be capable of reviewing and providing additional info feel free to ask them for review, as well. Like Basis's docs, I feel like this is very important.

Comment on lines 166 to 170
<description>
Returns a copy of the transform translated by the given [param offset].
Returns a copy of this transform translated by the given [param offset].
This method is an optimized version of multiplying the given transform [code]X[/code] with a corresponding translation transform [code]T[/code] from the right, i.e., [code]X * T[/code].
This can be seen as transforming with respect to the local frame.
</description>
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ALL of these descriptions, yes, all of them need a massive change:
translated, rotated, scaled and their equivalent *_local methods.

But I have no idea what of this description is meaningful, what NEEDS to be said, and how to phrase it. I need way further feedback.

@Mickeon Mickeon force-pushed the doc-peeves-trans-rights branch from 592781d to 64ba22a Compare March 2, 2024 16:53
doc/classes/Transform3D.xml Show resolved Hide resolved
doc/classes/Transform3D.xml Show resolved Hide resolved
doc/classes/Transform3D.xml Show resolved Hide resolved
doc/classes/Transform3D.xml Show resolved Hide resolved
@akien-mga akien-mga modified the milestones: 4.x, 4.3 Mar 4, 2024
@akien-mga akien-mga merged commit a195bc4 into godotengine:master Mar 4, 2024
16 checks passed
@AThousandShips
Copy link
Member

This was merged ignoring several review comments

@akien-mga
Copy link
Member

My bad, I missed those in my latest batch.

@Mickeon
Copy link
Contributor Author

Mickeon commented Mar 4, 2024

I did not expect this to be merged as is, to be honest, but I'm happy about it...

I can make a follow-up PR to address the above comments.

@Mickeon Mickeon deleted the doc-peeves-trans-rights branch March 4, 2024 16:55
@akien-mga
Copy link
Member

Cherry-picked for 4.2.2.
Cherry-picked for 4.1.4.

@akien-mga akien-mga removed cherrypick:4.1 Considered for cherry-picking into a future 4.1.x release cherrypick:4.2 Considered for cherry-picking into a future 4.2.x release labels Mar 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants