mirror of
https://github.com/godotengine/godot-docs.git
synced 2026-01-04 14:11:02 +03:00
classref: Sync with current master branch (f87858a8f)
This commit is contained in:
@@ -16,335 +16,465 @@ SkeletonProfile
|
||||
|
||||
Profile of a virtual skeleton used as a target for retargeting.
|
||||
|
||||
.. rst-class:: classref-introduction-group
|
||||
|
||||
Description
|
||||
-----------
|
||||
|
||||
This resource is used in :ref:`EditorScenePostImport<class_EditorScenePostImport>`. Some parameters are referring to bones in :ref:`Skeleton3D<class_Skeleton3D>`, :ref:`Skin<class_Skin>`, :ref:`Animation<class_Animation>`, and some other nodes are rewritten based on the parameters of ``SkeletonProfile``.
|
||||
This resource is used in :ref:`EditorScenePostImport<class_EditorScenePostImport>`. Some parameters are referring to bones in :ref:`Skeleton3D<class_Skeleton3D>`, :ref:`Skin<class_Skin>`, :ref:`Animation<class_Animation>`, and some other nodes are rewritten based on the parameters of **SkeletonProfile**.
|
||||
|
||||
.. rst-class:: classref-introduction-group
|
||||
|
||||
Tutorials
|
||||
---------
|
||||
|
||||
- :doc:`Retargeting 3D Skeletons <../tutorials/assets_pipeline/retargeting_3d_skeletons>`
|
||||
|
||||
.. rst-class:: classref-reftable-group
|
||||
|
||||
Properties
|
||||
----------
|
||||
|
||||
+-------------------------------------+------------------------------------------------------------------------+---------+
|
||||
| :ref:`int<class_int>` | :ref:`bone_size<class_SkeletonProfile_property_bone_size>` | ``0`` |
|
||||
+-------------------------------------+------------------------------------------------------------------------+---------+
|
||||
| :ref:`int<class_int>` | :ref:`group_size<class_SkeletonProfile_property_group_size>` | ``0`` |
|
||||
+-------------------------------------+------------------------------------------------------------------------+---------+
|
||||
| :ref:`StringName<class_StringName>` | :ref:`root_bone<class_SkeletonProfile_property_root_bone>` | ``&""`` |
|
||||
+-------------------------------------+------------------------------------------------------------------------+---------+
|
||||
| :ref:`StringName<class_StringName>` | :ref:`scale_base_bone<class_SkeletonProfile_property_scale_base_bone>` | ``&""`` |
|
||||
+-------------------------------------+------------------------------------------------------------------------+---------+
|
||||
.. table::
|
||||
:widths: auto
|
||||
|
||||
+-------------------------------------+------------------------------------------------------------------------+---------+
|
||||
| :ref:`int<class_int>` | :ref:`bone_size<class_SkeletonProfile_property_bone_size>` | ``0`` |
|
||||
+-------------------------------------+------------------------------------------------------------------------+---------+
|
||||
| :ref:`int<class_int>` | :ref:`group_size<class_SkeletonProfile_property_group_size>` | ``0`` |
|
||||
+-------------------------------------+------------------------------------------------------------------------+---------+
|
||||
| :ref:`StringName<class_StringName>` | :ref:`root_bone<class_SkeletonProfile_property_root_bone>` | ``&""`` |
|
||||
+-------------------------------------+------------------------------------------------------------------------+---------+
|
||||
| :ref:`StringName<class_StringName>` | :ref:`scale_base_bone<class_SkeletonProfile_property_scale_base_bone>` | ``&""`` |
|
||||
+-------------------------------------+------------------------------------------------------------------------+---------+
|
||||
|
||||
.. rst-class:: classref-reftable-group
|
||||
|
||||
Methods
|
||||
-------
|
||||
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`find_bone<class_SkeletonProfile_method_find_bone>` **(** :ref:`StringName<class_StringName>` bone_name **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`StringName<class_StringName>` | :ref:`get_bone_name<class_SkeletonProfile_method_get_bone_name>` **(** :ref:`int<class_int>` bone_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`StringName<class_StringName>` | :ref:`get_bone_parent<class_SkeletonProfile_method_get_bone_parent>` **(** :ref:`int<class_int>` bone_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`StringName<class_StringName>` | :ref:`get_bone_tail<class_SkeletonProfile_method_get_bone_tail>` **(** :ref:`int<class_int>` bone_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`StringName<class_StringName>` | :ref:`get_group<class_SkeletonProfile_method_get_group>` **(** :ref:`int<class_int>` bone_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`StringName<class_StringName>` | :ref:`get_group_name<class_SkeletonProfile_method_get_group_name>` **(** :ref:`int<class_int>` group_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`get_handle_offset<class_SkeletonProfile_method_get_handle_offset>` **(** :ref:`int<class_int>` bone_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Transform3D<class_Transform3D>` | :ref:`get_reference_pose<class_SkeletonProfile_method_get_reference_pose>` **(** :ref:`int<class_int>` bone_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`TailDirection<enum_SkeletonProfile_TailDirection>` | :ref:`get_tail_direction<class_SkeletonProfile_method_get_tail_direction>` **(** :ref:`int<class_int>` bone_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Texture2D<class_Texture2D>` | :ref:`get_texture<class_SkeletonProfile_method_get_texture>` **(** :ref:`int<class_int>` group_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_bone_name<class_SkeletonProfile_method_set_bone_name>` **(** :ref:`int<class_int>` bone_idx, :ref:`StringName<class_StringName>` bone_name **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_bone_parent<class_SkeletonProfile_method_set_bone_parent>` **(** :ref:`int<class_int>` bone_idx, :ref:`StringName<class_StringName>` bone_parent **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_bone_tail<class_SkeletonProfile_method_set_bone_tail>` **(** :ref:`int<class_int>` bone_idx, :ref:`StringName<class_StringName>` bone_tail **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_group<class_SkeletonProfile_method_set_group>` **(** :ref:`int<class_int>` bone_idx, :ref:`StringName<class_StringName>` group **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_group_name<class_SkeletonProfile_method_set_group_name>` **(** :ref:`int<class_int>` group_idx, :ref:`StringName<class_StringName>` group_name **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_handle_offset<class_SkeletonProfile_method_set_handle_offset>` **(** :ref:`int<class_int>` bone_idx, :ref:`Vector2<class_Vector2>` handle_offset **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_reference_pose<class_SkeletonProfile_method_set_reference_pose>` **(** :ref:`int<class_int>` bone_idx, :ref:`Transform3D<class_Transform3D>` bone_name **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_tail_direction<class_SkeletonProfile_method_set_tail_direction>` **(** :ref:`int<class_int>` bone_idx, :ref:`TailDirection<enum_SkeletonProfile_TailDirection>` tail_direction **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_texture<class_SkeletonProfile_method_set_texture>` **(** :ref:`int<class_int>` group_idx, :ref:`Texture2D<class_Texture2D>` texture **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
.. table::
|
||||
:widths: auto
|
||||
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`int<class_int>` | :ref:`find_bone<class_SkeletonProfile_method_find_bone>` **(** :ref:`StringName<class_StringName>` bone_name **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`StringName<class_StringName>` | :ref:`get_bone_name<class_SkeletonProfile_method_get_bone_name>` **(** :ref:`int<class_int>` bone_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`StringName<class_StringName>` | :ref:`get_bone_parent<class_SkeletonProfile_method_get_bone_parent>` **(** :ref:`int<class_int>` bone_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`StringName<class_StringName>` | :ref:`get_bone_tail<class_SkeletonProfile_method_get_bone_tail>` **(** :ref:`int<class_int>` bone_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`StringName<class_StringName>` | :ref:`get_group<class_SkeletonProfile_method_get_group>` **(** :ref:`int<class_int>` bone_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`StringName<class_StringName>` | :ref:`get_group_name<class_SkeletonProfile_method_get_group_name>` **(** :ref:`int<class_int>` group_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Vector2<class_Vector2>` | :ref:`get_handle_offset<class_SkeletonProfile_method_get_handle_offset>` **(** :ref:`int<class_int>` bone_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Transform3D<class_Transform3D>` | :ref:`get_reference_pose<class_SkeletonProfile_method_get_reference_pose>` **(** :ref:`int<class_int>` bone_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`TailDirection<enum_SkeletonProfile_TailDirection>` | :ref:`get_tail_direction<class_SkeletonProfile_method_get_tail_direction>` **(** :ref:`int<class_int>` bone_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| :ref:`Texture2D<class_Texture2D>` | :ref:`get_texture<class_SkeletonProfile_method_get_texture>` **(** :ref:`int<class_int>` group_idx **)** |const| |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_bone_name<class_SkeletonProfile_method_set_bone_name>` **(** :ref:`int<class_int>` bone_idx, :ref:`StringName<class_StringName>` bone_name **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_bone_parent<class_SkeletonProfile_method_set_bone_parent>` **(** :ref:`int<class_int>` bone_idx, :ref:`StringName<class_StringName>` bone_parent **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_bone_tail<class_SkeletonProfile_method_set_bone_tail>` **(** :ref:`int<class_int>` bone_idx, :ref:`StringName<class_StringName>` bone_tail **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_group<class_SkeletonProfile_method_set_group>` **(** :ref:`int<class_int>` bone_idx, :ref:`StringName<class_StringName>` group **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_group_name<class_SkeletonProfile_method_set_group_name>` **(** :ref:`int<class_int>` group_idx, :ref:`StringName<class_StringName>` group_name **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_handle_offset<class_SkeletonProfile_method_set_handle_offset>` **(** :ref:`int<class_int>` bone_idx, :ref:`Vector2<class_Vector2>` handle_offset **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_reference_pose<class_SkeletonProfile_method_set_reference_pose>` **(** :ref:`int<class_int>` bone_idx, :ref:`Transform3D<class_Transform3D>` bone_name **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_tail_direction<class_SkeletonProfile_method_set_tail_direction>` **(** :ref:`int<class_int>` bone_idx, :ref:`TailDirection<enum_SkeletonProfile_TailDirection>` tail_direction **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
| void | :ref:`set_texture<class_SkeletonProfile_method_set_texture>` **(** :ref:`int<class_int>` group_idx, :ref:`Texture2D<class_Texture2D>` texture **)** |
|
||||
+----------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
|
||||
|
||||
.. rst-class:: classref-section-separator
|
||||
|
||||
----
|
||||
|
||||
.. rst-class:: classref-descriptions-group
|
||||
|
||||
Signals
|
||||
-------
|
||||
|
||||
.. _class_SkeletonProfile_signal_profile_updated:
|
||||
|
||||
- **profile_updated** **(** **)**
|
||||
.. rst-class:: classref-signal
|
||||
|
||||
**profile_updated** **(** **)**
|
||||
|
||||
This signal is emitted when change the value in profile. This is used to update key name in the :ref:`BoneMap<class_BoneMap>` and to redraw the :ref:`BoneMap<class_BoneMap>` editor.
|
||||
|
||||
\ **Note:** This signal is not connected directly to editor to simplify the reference, instead it is passed on to editor through the :ref:`BoneMap<class_BoneMap>`.
|
||||
|
||||
.. rst-class:: classref-section-separator
|
||||
|
||||
----
|
||||
|
||||
.. rst-class:: classref-descriptions-group
|
||||
|
||||
Enumerations
|
||||
------------
|
||||
|
||||
.. _enum_SkeletonProfile_TailDirection:
|
||||
|
||||
.. _class_SkeletonProfile_constant_TAIL_DIRECTION_AVERAGE_CHILDREN:
|
||||
|
||||
.. _class_SkeletonProfile_constant_TAIL_DIRECTION_SPECIFIC_CHILD:
|
||||
|
||||
.. _class_SkeletonProfile_constant_TAIL_DIRECTION_END:
|
||||
.. rst-class:: classref-enumeration
|
||||
|
||||
enum **TailDirection**:
|
||||
|
||||
- **TAIL_DIRECTION_AVERAGE_CHILDREN** = **0** --- Direction to the average coordinates of bone children.
|
||||
.. _class_SkeletonProfile_constant_TAIL_DIRECTION_AVERAGE_CHILDREN:
|
||||
|
||||
- **TAIL_DIRECTION_SPECIFIC_CHILD** = **1** --- Direction to the coordinates of specified bone child.
|
||||
.. rst-class:: classref-enumeration-constant
|
||||
|
||||
- **TAIL_DIRECTION_END** = **2** --- Direction is not calculated.
|
||||
:ref:`TailDirection<enum_SkeletonProfile_TailDirection>` **TAIL_DIRECTION_AVERAGE_CHILDREN** = ``0``
|
||||
|
||||
Direction to the average coordinates of bone children.
|
||||
|
||||
.. _class_SkeletonProfile_constant_TAIL_DIRECTION_SPECIFIC_CHILD:
|
||||
|
||||
.. rst-class:: classref-enumeration-constant
|
||||
|
||||
:ref:`TailDirection<enum_SkeletonProfile_TailDirection>` **TAIL_DIRECTION_SPECIFIC_CHILD** = ``1``
|
||||
|
||||
Direction to the coordinates of specified bone child.
|
||||
|
||||
.. _class_SkeletonProfile_constant_TAIL_DIRECTION_END:
|
||||
|
||||
.. rst-class:: classref-enumeration-constant
|
||||
|
||||
:ref:`TailDirection<enum_SkeletonProfile_TailDirection>` **TAIL_DIRECTION_END** = ``2``
|
||||
|
||||
Direction is not calculated.
|
||||
|
||||
.. rst-class:: classref-section-separator
|
||||
|
||||
----
|
||||
|
||||
.. rst-class:: classref-descriptions-group
|
||||
|
||||
Property Descriptions
|
||||
---------------------
|
||||
|
||||
.. _class_SkeletonProfile_property_bone_size:
|
||||
|
||||
- :ref:`int<class_int>` **bone_size**
|
||||
.. rst-class:: classref-property
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_bone_size(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_bone_size() |
|
||||
+-----------+----------------------+
|
||||
:ref:`int<class_int>` **bone_size** = ``0``
|
||||
|
||||
.. rst-class:: classref-property-setget
|
||||
|
||||
- void **set_bone_size** **(** :ref:`int<class_int>` value **)**
|
||||
- :ref:`int<class_int>` **get_bone_size** **(** **)**
|
||||
|
||||
.. container:: contribute
|
||||
|
||||
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_property_group_size:
|
||||
|
||||
- :ref:`int<class_int>` **group_size**
|
||||
.. rst-class:: classref-property
|
||||
|
||||
+-----------+-----------------------+
|
||||
| *Default* | ``0`` |
|
||||
+-----------+-----------------------+
|
||||
| *Setter* | set_group_size(value) |
|
||||
+-----------+-----------------------+
|
||||
| *Getter* | get_group_size() |
|
||||
+-----------+-----------------------+
|
||||
:ref:`int<class_int>` **group_size** = ``0``
|
||||
|
||||
.. rst-class:: classref-property-setget
|
||||
|
||||
- void **set_group_size** **(** :ref:`int<class_int>` value **)**
|
||||
- :ref:`int<class_int>` **get_group_size** **(** **)**
|
||||
|
||||
.. container:: contribute
|
||||
|
||||
There is currently no description for this property. Please help us by :ref:`contributing one <doc_updating_the_class_reference>`!
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_property_root_bone:
|
||||
|
||||
- :ref:`StringName<class_StringName>` **root_bone**
|
||||
.. rst-class:: classref-property
|
||||
|
||||
+-----------+----------------------+
|
||||
| *Default* | ``&""`` |
|
||||
+-----------+----------------------+
|
||||
| *Setter* | set_root_bone(value) |
|
||||
+-----------+----------------------+
|
||||
| *Getter* | get_root_bone() |
|
||||
+-----------+----------------------+
|
||||
:ref:`StringName<class_StringName>` **root_bone** = ``&""``
|
||||
|
||||
.. rst-class:: classref-property-setget
|
||||
|
||||
- void **set_root_bone** **(** :ref:`StringName<class_StringName>` value **)**
|
||||
- :ref:`StringName<class_StringName>` **get_root_bone** **(** **)**
|
||||
|
||||
A name of bone that will be used as the root bone in :ref:`AnimationTree<class_AnimationTree>`.
|
||||
|
||||
\ **Note:** In most cases, it is the bone of the parent of the hips that exists at the world origin in the humanoid model.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_property_scale_base_bone:
|
||||
|
||||
- :ref:`StringName<class_StringName>` **scale_base_bone**
|
||||
.. rst-class:: classref-property
|
||||
|
||||
+-----------+----------------------------+
|
||||
| *Default* | ``&""`` |
|
||||
+-----------+----------------------------+
|
||||
| *Setter* | set_scale_base_bone(value) |
|
||||
+-----------+----------------------------+
|
||||
| *Getter* | get_scale_base_bone() |
|
||||
+-----------+----------------------------+
|
||||
:ref:`StringName<class_StringName>` **scale_base_bone** = ``&""``
|
||||
|
||||
.. rst-class:: classref-property-setget
|
||||
|
||||
- void **set_scale_base_bone** **(** :ref:`StringName<class_StringName>` value **)**
|
||||
- :ref:`StringName<class_StringName>` **get_scale_base_bone** **(** **)**
|
||||
|
||||
A name of bone which height will be used as the coefficient for normalization.
|
||||
|
||||
\ **Note:** In most cases, it is hips in the humanoid model.
|
||||
|
||||
.. rst-class:: classref-section-separator
|
||||
|
||||
----
|
||||
|
||||
.. rst-class:: classref-descriptions-group
|
||||
|
||||
Method Descriptions
|
||||
-------------------
|
||||
|
||||
.. _class_SkeletonProfile_method_find_bone:
|
||||
|
||||
- :ref:`int<class_int>` **find_bone** **(** :ref:`StringName<class_StringName>` bone_name **)** |const|
|
||||
.. rst-class:: classref-method
|
||||
|
||||
:ref:`int<class_int>` **find_bone** **(** :ref:`StringName<class_StringName>` bone_name **)** |const|
|
||||
|
||||
Returns the bone index that matches ``bone_name`` as its name.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_get_bone_name:
|
||||
|
||||
- :ref:`StringName<class_StringName>` **get_bone_name** **(** :ref:`int<class_int>` bone_idx **)** |const|
|
||||
.. rst-class:: classref-method
|
||||
|
||||
:ref:`StringName<class_StringName>` **get_bone_name** **(** :ref:`int<class_int>` bone_idx **)** |const|
|
||||
|
||||
Returns the name of the bone at ``bone_idx`` that will be the key name in the :ref:`BoneMap<class_BoneMap>`.
|
||||
|
||||
In the retargeting process, the returned bone name is the bone name of the target skeleton.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_get_bone_parent:
|
||||
|
||||
- :ref:`StringName<class_StringName>` **get_bone_parent** **(** :ref:`int<class_int>` bone_idx **)** |const|
|
||||
.. rst-class:: classref-method
|
||||
|
||||
:ref:`StringName<class_StringName>` **get_bone_parent** **(** :ref:`int<class_int>` bone_idx **)** |const|
|
||||
|
||||
Returns the name of the bone which is the parent to the bone at ``bone_idx``. The result is empty if the bone has no parent.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_get_bone_tail:
|
||||
|
||||
- :ref:`StringName<class_StringName>` **get_bone_tail** **(** :ref:`int<class_int>` bone_idx **)** |const|
|
||||
.. rst-class:: classref-method
|
||||
|
||||
:ref:`StringName<class_StringName>` **get_bone_tail** **(** :ref:`int<class_int>` bone_idx **)** |const|
|
||||
|
||||
Returns the name of the bone which is the tail of the bone at ``bone_idx``.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_get_group:
|
||||
|
||||
- :ref:`StringName<class_StringName>` **get_group** **(** :ref:`int<class_int>` bone_idx **)** |const|
|
||||
.. rst-class:: classref-method
|
||||
|
||||
:ref:`StringName<class_StringName>` **get_group** **(** :ref:`int<class_int>` bone_idx **)** |const|
|
||||
|
||||
Returns the group of the bone at ``bone_idx``.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_get_group_name:
|
||||
|
||||
- :ref:`StringName<class_StringName>` **get_group_name** **(** :ref:`int<class_int>` group_idx **)** |const|
|
||||
.. rst-class:: classref-method
|
||||
|
||||
:ref:`StringName<class_StringName>` **get_group_name** **(** :ref:`int<class_int>` group_idx **)** |const|
|
||||
|
||||
Returns the name of the group at ``group_idx`` that will be the drawing group in the :ref:`BoneMap<class_BoneMap>` editor.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_get_handle_offset:
|
||||
|
||||
- :ref:`Vector2<class_Vector2>` **get_handle_offset** **(** :ref:`int<class_int>` bone_idx **)** |const|
|
||||
.. rst-class:: classref-method
|
||||
|
||||
:ref:`Vector2<class_Vector2>` **get_handle_offset** **(** :ref:`int<class_int>` bone_idx **)** |const|
|
||||
|
||||
Returns the offset of the bone at ``bone_idx`` that will be the button position in the :ref:`BoneMap<class_BoneMap>` editor.
|
||||
|
||||
This is the offset with origin at the top left corner of the square.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_get_reference_pose:
|
||||
|
||||
- :ref:`Transform3D<class_Transform3D>` **get_reference_pose** **(** :ref:`int<class_int>` bone_idx **)** |const|
|
||||
.. rst-class:: classref-method
|
||||
|
||||
:ref:`Transform3D<class_Transform3D>` **get_reference_pose** **(** :ref:`int<class_int>` bone_idx **)** |const|
|
||||
|
||||
Returns the reference pose transform for bone ``bone_idx``.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_get_tail_direction:
|
||||
|
||||
- :ref:`TailDirection<enum_SkeletonProfile_TailDirection>` **get_tail_direction** **(** :ref:`int<class_int>` bone_idx **)** |const|
|
||||
.. rst-class:: classref-method
|
||||
|
||||
:ref:`TailDirection<enum_SkeletonProfile_TailDirection>` **get_tail_direction** **(** :ref:`int<class_int>` bone_idx **)** |const|
|
||||
|
||||
Returns the tail direction of the bone at ``bone_idx``.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_get_texture:
|
||||
|
||||
- :ref:`Texture2D<class_Texture2D>` **get_texture** **(** :ref:`int<class_int>` group_idx **)** |const|
|
||||
.. rst-class:: classref-method
|
||||
|
||||
:ref:`Texture2D<class_Texture2D>` **get_texture** **(** :ref:`int<class_int>` group_idx **)** |const|
|
||||
|
||||
Returns the texture of the group at ``group_idx`` that will be the drawing group background image in the :ref:`BoneMap<class_BoneMap>` editor.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_set_bone_name:
|
||||
|
||||
- void **set_bone_name** **(** :ref:`int<class_int>` bone_idx, :ref:`StringName<class_StringName>` bone_name **)**
|
||||
.. rst-class:: classref-method
|
||||
|
||||
void **set_bone_name** **(** :ref:`int<class_int>` bone_idx, :ref:`StringName<class_StringName>` bone_name **)**
|
||||
|
||||
Sets the name of the bone at ``bone_idx`` that will be the key name in the :ref:`BoneMap<class_BoneMap>`.
|
||||
|
||||
In the retargeting process, the setting bone name is the bone name of the target skeleton.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_set_bone_parent:
|
||||
|
||||
- void **set_bone_parent** **(** :ref:`int<class_int>` bone_idx, :ref:`StringName<class_StringName>` bone_parent **)**
|
||||
.. rst-class:: classref-method
|
||||
|
||||
void **set_bone_parent** **(** :ref:`int<class_int>` bone_idx, :ref:`StringName<class_StringName>` bone_parent **)**
|
||||
|
||||
Sets the bone with name ``bone_parent`` as the parent of the bone at ``bone_idx``. If an empty string is passed, then the bone has no parent.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_set_bone_tail:
|
||||
|
||||
- void **set_bone_tail** **(** :ref:`int<class_int>` bone_idx, :ref:`StringName<class_StringName>` bone_tail **)**
|
||||
.. rst-class:: classref-method
|
||||
|
||||
void **set_bone_tail** **(** :ref:`int<class_int>` bone_idx, :ref:`StringName<class_StringName>` bone_tail **)**
|
||||
|
||||
Sets the bone with name ``bone_tail`` as the tail of the bone at ``bone_idx``.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_set_group:
|
||||
|
||||
- void **set_group** **(** :ref:`int<class_int>` bone_idx, :ref:`StringName<class_StringName>` group **)**
|
||||
.. rst-class:: classref-method
|
||||
|
||||
void **set_group** **(** :ref:`int<class_int>` bone_idx, :ref:`StringName<class_StringName>` group **)**
|
||||
|
||||
Sets the group of the bone at ``bone_idx``.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_set_group_name:
|
||||
|
||||
- void **set_group_name** **(** :ref:`int<class_int>` group_idx, :ref:`StringName<class_StringName>` group_name **)**
|
||||
.. rst-class:: classref-method
|
||||
|
||||
void **set_group_name** **(** :ref:`int<class_int>` group_idx, :ref:`StringName<class_StringName>` group_name **)**
|
||||
|
||||
Sets the name of the group at ``group_idx`` that will be the drawing group in the :ref:`BoneMap<class_BoneMap>` editor.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_set_handle_offset:
|
||||
|
||||
- void **set_handle_offset** **(** :ref:`int<class_int>` bone_idx, :ref:`Vector2<class_Vector2>` handle_offset **)**
|
||||
.. rst-class:: classref-method
|
||||
|
||||
void **set_handle_offset** **(** :ref:`int<class_int>` bone_idx, :ref:`Vector2<class_Vector2>` handle_offset **)**
|
||||
|
||||
Sets the offset of the bone at ``bone_idx`` that will be the button position in the :ref:`BoneMap<class_BoneMap>` editor.
|
||||
|
||||
This is the offset with origin at the top left corner of the square.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_set_reference_pose:
|
||||
|
||||
- void **set_reference_pose** **(** :ref:`int<class_int>` bone_idx, :ref:`Transform3D<class_Transform3D>` bone_name **)**
|
||||
.. rst-class:: classref-method
|
||||
|
||||
void **set_reference_pose** **(** :ref:`int<class_int>` bone_idx, :ref:`Transform3D<class_Transform3D>` bone_name **)**
|
||||
|
||||
Sets the reference pose transform for bone ``bone_idx``.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_set_tail_direction:
|
||||
|
||||
- void **set_tail_direction** **(** :ref:`int<class_int>` bone_idx, :ref:`TailDirection<enum_SkeletonProfile_TailDirection>` tail_direction **)**
|
||||
.. rst-class:: classref-method
|
||||
|
||||
void **set_tail_direction** **(** :ref:`int<class_int>` bone_idx, :ref:`TailDirection<enum_SkeletonProfile_TailDirection>` tail_direction **)**
|
||||
|
||||
Sets the tail direction of the bone at ``bone_idx``.
|
||||
|
||||
\ **Note:** This only specifies the method of calculation. The actual coordinates required should be stored in an external skeleton, so the calculation itself needs to be done externally.
|
||||
|
||||
.. rst-class:: classref-item-separator
|
||||
|
||||
----
|
||||
|
||||
.. _class_SkeletonProfile_method_set_texture:
|
||||
|
||||
- void **set_texture** **(** :ref:`int<class_int>` group_idx, :ref:`Texture2D<class_Texture2D>` texture **)**
|
||||
.. rst-class:: classref-method
|
||||
|
||||
void **set_texture** **(** :ref:`int<class_int>` group_idx, :ref:`Texture2D<class_Texture2D>` texture **)**
|
||||
|
||||
Sets the texture of the group at ``group_idx`` that will be the drawing group background image in the :ref:`BoneMap<class_BoneMap>` editor.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user