summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <remi@verschelde.fr>2021-10-13 12:40:33 +0200
committerGitHub <noreply@github.com>2021-10-13 12:40:33 +0200
commit3e86ca5586985acbbd33878f99c8ce91ac20891d (patch)
treea240072cbf90b96469d1ed9d8715b8eccdd94ac7 /doc
parent4d2c82ef77fafc1a146e1cb46eb99efb68de2453 (diff)
parentec19ed37230c368b3d24050c9f1e99869dd94bec (diff)
Merge pull request #53689 from reduz/remove-animation-transform3d-track
Diffstat (limited to 'doc')
-rw-r--r--doc/classes/Animation.xml58
-rw-r--r--doc/classes/AnimationTree.xml4
-rw-r--r--doc/classes/Skeleton3D.xml38
3 files changed, 69 insertions, 31 deletions
diff --git a/doc/classes/Animation.xml b/doc/classes/Animation.xml
index d2ecbdde26..a35b784106 100644
--- a/doc/classes/Animation.xml
+++ b/doc/classes/Animation.xml
@@ -253,6 +253,14 @@
Returns the arguments values to be called on a method track for a given key in a given track.
</description>
</method>
+ <method name="position_track_insert_key">
+ <return type="int" />
+ <argument index="0" name="track_idx" type="int" />
+ <argument index="1" name="time" type="float" />
+ <argument index="2" name="position" type="Vector3" />
+ <description>
+ </description>
+ </method>
<method name="remove_track">
<return type="void" />
<argument index="0" name="track_idx" type="int" />
@@ -260,6 +268,22 @@
Removes a track by specifying the track index.
</description>
</method>
+ <method name="rotation_track_insert_key">
+ <return type="int" />
+ <argument index="0" name="track_idx" type="int" />
+ <argument index="1" name="time" type="float" />
+ <argument index="2" name="rotation" type="Quaternion" />
+ <description>
+ </description>
+ </method>
+ <method name="scale_track_insert_key">
+ <return type="int" />
+ <argument index="0" name="track_idx" type="int" />
+ <argument index="1" name="time" type="float" />
+ <argument index="2" name="scale" type="Vector3" />
+ <description>
+ </description>
+ </method>
<method name="track_find_key" qualifiers="const">
<return type="int" />
<argument index="0" name="track_idx" type="int" />
@@ -466,25 +490,6 @@
Swaps the track [code]idx[/code]'s index position with the track [code]with_idx[/code].
</description>
</method>
- <method name="transform_track_insert_key">
- <return type="int" />
- <argument index="0" name="track_idx" type="int" />
- <argument index="1" name="time" type="float" />
- <argument index="2" name="location" type="Vector3" />
- <argument index="3" name="rotation" type="Quaternion" />
- <argument index="4" name="scale" type="Vector3" />
- <description>
- Insert a transform key for a transform track.
- </description>
- </method>
- <method name="transform_track_interpolate" qualifiers="const">
- <return type="Array" />
- <argument index="0" name="track_idx" type="int" />
- <argument index="1" name="time_sec" type="float" />
- <description>
- Returns the interpolated value of a transform track at a given time (in seconds). An array consisting of 3 elements: position ([Vector3]), rotation ([Quaternion]) and scale ([Vector3]).
- </description>
- </method>
<method name="value_track_get_key_indices" qualifiers="const">
<return type="PackedInt32Array" />
<argument index="0" name="track_idx" type="int" />
@@ -541,19 +546,22 @@
<constant name="TYPE_VALUE" value="0" enum="TrackType">
Value tracks set values in node properties, but only those which can be Interpolated.
</constant>
- <constant name="TYPE_TRANSFORM3D" value="1" enum="TrackType">
- Transform3D tracks are used to change node local transforms or skeleton pose bones of 3D nodes. Transitions are interpolated.
+ <constant name="TYPE_POSITION_3D" value="1" enum="TrackType">
+ </constant>
+ <constant name="TYPE_ROTATION_3D" value="2" enum="TrackType">
+ </constant>
+ <constant name="TYPE_SCALE_3D" value="3" enum="TrackType">
</constant>
- <constant name="TYPE_METHOD" value="2" enum="TrackType">
+ <constant name="TYPE_METHOD" value="4" enum="TrackType">
Method tracks call functions with given arguments per key.
</constant>
- <constant name="TYPE_BEZIER" value="3" enum="TrackType">
+ <constant name="TYPE_BEZIER" value="5" enum="TrackType">
Bezier tracks are used to interpolate a value using custom curves. They can also be used to animate sub-properties of vectors and colors (e.g. alpha value of a [Color]).
</constant>
- <constant name="TYPE_AUDIO" value="4" enum="TrackType">
+ <constant name="TYPE_AUDIO" value="6" enum="TrackType">
Audio tracks are used to play an audio stream with either type of [AudioStreamPlayer]. The stream can be trimmed and previewed in the animation.
</constant>
- <constant name="TYPE_ANIMATION" value="5" enum="TrackType">
+ <constant name="TYPE_ANIMATION" value="7" enum="TrackType">
Animation tracks play animations in other [AnimationPlayer] nodes.
</constant>
<constant name="INTERPOLATION_NEAREST" value="0" enum="InterpolationType">
diff --git a/doc/classes/AnimationTree.xml b/doc/classes/AnimationTree.xml
index 3d112e258e..40dcd950d7 100644
--- a/doc/classes/AnimationTree.xml
+++ b/doc/classes/AnimationTree.xml
@@ -22,7 +22,7 @@
<method name="get_root_motion_transform" qualifiers="const">
<return type="Transform3D" />
<description>
- Retrieve the motion of the [member root_motion_track] as a [Transform3D] that can be used elsewhere. If [member root_motion_track] is not a path to a track of type [constant Animation.TYPE_TRANSFORM3D], returns an identity transformation. See also [member root_motion_track] and [RootMotionView].
+ Retrieve the motion of the [member root_motion_track] as a [Transform3D] that can be used elsewhere. If [member root_motion_track] is not a path to a track of type [constant Animation.TYPE_POSITION_3D], [constant Animation.TYPE_SCALE_3D] or [constant Animation.TYPE_ROTATION_3D], returns an identity transformation. See also [member root_motion_track] and [RootMotionView].
</description>
</method>
<method name="rename_parameter">
@@ -45,7 +45,7 @@
</member>
<member name="root_motion_track" type="NodePath" setter="set_root_motion_track" getter="get_root_motion_track" default="NodePath(&quot;&quot;)">
The path to the Animation track used for root motion. Paths must be valid scene-tree paths to a node, and must be specified starting from the parent node of the node that will reproduce the animation. To specify a track that controls properties or bones, append its name after the path, separated by [code]":"[/code]. For example, [code]"character/skeleton:ankle"[/code] or [code]"character/mesh:transform/local"[/code].
- If the track has type [constant Animation.TYPE_TRANSFORM3D], the transformation will be cancelled visually, and the animation will appear to stay in place. See also [method get_root_motion_transform] and [RootMotionView].
+ If the track has type [constant Animation.TYPE_POSITION_3D], [constant Animation.TYPE_ROTATION_3D] or [constant Animation.TYPE_SCALE_3D] the transformation will be cancelled visually, and the animation will appear to stay in place. See also [method get_root_motion_transform] and [RootMotionView].
</member>
<member name="tree_root" type="AnimationNode" setter="set_tree_root" getter="get_tree_root">
The root animation node of this [AnimationTree]. See [AnimationNode].
diff --git a/doc/classes/Skeleton3D.xml b/doc/classes/Skeleton3D.xml
index 6ab5ed55a3..e046527b17 100644
--- a/doc/classes/Skeleton3D.xml
+++ b/doc/classes/Skeleton3D.xml
@@ -144,6 +144,24 @@
Returns the pose transform of the specified bone. Pose is applied on top of the custom pose, which is applied on top the rest pose.
</description>
</method>
+ <method name="get_bone_pose_position" qualifiers="const">
+ <return type="Vector3" />
+ <argument index="0" name="bone_idx" type="int" />
+ <description>
+ </description>
+ </method>
+ <method name="get_bone_pose_rotation" qualifiers="const">
+ <return type="Quaternion" />
+ <argument index="0" name="bone_idx" type="int" />
+ <description>
+ </description>
+ </method>
+ <method name="get_bone_pose_scale" qualifiers="const">
+ <return type="Vector3" />
+ <argument index="0" name="bone_idx" type="int" />
+ <description>
+ </description>
+ </method>
<method name="get_bone_rest" qualifiers="const">
<return type="Transform3D" />
<argument index="0" name="bone_idx" type="int" />
@@ -337,13 +355,25 @@
[b]Note:[/b] [code]parent_idx[/code] must be less than [code]bone_idx[/code].
</description>
</method>
- <method name="set_bone_pose">
+ <method name="set_bone_pose_position">
<return type="void" />
<argument index="0" name="bone_idx" type="int" />
- <argument index="1" name="pose" type="Transform3D" />
+ <argument index="1" name="position" type="Vector3" />
+ <description>
+ </description>
+ </method>
+ <method name="set_bone_pose_rotation">
+ <return type="void" />
+ <argument index="0" name="bone_idx" type="int" />
+ <argument index="1" name="rotation" type="Quaternion" />
+ <description>
+ </description>
+ </method>
+ <method name="set_bone_pose_scale">
+ <return type="void" />
+ <argument index="0" name="bone_idx" type="int" />
+ <argument index="1" name="scale" type="Vector3" />
<description>
- Sets the pose transform for bone [code]bone_idx[/code].
- [b]Note:[/b] The pose transform needs to be in bone space. Use [method world_transform_to_global_pose] to convert a world transform, like one you can get from a [Node3D], to bone space.
</description>
</method>
<method name="set_bone_rest">