Documented Transform and Transform2D.
This commit is contained in:
parent
d1cb73b47a
commit
decd5052d8
|
@ -53403,10 +53403,10 @@
|
||||||
</class>
|
</class>
|
||||||
<class name="Transform" category="Built-In Types">
|
<class name="Transform" category="Built-In Types">
|
||||||
<brief_description>
|
<brief_description>
|
||||||
3D Transformation.
|
3D Transformation. 3x4 matrix.
|
||||||
</brief_description>
|
</brief_description>
|
||||||
<description>
|
<description>
|
||||||
Transform is used to store translation, rotation and scaling transformations. It consists of a Basis "basis" and Vector3 "origin". Transform is used to represent transformations of objects in space, and as such, determine their position, orientation and scale. It is similar to a 3x4 matrix.
|
Represents one or many transformations in 3D space such as translation, rotation, or scaling. It consists of a [Basis] "basis" and an [Vector3] "origin". It is similar to a 3x4 matrix.
|
||||||
</description>
|
</description>
|
||||||
<methods>
|
<methods>
|
||||||
<method name="Transform">
|
<method name="Transform">
|
||||||
|
@ -53421,7 +53421,7 @@
|
||||||
<argument index="3" name="origin" type="Vector3">
|
<argument index="3" name="origin" type="Vector3">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Construct the Transform from four Vector3. Each axis corresponds to local basis vectors (some of which may be scaled).
|
Construct the Transform from four [Vector3]. Each axis corresponds to local basis vectors (some of which may be scaled).
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="Transform">
|
<method name="Transform">
|
||||||
|
@ -53432,7 +53432,7 @@
|
||||||
<argument index="1" name="origin" type="Vector3">
|
<argument index="1" name="origin" type="Vector3">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Construct the Transform from a Basis and Vector3.
|
Construct the Transform from a [Basis] and [Vector3].
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="Transform">
|
<method name="Transform">
|
||||||
|
@ -53441,7 +53441,7 @@
|
||||||
<argument index="0" name="from" type="Transform2D">
|
<argument index="0" name="from" type="Transform2D">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Construct the Transform from a Transform2D.
|
Construct the Transform from a [Transform2D].
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="Transform">
|
<method name="Transform">
|
||||||
|
@ -53450,7 +53450,7 @@
|
||||||
<argument index="0" name="from" type="Quat">
|
<argument index="0" name="from" type="Quat">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Construct the Transform from a Quat. The origin will be Vector3(0, 0, 0).
|
Construct the Transform from a [Quat]. The origin will be Vector3(0, 0, 0).
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="Transform">
|
<method name="Transform">
|
||||||
|
@ -53459,7 +53459,7 @@
|
||||||
<argument index="0" name="from" type="Basis">
|
<argument index="0" name="from" type="Basis">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Construct the Transform from a Basis. The origin will be Vector3(0, 0, 0).
|
Construct the Transform from a [Basis]. The origin will be Vector3(0, 0, 0).
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="affine_inverse">
|
<method name="affine_inverse">
|
||||||
|
@ -53477,13 +53477,14 @@
|
||||||
<argument index="1" name="weight" type="float">
|
<argument index="1" name="weight" type="float">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
|
Interpolate to other Transform by weight amount (0-1).
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="inverse">
|
<method name="inverse">
|
||||||
<return type="Transform">
|
<return type="Transform">
|
||||||
</return>
|
</return>
|
||||||
<description>
|
<description>
|
||||||
Returns the inverse of the transform, under the assumption that the transformation is composed of rotation and translation (no scaling).
|
Returns the inverse of the transform, under the assumption that the transformation is composed of rotation and translation (no scaling, use affine_inverse for transforms with scaling).
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="looking_at">
|
<method name="looking_at">
|
||||||
|
@ -53530,7 +53531,7 @@
|
||||||
<argument index="0" name="ofs" type="Vector3">
|
<argument index="0" name="ofs" type="Vector3">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
Translate the transform by the specified displacement.
|
Translate the transform by the specified offset.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="xform">
|
<method name="xform">
|
||||||
|
@ -53554,10 +53555,10 @@
|
||||||
</methods>
|
</methods>
|
||||||
<members>
|
<members>
|
||||||
<member name="basis" type="Basis" setter="" getter="" brief="">
|
<member name="basis" type="Basis" setter="" getter="" brief="">
|
||||||
The basis is a matrix containing 3 [Vector3] as its columns: X axis, Y axis, and Z axis. These vectors can be interpreted as the basis vectors of local coordinate system travelling with the object.
|
The basis is a matrix containing 3 [Vector3] as its columns: X axis, Y axis, and Z axis. These vectors can be interpreted as the basis vectors of local coordinate system traveling with the object.
|
||||||
</member>
|
</member>
|
||||||
<member name="origin" type="Vector3" setter="" getter="" brief="">
|
<member name="origin" type="Vector3" setter="" getter="" brief="">
|
||||||
The origin of the transform. Which is the translation offset.
|
The translation offset of the transform.
|
||||||
</member>
|
</member>
|
||||||
</members>
|
</members>
|
||||||
<constants>
|
<constants>
|
||||||
|
@ -53565,10 +53566,10 @@
|
||||||
</class>
|
</class>
|
||||||
<class name="Transform2D" category="Built-In Types">
|
<class name="Transform2D" category="Built-In Types">
|
||||||
<brief_description>
|
<brief_description>
|
||||||
3x2 Matrix for 2D transforms.
|
2D Transformation. 3x2 matrix.
|
||||||
</brief_description>
|
</brief_description>
|
||||||
<description>
|
<description>
|
||||||
3x2 Matrix for 2D transforms.
|
Represents one or many transformations in 3D space such as translation, rotation, or scaling. It consists of a two [Vector2] x, y and [Vector2] "origin". It is similar to a 3x2 matrix.
|
||||||
</description>
|
</description>
|
||||||
<methods>
|
<methods>
|
||||||
<method name="Transform2D">
|
<method name="Transform2D">
|
||||||
|
@ -53577,6 +53578,7 @@
|
||||||
<argument index="0" name="from" type="Transform">
|
<argument index="0" name="from" type="Transform">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
|
Constructs the [Transform2D] from a 3D [Transform].
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="Transform2D">
|
<method name="Transform2D">
|
||||||
|
@ -53589,6 +53591,7 @@
|
||||||
<argument index="2" name="origin" type="Vector2">
|
<argument index="2" name="origin" type="Vector2">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
|
Constructs the [Transform2D] from 3 [Vector2] consisting of rows x, y and origin.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="Transform2D">
|
<method name="Transform2D">
|
||||||
|
@ -53599,13 +53602,14 @@
|
||||||
<argument index="1" name="pos" type="Vector2">
|
<argument index="1" name="pos" type="Vector2">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
|
Constructs the [Transform2D] from rotation angle in radians and position [Vector2].
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="affine_inverse">
|
<method name="affine_inverse">
|
||||||
<return type="Transform2D">
|
<return type="Transform2D">
|
||||||
</return>
|
</return>
|
||||||
<description>
|
<description>
|
||||||
Return the inverse of the matrix.
|
Returns the inverse of the matrix.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="basis_xform">
|
<method name="basis_xform">
|
||||||
|
@ -53614,6 +53618,7 @@
|
||||||
<argument index="0" name="v" type="var">
|
<argument index="0" name="v" type="var">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
|
Transforms the given vector "v" by this transform basis (no translation).
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="basis_xform_inv">
|
<method name="basis_xform_inv">
|
||||||
|
@ -53622,12 +53627,14 @@
|
||||||
<argument index="0" name="v" type="var">
|
<argument index="0" name="v" type="var">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
|
Inverse-transforms vector "v" by this transform basis (no translation).
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="get_origin">
|
<method name="get_origin">
|
||||||
<return type="Vector2">
|
<return type="Vector2">
|
||||||
</return>
|
</return>
|
||||||
<description>
|
<description>
|
||||||
|
Return the origin [Vector2] (translation).
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="get_rotation">
|
<method name="get_rotation">
|
||||||
|
@ -53641,6 +53648,7 @@
|
||||||
<return type="Vector2">
|
<return type="Vector2">
|
||||||
</return>
|
</return>
|
||||||
<description>
|
<description>
|
||||||
|
Return the scale.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="interpolate_with">
|
<method name="interpolate_with">
|
||||||
|
@ -53651,18 +53659,21 @@
|
||||||
<argument index="1" name="weight" type="float">
|
<argument index="1" name="weight" type="float">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
|
Interpolate to other Transform2D by weight amount (0-1).
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="inverse">
|
<method name="inverse">
|
||||||
<return type="Transform2D">
|
<return type="Transform2D">
|
||||||
</return>
|
</return>
|
||||||
<description>
|
<description>
|
||||||
|
Returns the inverse of the transform, under the assumption that the transformation is composed of rotation and translation (no scaling, use affine_inverse for transforms with scaling).
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="orthonormalized">
|
<method name="orthonormalized">
|
||||||
<return type="Transform2D">
|
<return type="Transform2D">
|
||||||
</return>
|
</return>
|
||||||
<description>
|
<description>
|
||||||
|
Returns a transfrom with the basis orthogonal (90 degrees), and normalized axis vectors.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="rotated">
|
<method name="rotated">
|
||||||
|
@ -53671,6 +53682,7 @@
|
||||||
<argument index="0" name="phi" type="float">
|
<argument index="0" name="phi" type="float">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
|
Rotate the transform by phi.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="scaled">
|
<method name="scaled">
|
||||||
|
@ -53679,6 +53691,7 @@
|
||||||
<argument index="0" name="scale" type="Vector2">
|
<argument index="0" name="scale" type="Vector2">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
|
Scale the transform by the specified 2D scaling factors.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="translated">
|
<method name="translated">
|
||||||
|
@ -53687,6 +53700,7 @@
|
||||||
<argument index="0" name="offset" type="Vector2">
|
<argument index="0" name="offset" type="Vector2">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
|
Translate the transform by the specified offset.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="xform">
|
<method name="xform">
|
||||||
|
@ -53695,6 +53709,7 @@
|
||||||
<argument index="0" name="v" type="var">
|
<argument index="0" name="v" type="var">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
|
Transforms the given vector "v" by this transform.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
<method name="xform_inv">
|
<method name="xform_inv">
|
||||||
|
@ -53703,15 +53718,19 @@
|
||||||
<argument index="0" name="v" type="var">
|
<argument index="0" name="v" type="var">
|
||||||
</argument>
|
</argument>
|
||||||
<description>
|
<description>
|
||||||
|
Inverse-transforms the given vector "v" by this transform.
|
||||||
</description>
|
</description>
|
||||||
</method>
|
</method>
|
||||||
</methods>
|
</methods>
|
||||||
<members>
|
<members>
|
||||||
<member name="origin" type="Vector2" setter="" getter="" brief="">
|
<member name="origin" type="Vector2" setter="" getter="" brief="">
|
||||||
|
The translation offset of the transform.
|
||||||
</member>
|
</member>
|
||||||
<member name="x" type="Vector2" setter="" getter="" brief="">
|
<member name="x" type="Vector2" setter="" getter="" brief="">
|
||||||
|
The X axis of 2x2 basis matrix containing 2 [Vector2] as its columns: X axis and Y axis. These vectors can be interpreted as the basis vectors of local coordinate system traveling with the object.
|
||||||
</member>
|
</member>
|
||||||
<member name="y" type="Vector2" setter="" getter="" brief="">
|
<member name="y" type="Vector2" setter="" getter="" brief="">
|
||||||
|
The Y axis of 2x2 basis matrix containing 2 [Vector2] as its columns: X axis and Y axis. These vectors can be interpreted as the basis vectors of local coordinate system traveling with the object.
|
||||||
</member>
|
</member>
|
||||||
</members>
|
</members>
|
||||||
<constants>
|
<constants>
|
||||||
|
|
Loading…
Reference in New Issue