diff options
Diffstat (limited to 'doc/classes/ArrayMesh.xml')
-rw-r--r-- | doc/classes/ArrayMesh.xml | 45 |
1 files changed, 23 insertions, 22 deletions
diff --git a/doc/classes/ArrayMesh.xml b/doc/classes/ArrayMesh.xml index 20f8b2ab60..857897dab4 100644 --- a/doc/classes/ArrayMesh.xml +++ b/doc/classes/ArrayMesh.xml @@ -1,5 +1,5 @@ <?xml version="1.0" encoding="UTF-8" ?> -<class name="ArrayMesh" inherits="Mesh" version="3.2"> +<class name="ArrayMesh" inherits="Mesh" version="4.0"> <brief_description> [Mesh] type that provides utility for constructing a surface from arrays. </brief_description> @@ -7,7 +7,7 @@ The [ArrayMesh] is used to construct a [Mesh] by specifying the attributes as arrays. The most basic example is the creation of a single triangle: [codeblock] - var vertices = PoolVector3Array() + var vertices = PackedVector3Array() vertices.push_back(Vector3(0, 1, 0)) vertices.push_back(Vector3(1, 0, 0)) vertices.push_back(Vector3(0, 0, 1)) @@ -45,7 +45,11 @@ </argument> <argument index="2" name="blend_shapes" type="Array" default="[ ]"> </argument> - <argument index="3" name="compress_flags" type="int" default="97280"> + <argument index="3" name="lods" type="Dictionary" default="{ + +}"> + </argument> + <argument index="4" name="compress_flags" type="int" default="31744"> </argument> <description> Creates a new surface. @@ -62,6 +66,12 @@ Removes all blend shapes from this [ArrayMesh]. </description> </method> + <method name="clear_surfaces"> + <return type="void"> + </return> + <description> + </description> + </method> <method name="get_blend_shape_count" qualifiers="const"> <return type="int"> </return> @@ -150,15 +160,6 @@ Returns the primitive type of the requested surface (see [method add_surface_from_arrays]). </description> </method> - <method name="surface_remove"> - <return type="void"> - </return> - <argument index="0" name="surf_idx" type="int"> - </argument> - <description> - Removes a surface at position [code]surf_idx[/code], shifting greater surfaces one [code]surf_idx[/code] slot down. - </description> - </method> <method name="surface_set_name"> <return type="void"> </return> @@ -177,7 +178,7 @@ </argument> <argument index="1" name="offset" type="int"> </argument> - <argument index="2" name="data" type="PoolByteArray"> + <argument index="2" name="data" type="PackedByteArray"> </argument> <description> Updates a specified region of mesh arrays on the GPU. @@ -201,31 +202,31 @@ Amount of weights/bone indices per vertex (always 4). </constant> <constant name="ARRAY_VERTEX" value="0" enum="ArrayType"> - [PoolVector3Array], [PoolVector2Array], or [Array] of vertex positions. + [PackedVector3Array], [PackedVector2Array], or [Array] of vertex positions. </constant> <constant name="ARRAY_NORMAL" value="1" enum="ArrayType"> - [PoolVector3Array] of vertex normals. + [PackedVector3Array] of vertex normals. </constant> <constant name="ARRAY_TANGENT" value="2" enum="ArrayType"> - [PoolRealArray] of vertex tangents. Each element in groups of 4 floats, first 3 floats determine the tangent, and the last the binormal direction as -1 or 1. + [PackedRealArray] of vertex tangents. Each element in groups of 4 floats, first 3 floats determine the tangent, and the last the binormal direction as -1 or 1. </constant> <constant name="ARRAY_COLOR" value="3" enum="ArrayType"> - [PoolColorArray] of vertex colors. + [PackedColorArray] of vertex colors. </constant> <constant name="ARRAY_TEX_UV" value="4" enum="ArrayType"> - [PoolVector2Array] for UV coordinates. + [PackedVector2Array] for UV coordinates. </constant> <constant name="ARRAY_TEX_UV2" value="5" enum="ArrayType"> - [PoolVector2Array] for second UV coordinates. + [PackedVector2Array] for second UV coordinates. </constant> <constant name="ARRAY_BONES" value="6" enum="ArrayType"> - [PoolRealArray] or [PoolIntArray] of bone indices. Each element in groups of 4 floats. + [PackedRealArray] or [PackedIntArray] of bone indices. Each element in groups of 4 floats. </constant> <constant name="ARRAY_WEIGHTS" value="7" enum="ArrayType"> - [PoolRealArray] of bone weights. Each element in groups of 4 floats. + [PackedRealArray] of bone weights. Each element in groups of 4 floats. </constant> <constant name="ARRAY_INDEX" value="8" enum="ArrayType"> - [PoolIntArray] of integers used as indices referencing vertices, colors, normals, tangents, and textures. All of those arrays must have the same number of elements as the vertex array. No index can be beyond the vertex array size. When this index array is present, it puts the function into "index mode," where the index selects the *i*'th vertex, normal, tangent, color, UV, etc. This means if you want to have different normals or colors along an edge, you have to duplicate the vertices. + [PackedIntArray] of integers used as indices referencing vertices, colors, normals, tangents, and textures. All of those arrays must have the same number of elements as the vertex array. No index can be beyond the vertex array size. When this index array is present, it puts the function into "index mode," where the index selects the *i*'th vertex, normal, tangent, color, UV, etc. This means if you want to have different normals or colors along an edge, you have to duplicate the vertices. For triangles, the index array is interpreted as triples, referring to the vertices of each triangle. For lines, the index array is in pairs indicating the start and end of each line. </constant> <constant name="ARRAY_MAX" value="9" enum="ArrayType"> |