Merge pull request #40414 from rcorre/get-mesh-arrays-doc
Clarify how to convert PrimitiveMesh to ArrayMesh.
This commit is contained in:
commit
f131daf972
1 changed files with 6 additions and 1 deletions
|
@ -13,7 +13,12 @@
|
|||
<return type="Array">
|
||||
</return>
|
||||
<description>
|
||||
Returns mesh arrays used to constitute surface of [Mesh]. Mesh arrays can be used with [ArrayMesh] to create new surfaces.
|
||||
Returns mesh arrays used to constitute surface of [Mesh]. The result can be passed to [method ArrayMesh.add_surface_from_arrays] to create a new surface. For example:
|
||||
[codeblock]
|
||||
var c := CylinderMesh.new()
|
||||
var arr_mesh := ArrayMesh.new()
|
||||
arr_mesh.add_surface_from_arrays(Mesh.PRIMITIVE_TRIANGLES, c.get_mesh_arrays())
|
||||
[/codeblock]
|
||||
</description>
|
||||
</method>
|
||||
</methods>
|
||||
|
|
Loading…
Reference in a new issue