0.2.0-dev Download ZIP
45 lines ·2.6 KB Raw
| 1 | <?xml version="1.0" encoding="UTF-8" ?> |
| 2 | <class name="GLTFMesh" inherits="Resource" api_type="core" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="../../../doc/class.xsd"> |
| 3 | <brief_description> |
| 4 | GLTFMesh represents a glTF mesh. |
| 5 | </brief_description> |
| 6 | <description> |
| 7 | GLTFMesh handles 3D mesh data imported from glTF files. It includes properties for blend channels, blend weights, instance materials, and the mesh itself. |
| 8 | </description> |
| 9 | <tutorials> |
| 10 | <link title="Runtime file loading and saving">$DOCS_URL/tutorials/io/runtime_file_loading_and_saving.html</link> |
| 11 | </tutorials> |
| 12 | <methods> |
| 13 | <method name="get_additional_data"> |
| 14 | <return type="Variant" /> |
| 15 | <param index="0" name="extension_name" type="StringName" /> |
| 16 | <description> |
| 17 | Gets additional arbitrary data in this [GLTFMesh] instance. This can be used to keep per-node state data in [GLTFDocumentExtension] classes, which is important because they are stateless. |
| 18 | The argument should be the [GLTFDocumentExtension] name (does not have to match the extension name in the glTF file), and the return value can be anything you set. If nothing was set, the return value is [code]null[/code]. |
| 19 | </description> |
| 20 | </method> |
| 21 | <method name="set_additional_data"> |
| 22 | <return type="void" /> |
| 23 | <param index="0" name="extension_name" type="StringName" /> |
| 24 | <param index="1" name="additional_data" type="Variant" /> |
| 25 | <description> |
| 26 | Sets additional arbitrary data in this [GLTFMesh] instance. This can be used to keep per-node state data in [GLTFDocumentExtension] classes, which is important because they are stateless. |
| 27 | The first argument should be the [GLTFDocumentExtension] name (does not have to match the extension name in the glTF file), and the second argument can be anything you want. |
| 28 | </description> |
| 29 | </method> |
| 30 | </methods> |
| 31 | <members> |
| 32 | <member name="blend_weights" type="PackedFloat32Array" setter="set_blend_weights" getter="get_blend_weights" default="PackedFloat32Array()"> |
| 33 | An array of floats representing the blend weights of the mesh. |
| 34 | </member> |
| 35 | <member name="instance_materials" type="Material[]" setter="set_instance_materials" getter="get_instance_materials" default="[]"> |
| 36 | An array of Material objects representing the materials used in the mesh. |
| 37 | </member> |
| 38 | <member name="mesh" type="ImporterMesh" setter="set_mesh" getter="get_mesh"> |
| 39 | The [ImporterMesh] object representing the mesh itself. |
| 40 | </member> |
| 41 | <member name="original_name" type="String" setter="set_original_name" getter="get_original_name" default=""""> |
| 42 | The original name of the mesh. |
| 43 | </member> |
| 44 | </members> |
| 45 | </class> |