doc: Sync classref with current source
And fixups: - Add missing bindings in RenderingServer - Remove duplicate ArrayMesh enum bindings (they're in Mesh already) - Remove redundant _unhandled_key_input binding in Control (it's in Node already)
This commit is contained in:
parent
3dc8aaaccc
commit
1a001ad964
20 changed files with 371 additions and 336 deletions
|
@ -16,8 +16,8 @@
|
|||
# Initialize the ArrayMesh.
|
||||
var arr_mesh = ArrayMesh.new()
|
||||
var arrays = []
|
||||
arrays.resize(ArrayMesh.ARRAY_MAX)
|
||||
arrays[ArrayMesh.ARRAY_VERTEX] = vertices
|
||||
arrays.resize(Mesh.ARRAY_MAX)
|
||||
arrays[Mesh.ARRAY_VERTEX] = vertices
|
||||
|
||||
# Create the Mesh.
|
||||
arr_mesh.add_surface_from_arrays(Mesh.PRIMITIVE_TRIANGLES, arrays)
|
||||
|
@ -33,8 +33,8 @@
|
|||
// Initialize the ArrayMesh.
|
||||
var arrMesh = new ArrayMesh();
|
||||
var arrays = new Godot.Collections.Array();
|
||||
arrays.Resize((int)ArrayMesh.ArrayType.Max);
|
||||
arrays[(int)ArrayMesh.ArrayType.Vertex] = vertices;
|
||||
arrays.Resize((int)Mesh.ArrayType.Max);
|
||||
arrays[(int)Mesh.ArrayType.Vertex] = vertices;
|
||||
|
||||
// Create the Mesh.
|
||||
arrMesh.AddSurfaceFromArrays(Mesh.PrimitiveType.Triangles, arrays);
|
||||
|
@ -71,12 +71,12 @@
|
|||
<argument index="3" name="lods" type="Dictionary" default="{
|
||||
}">
|
||||
</argument>
|
||||
<argument index="4" name="compress_flags" type="int" default="31744">
|
||||
<argument index="4" name="compress_flags" type="int" default="0">
|
||||
</argument>
|
||||
<description>
|
||||
Creates a new surface.
|
||||
Surfaces are created to be rendered using a [code]primitive[/code], which may be any of the types defined in [enum Mesh.PrimitiveType]. (As a note, when using indices, it is recommended to only use points, lines or triangles.) [method Mesh.get_surface_count] will become the [code]surf_idx[/code] for this new surface.
|
||||
The [code]arrays[/code] argument is an array of arrays. See [enum ArrayType] for the values used in this array. For example, [code]arrays[0][/code] is the array of vertices. That first vertex sub-array is always required; the others are optional. Adding an index array puts this function into "index mode" where the vertex and other arrays become the sources of data and the index array defines the vertex order. All sub-arrays must have the same length as the vertex array or be empty, except for [constant ARRAY_INDEX] if it is used.
|
||||
The [code]arrays[/code] argument is an array of arrays. See [enum Mesh.ArrayType] for the values used in this array. For example, [code]arrays[0][/code] is the array of vertices. That first vertex sub-array is always required; the others are optional. Adding an index array puts this function into "index mode" where the vertex and other arrays become the sources of data and the index array defines the vertex order. All sub-arrays must have the same length as the vertex array or be empty, except for [constant Mesh.ARRAY_INDEX] if it is used.
|
||||
Adding an index array puts this function into "index mode" where the vertex and other arrays become the sources of data, and the index array defines the order of the vertices.
|
||||
</description>
|
||||
</method>
|
||||
|
@ -217,69 +217,5 @@
|
|||
</member>
|
||||
</members>
|
||||
<constants>
|
||||
<constant name="NO_INDEX_ARRAY" value="-1">
|
||||
Default value used for index_array_len when no indices are present.
|
||||
</constant>
|
||||
<constant name="ARRAY_WEIGHTS_SIZE" value="4">
|
||||
Amount of weights/bone indices per vertex (always 4).
|
||||
</constant>
|
||||
<constant name="ARRAY_VERTEX" value="0" enum="ArrayType">
|
||||
[PackedVector3Array], [PackedVector2Array], or [Array] of vertex positions.
|
||||
</constant>
|
||||
<constant name="ARRAY_NORMAL" value="1" enum="ArrayType">
|
||||
[PackedVector3Array] of vertex normals.
|
||||
</constant>
|
||||
<constant name="ARRAY_TANGENT" value="2" enum="ArrayType">
|
||||
[PackedFloat32Array] 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">
|
||||
[PackedColorArray] of vertex colors.
|
||||
</constant>
|
||||
<constant name="ARRAY_TEX_UV" value="4" enum="ArrayType">
|
||||
[PackedVector2Array] for UV coordinates.
|
||||
</constant>
|
||||
<constant name="ARRAY_TEX_UV2" value="5" enum="ArrayType">
|
||||
[PackedVector2Array] for second UV coordinates.
|
||||
</constant>
|
||||
<constant name="ARRAY_BONES" value="6" enum="ArrayType">
|
||||
[PackedFloat32Array] or [PackedInt32Array] of bone indices. Each element in groups of 4 floats.
|
||||
</constant>
|
||||
<constant name="ARRAY_WEIGHTS" value="7" enum="ArrayType">
|
||||
[PackedFloat32Array] of bone weights. Each element in groups of 4 floats.
|
||||
</constant>
|
||||
<constant name="ARRAY_INDEX" value="8" enum="ArrayType">
|
||||
[PackedInt32Array] 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">
|
||||
Represents the size of the [enum ArrayType] enum.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_VERTEX" value="1" enum="ArrayFormat">
|
||||
Array format will include vertices (mandatory).
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_NORMAL" value="2" enum="ArrayFormat">
|
||||
Array format will include normals.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_TANGENT" value="4" enum="ArrayFormat">
|
||||
Array format will include tangents.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_COLOR" value="8" enum="ArrayFormat">
|
||||
Array format will include a color array.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_TEX_UV" value="16" enum="ArrayFormat">
|
||||
Array format will include UVs.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_TEX_UV2" value="32" enum="ArrayFormat">
|
||||
Array format will include another set of UVs.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_BONES" value="64" enum="ArrayFormat">
|
||||
Array format will include bone indices.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_WEIGHTS" value="128" enum="ArrayFormat">
|
||||
Array format will include bone weights.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_INDEX" value="256" enum="ArrayFormat">
|
||||
Index array will be used.
|
||||
</constant>
|
||||
</constants>
|
||||
</class>
|
||||
|
|
|
@ -255,6 +255,14 @@
|
|||
<description>
|
||||
</description>
|
||||
</method>
|
||||
<method name="operator -" qualifiers="operator">
|
||||
<return type="Color">
|
||||
</return>
|
||||
<argument index="0" name="right" type="Color">
|
||||
</argument>
|
||||
<description>
|
||||
</description>
|
||||
</method>
|
||||
<method name="operator /" qualifiers="operator">
|
||||
<return type="Color">
|
||||
</return>
|
||||
|
|
|
@ -18,6 +18,8 @@
|
|||
<member name="occluder" type="OccluderPolygon2D" setter="set_occluder_polygon" getter="get_occluder_polygon">
|
||||
The [OccluderPolygon2D] used to compute the shadow.
|
||||
</member>
|
||||
<member name="sdf_collision" type="bool" setter="set_as_sdf_collision" getter="is_set_as_sdf_collision" default="true">
|
||||
</member>
|
||||
</members>
|
||||
<constants>
|
||||
</constants>
|
||||
|
|
|
@ -39,6 +39,7 @@
|
|||
</method>
|
||||
</methods>
|
||||
<members>
|
||||
<member name="focus_mode" type="int" setter="set_focus_mode" getter="get_focus_mode" override="true" enum="Control.FocusMode" default="0" />
|
||||
<member name="language" type="String" setter="set_language" getter="get_language" default="""">
|
||||
Language code used for line-breaking and text shaping algorithms, if left empty current locale is used instead.
|
||||
</member>
|
||||
|
|
|
@ -31,6 +31,7 @@
|
|||
<members>
|
||||
<member name="action_mode" type="int" setter="set_action_mode" getter="get_action_mode" override="true" enum="BaseButton.ActionMode" default="0" />
|
||||
<member name="flat" type="bool" setter="set_flat" getter="is_flat" override="true" default="true" />
|
||||
<member name="focus_mode" type="int" setter="set_focus_mode" getter="get_focus_mode" override="true" enum="Control.FocusMode" default="0" />
|
||||
<member name="switch_on_hover" type="bool" setter="set_switch_on_hover" getter="is_switch_on_hover" default="false">
|
||||
If [code]true[/code], when the cursor hovers above another [MenuButton] within the same parent which also has [code]switch_on_hover[/code] enabled, it will close the current [MenuButton] and open the other one.
|
||||
</member>
|
||||
|
|
|
@ -132,57 +132,6 @@
|
|||
<constant name="BLEND_SHAPE_MODE_RELATIVE" value="1" enum="BlendShapeMode">
|
||||
Blend shapes are relative to base weight.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_VERTEX" value="1" enum="ArrayFormat">
|
||||
Mesh array contains vertices. All meshes require a vertex array so this should always be present.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_NORMAL" value="2" enum="ArrayFormat">
|
||||
Mesh array contains normals.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_TANGENT" value="4" enum="ArrayFormat">
|
||||
Mesh array contains tangents.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_COLOR" value="8" enum="ArrayFormat">
|
||||
Mesh array contains colors.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_TEX_UV" value="16" enum="ArrayFormat">
|
||||
Mesh array contains UVs.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_TEX_UV2" value="32" enum="ArrayFormat">
|
||||
Mesh array contains second UV.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_BONES" value="64" enum="ArrayFormat">
|
||||
Mesh array contains bones.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_WEIGHTS" value="128" enum="ArrayFormat">
|
||||
Mesh array contains bone weights.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_INDEX" value="256" enum="ArrayFormat">
|
||||
Mesh array uses indices.
|
||||
</constant>
|
||||
<constant name="ARRAY_COMPRESS_NORMAL" value="1024" enum="ArrayFormat">
|
||||
Flag used to mark a compressed (half float) normal array.
|
||||
</constant>
|
||||
<constant name="ARRAY_COMPRESS_TANGENT" value="2048" enum="ArrayFormat">
|
||||
Flag used to mark a compressed (half float) tangent array.
|
||||
</constant>
|
||||
<constant name="ARRAY_COMPRESS_COLOR" value="4096" enum="ArrayFormat">
|
||||
Flag used to mark a compressed (half float) color array.
|
||||
</constant>
|
||||
<constant name="ARRAY_COMPRESS_TEX_UV" value="8192" enum="ArrayFormat">
|
||||
Flag used to mark a compressed (half float) UV coordinates array.
|
||||
</constant>
|
||||
<constant name="ARRAY_COMPRESS_TEX_UV2" value="16384" enum="ArrayFormat">
|
||||
Flag used to mark a compressed (half float) UV coordinates array for the second UV coordinates.
|
||||
</constant>
|
||||
<constant name="ARRAY_COMPRESS_INDEX" value="131072" enum="ArrayFormat">
|
||||
Flag used to mark a compressed index array.
|
||||
</constant>
|
||||
<constant name="ARRAY_FLAG_USE_2D_VERTICES" value="262144" enum="ArrayFormat">
|
||||
Flag used to mark that the array contains 2D vertices.
|
||||
</constant>
|
||||
<constant name="ARRAY_COMPRESS_DEFAULT" value="31744" enum="ArrayFormat">
|
||||
Used to set flags [constant ARRAY_COMPRESS_NORMAL], [constant ARRAY_COMPRESS_TANGENT], [constant ARRAY_COMPRESS_COLOR], [constant ARRAY_COMPRESS_TEX_UV] and [constant ARRAY_COMPRESS_TEX_UV2] quickly.
|
||||
</constant>
|
||||
<constant name="ARRAY_VERTEX" value="0" enum="ArrayType">
|
||||
Array of vertices.
|
||||
</constant>
|
||||
|
@ -201,17 +150,101 @@
|
|||
<constant name="ARRAY_TEX_UV2" value="5" enum="ArrayType">
|
||||
Array of second set of UV coordinates.
|
||||
</constant>
|
||||
<constant name="ARRAY_BONES" value="6" enum="ArrayType">
|
||||
<constant name="ARRAY_CUSTOM0" value="6" enum="ArrayType">
|
||||
</constant>
|
||||
<constant name="ARRAY_CUSTOM1" value="7" enum="ArrayType">
|
||||
</constant>
|
||||
<constant name="ARRAY_CUSTOM2" value="8" enum="ArrayType">
|
||||
</constant>
|
||||
<constant name="ARRAY_CUSTOM3" value="9" enum="ArrayType">
|
||||
</constant>
|
||||
<constant name="ARRAY_BONES" value="10" enum="ArrayType">
|
||||
Array of bone data.
|
||||
</constant>
|
||||
<constant name="ARRAY_WEIGHTS" value="7" enum="ArrayType">
|
||||
<constant name="ARRAY_WEIGHTS" value="11" enum="ArrayType">
|
||||
Array of weights.
|
||||
</constant>
|
||||
<constant name="ARRAY_INDEX" value="8" enum="ArrayType">
|
||||
<constant name="ARRAY_INDEX" value="12" enum="ArrayType">
|
||||
Array of indices.
|
||||
</constant>
|
||||
<constant name="ARRAY_MAX" value="9" enum="ArrayType">
|
||||
<constant name="ARRAY_MAX" value="13" enum="ArrayType">
|
||||
Represents the size of the [enum ArrayType] enum.
|
||||
</constant>
|
||||
<constant name="ARRAY_CUSTOM_RGBA8_UNORM" value="0" enum="ArrayCustomFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_CUSTOM_RGBA8_SNORM" value="1" enum="ArrayCustomFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_CUSTOM_RG_HALF" value="2" enum="ArrayCustomFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_CUSTOM_RGBA_HALF" value="3" enum="ArrayCustomFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_CUSTOM_R_FLOAT" value="4" enum="ArrayCustomFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_CUSTOM_RG_FLOAT" value="5" enum="ArrayCustomFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_CUSTOM_RGB_FLOAT" value="6" enum="ArrayCustomFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_CUSTOM_RGBA_FLOAT" value="7" enum="ArrayCustomFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_CUSTOM_MAX" value="8" enum="ArrayCustomFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_VERTEX" value="1" enum="ArrayFormat">
|
||||
Mesh array contains vertices. All meshes require a vertex array so this should always be present.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_NORMAL" value="2" enum="ArrayFormat">
|
||||
Mesh array contains normals.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_TANGENT" value="4" enum="ArrayFormat">
|
||||
Mesh array contains tangents.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_COLOR" value="8" enum="ArrayFormat">
|
||||
Mesh array contains colors.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_TEX_UV" value="16" enum="ArrayFormat">
|
||||
Mesh array contains UVs.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_TEX_UV2" value="32" enum="ArrayFormat">
|
||||
Mesh array contains second UV.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_CUSTOM0" value="64" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_CUSTOM1" value="128" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_CUSTOM2" value="256" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_CUSTOM3" value="512" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_BONES" value="1024" enum="ArrayFormat">
|
||||
Mesh array contains bones.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_WEIGHTS" value="2048" enum="ArrayFormat">
|
||||
Mesh array contains bone weights.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_INDEX" value="4096" enum="ArrayFormat">
|
||||
Mesh array uses indices.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_BLEND_SHAPE_MASK" value="-8185" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_CUSTOM_BASE" value="13" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_CUSTOM0_SHIFT" value="13" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_CUSTOM1_SHIFT" value="16" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_CUSTOM2_SHIFT" value="19" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_CUSTOM3_SHIFT" value="22" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_CUSTOM_MASK" value="7" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_COMPRESS_FLAGS_BASE" value="25" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FLAG_USE_2D_VERTICES" value="33554432" enum="ArrayFormat">
|
||||
Flag used to mark that the array contains 2D vertices.
|
||||
</constant>
|
||||
<constant name="ARRAY_FLAG_USE_DYNAMIC_UPDATE" value="67108864" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FLAG_USE_8_BONE_WEIGHTS" value="134217728" enum="ArrayFormat">
|
||||
</constant>
|
||||
</constants>
|
||||
</class>
|
||||
|
|
|
@ -169,8 +169,8 @@
|
|||
<return type="int">
|
||||
</return>
|
||||
<description>
|
||||
Returns the [Mesh]'s format. Format is an integer made up of [Mesh] format flags combined together. For example, a mesh containing both vertices and normals would return a format of [code]3[/code] because [constant ArrayMesh.ARRAY_FORMAT_VERTEX] is [code]1[/code] and [constant ArrayMesh.ARRAY_FORMAT_NORMAL] is [code]2[/code].
|
||||
See [enum ArrayMesh.ArrayFormat] for a list of format flags.
|
||||
Returns the [Mesh]'s format. Format is an integer made up of [Mesh] format flags combined together. For example, a mesh containing both vertices and normals would return a format of [code]3[/code] because [constant Mesh.ARRAY_FORMAT_VERTEX] is [code]1[/code] and [constant Mesh.ARRAY_FORMAT_NORMAL] is [code]2[/code].
|
||||
See [enum Mesh.ArrayFormat] for a list of format flags.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_material" qualifiers="const">
|
||||
|
|
|
@ -117,9 +117,6 @@
|
|||
<member name="mass" type="float" setter="set_mass" getter="get_mass" default="1.0">
|
||||
The body's mass.
|
||||
</member>
|
||||
<member name="weight" type="float" setter="set_weight" getter="get_weight" default="9.8">
|
||||
The body's weight based on its mass and the global 3D gravity. Global values are set in [b]Project > Project Settings > Physics > 3d[/b].
|
||||
</member>
|
||||
</members>
|
||||
<constants>
|
||||
<constant name="JOINT_TYPE_NONE" value="0" enum="JointType">
|
||||
|
|
|
@ -1084,6 +1084,10 @@
|
|||
</member>
|
||||
<member name="rendering/quality/2d/snap_2d_vertices_to_pixel" type="bool" setter="" getter="" default="false">
|
||||
</member>
|
||||
<member name="rendering/quality/2d_sdf/oversize" type="int" setter="" getter="" default="1">
|
||||
</member>
|
||||
<member name="rendering/quality/2d_sdf/scale" type="int" setter="" getter="" default="1">
|
||||
</member>
|
||||
<member name="rendering/quality/2d_shadow_atlas/size" type="int" setter="" getter="" default="2048">
|
||||
</member>
|
||||
<member name="rendering/quality/depth_of_field/depth_of_field_bokeh_quality" type="int" setter="" getter="" default="2">
|
||||
|
|
|
@ -218,6 +218,14 @@
|
|||
<description>
|
||||
</description>
|
||||
</method>
|
||||
<method name="operator -" qualifiers="operator">
|
||||
<return type="Quat">
|
||||
</return>
|
||||
<argument index="0" name="right" type="Quat">
|
||||
</argument>
|
||||
<description>
|
||||
</description>
|
||||
</method>
|
||||
<method name="operator /" qualifiers="operator">
|
||||
<return type="Quat">
|
||||
</return>
|
||||
|
|
|
@ -537,17 +537,6 @@
|
|||
Sets the shape of the occluder polygon.
|
||||
</description>
|
||||
</method>
|
||||
<method name="canvas_occluder_polygon_set_shape_as_lines">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="occluder_polygon" type="RID">
|
||||
</argument>
|
||||
<argument index="1" name="shape" type="PackedVector2Array">
|
||||
</argument>
|
||||
<description>
|
||||
Sets the shape of the occluder polygon as lines.
|
||||
</description>
|
||||
</method>
|
||||
<method name="canvas_set_item_mirroring">
|
||||
<return type="void">
|
||||
</return>
|
||||
|
@ -1625,25 +1614,6 @@
|
|||
Sets a shader material's shader.
|
||||
</description>
|
||||
</method>
|
||||
<method name="mesh_add_surface_from_arrays">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="mesh" type="RID">
|
||||
</argument>
|
||||
<argument index="1" name="primitive" type="int" enum="RenderingServer.PrimitiveType">
|
||||
</argument>
|
||||
<argument index="2" name="arrays" type="Array">
|
||||
</argument>
|
||||
<argument index="3" name="blend_shapes" type="Array" default="[ ]">
|
||||
</argument>
|
||||
<argument index="4" name="lods" type="Dictionary" default="{
|
||||
}">
|
||||
</argument>
|
||||
<argument index="5" name="compress_format" type="int" default="31744">
|
||||
</argument>
|
||||
<description>
|
||||
</description>
|
||||
</method>
|
||||
<method name="mesh_clear">
|
||||
<return type="void">
|
||||
</return>
|
||||
|
@ -1742,32 +1712,46 @@
|
|||
Returns a mesh's surface's arrays for blend shapes.
|
||||
</description>
|
||||
</method>
|
||||
<method name="mesh_surface_get_format_attribute_stride" qualifiers="const">
|
||||
<return type="int">
|
||||
</return>
|
||||
<argument index="0" name="format" type="int">
|
||||
</argument>
|
||||
<argument index="1" name="vertex_count" type="int">
|
||||
</argument>
|
||||
<description>
|
||||
</description>
|
||||
</method>
|
||||
<method name="mesh_surface_get_format_offset" qualifiers="const">
|
||||
<return type="int">
|
||||
</return>
|
||||
<argument index="0" name="format" type="int">
|
||||
</argument>
|
||||
<argument index="1" name="vertex_len" type="int">
|
||||
<argument index="1" name="vertex_count" type="int">
|
||||
</argument>
|
||||
<argument index="2" name="index_len" type="int">
|
||||
</argument>
|
||||
<argument index="3" name="array_index" type="int">
|
||||
<argument index="2" name="array_index" type="int">
|
||||
</argument>
|
||||
<description>
|
||||
Function is unused in Godot 3.x.
|
||||
</description>
|
||||
</method>
|
||||
<method name="mesh_surface_get_format_stride" qualifiers="const">
|
||||
<method name="mesh_surface_get_format_skin_stride" qualifiers="const">
|
||||
<return type="int">
|
||||
</return>
|
||||
<argument index="0" name="format" type="int">
|
||||
</argument>
|
||||
<argument index="1" name="vertex_len" type="int">
|
||||
</argument>
|
||||
<argument index="2" name="index_len" type="int">
|
||||
<argument index="1" name="vertex_count" type="int">
|
||||
</argument>
|
||||
<description>
|
||||
</description>
|
||||
</method>
|
||||
<method name="mesh_surface_get_format_vertex_stride" qualifiers="const">
|
||||
<return type="int">
|
||||
</return>
|
||||
<argument index="0" name="format" type="int">
|
||||
</argument>
|
||||
<argument index="1" name="vertex_count" type="int">
|
||||
</argument>
|
||||
<description>
|
||||
Function is unused in Godot 3.x.
|
||||
</description>
|
||||
</method>
|
||||
<method name="mesh_surface_get_material" qualifiers="const">
|
||||
|
@ -3084,16 +3068,24 @@
|
|||
<constant name="ARRAY_TEX_UV2" value="5" enum="ArrayType">
|
||||
Array is an UV coordinates array for the second UV coordinates.
|
||||
</constant>
|
||||
<constant name="ARRAY_BONES" value="6" enum="ArrayType">
|
||||
<constant name="ARRAY_CUSTOM0" value="6" enum="ArrayType">
|
||||
</constant>
|
||||
<constant name="ARRAY_CUSTOM1" value="7" enum="ArrayType">
|
||||
</constant>
|
||||
<constant name="ARRAY_CUSTOM2" value="8" enum="ArrayType">
|
||||
</constant>
|
||||
<constant name="ARRAY_CUSTOM3" value="9" enum="ArrayType">
|
||||
</constant>
|
||||
<constant name="ARRAY_BONES" value="10" enum="ArrayType">
|
||||
Array contains bone information.
|
||||
</constant>
|
||||
<constant name="ARRAY_WEIGHTS" value="7" enum="ArrayType">
|
||||
<constant name="ARRAY_WEIGHTS" value="11" enum="ArrayType">
|
||||
Array is weight information.
|
||||
</constant>
|
||||
<constant name="ARRAY_INDEX" value="8" enum="ArrayType">
|
||||
<constant name="ARRAY_INDEX" value="12" enum="ArrayType">
|
||||
Array is index array.
|
||||
</constant>
|
||||
<constant name="ARRAY_MAX" value="9" enum="ArrayType">
|
||||
<constant name="ARRAY_MAX" value="13" enum="ArrayType">
|
||||
Represents the size of the [enum ArrayType] enum.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_VERTEX" value="1" enum="ArrayFormat">
|
||||
|
@ -3114,40 +3106,45 @@
|
|||
<constant name="ARRAY_FORMAT_TEX_UV2" value="32" enum="ArrayFormat">
|
||||
Flag used to mark an UV coordinates array for the second UV coordinates.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_BONES" value="64" enum="ArrayFormat">
|
||||
<constant name="ARRAY_FORMAT_CUSTOM0" value="64" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_CUSTOM1" value="128" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_CUSTOM2" value="256" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_CUSTOM3" value="512" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_BONES" value="1024" enum="ArrayFormat">
|
||||
Flag used to mark a bone information array.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_WEIGHTS" value="128" enum="ArrayFormat">
|
||||
<constant name="ARRAY_FORMAT_WEIGHTS" value="2048" enum="ArrayFormat">
|
||||
Flag used to mark a weights array.
|
||||
</constant>
|
||||
<constant name="ARRAY_FORMAT_INDEX" value="256" enum="ArrayFormat">
|
||||
<constant name="ARRAY_FORMAT_INDEX" value="4096" enum="ArrayFormat">
|
||||
Flag used to mark an index array.
|
||||
</constant>
|
||||
<constant name="ARRAY_COMPRESS_NORMAL" value="1024" enum="ArrayFormat">
|
||||
Flag used to mark a compressed (half float) normal array.
|
||||
<constant name="ARRAY_FORMAT_BLEND_SHAPE_MASK" value="-8185" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_COMPRESS_TANGENT" value="2048" enum="ArrayFormat">
|
||||
Flag used to mark a compressed (half float) tangent array.
|
||||
<constant name="ARRAY_FORMAT_CUSTOM_BASE" value="13" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_COMPRESS_COLOR" value="4096" enum="ArrayFormat">
|
||||
Flag used to mark a compressed (half float) color array.
|
||||
<constant name="ARRAY_FORMAT_CUSTOM0_SHIFT" value="13" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_COMPRESS_TEX_UV" value="8192" enum="ArrayFormat">
|
||||
Flag used to mark a compressed (half float) UV coordinates array.
|
||||
<constant name="ARRAY_FORMAT_CUSTOM1_SHIFT" value="16" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_COMPRESS_TEX_UV2" value="16384" enum="ArrayFormat">
|
||||
Flag used to mark a compressed (half float) UV coordinates array for the second UV coordinates.
|
||||
<constant name="ARRAY_FORMAT_CUSTOM2_SHIFT" value="19" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_COMPRESS_INDEX" value="131072" enum="ArrayFormat">
|
||||
Flag used to mark a compressed index array.
|
||||
<constant name="ARRAY_FORMAT_CUSTOM3_SHIFT" value="22" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_COMPRESS_DEFAULT" value="31744" enum="ArrayFormat">
|
||||
Used to set flags [constant ARRAY_COMPRESS_NORMAL], [constant ARRAY_COMPRESS_TANGENT], [constant ARRAY_COMPRESS_COLOR], [constant ARRAY_COMPRESS_TEX_UV] and [constant ARRAY_COMPRESS_TEX_UV2] quickly.
|
||||
<constant name="ARRAY_FORMAT_CUSTOM_MASK" value="7" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FLAG_USE_2D_VERTICES" value="262144" enum="ArrayFormat">
|
||||
<constant name="ARRAY_COMPRESS_FLAGS_BASE" value="25" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FLAG_USE_2D_VERTICES" value="33554432" enum="ArrayFormat">
|
||||
Flag used to mark that the array contains 2D vertices.
|
||||
</constant>
|
||||
<constant name="ARRAY_FLAG_USE_DYNAMIC_UPDATE" value="1048576" enum="ArrayFormat">
|
||||
<constant name="ARRAY_FLAG_USE_DYNAMIC_UPDATE" value="67108864" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="ARRAY_FLAG_USE_8_BONE_WEIGHTS" value="134217728" enum="ArrayFormat">
|
||||
</constant>
|
||||
<constant name="PRIMITIVE_POINTS" value="0" enum="PrimitiveType">
|
||||
Primitive to draw consists of points.
|
||||
|
|
|
@ -329,9 +329,6 @@
|
|||
The raw text of the label.
|
||||
When set, clears the tag stack and adds a raw text tag to the top of it. Does not parse BBCodes. Does not modify [member bbcode_text].
|
||||
</member>
|
||||
<member name="text_direction" type="int" setter="set_text_direction" getter="get_text_direction" enum="Control.TextDirection" default="0">
|
||||
Base text writing direction.
|
||||
</member>
|
||||
<member name="visible_characters" type="int" setter="set_visible_characters" getter="get_visible_characters" default="-1">
|
||||
The restricted number of characters to display in the label. If [code]-1[/code], all characters will be displayed.
|
||||
</member>
|
||||
|
|
|
@ -8,11 +8,11 @@
|
|||
[codeblock]
|
||||
var st = SurfaceTool.new()
|
||||
st.begin(Mesh.PRIMITIVE_TRIANGLES)
|
||||
st.add_color(Color(1, 0, 0))
|
||||
st.add_uv(Vector2(0, 0))
|
||||
st.add_vertex(Vector3(0, 0, 0))
|
||||
st.set_color(Color(1, 0, 0))
|
||||
st.set_uv(Vector2(0, 0))
|
||||
st.set_vertex(Vector3(0, 0, 0))
|
||||
[/codeblock]
|
||||
The above [SurfaceTool] now contains one vertex of a triangle which has a UV coordinate and a specified [Color]. If another vertex were added without calling [method add_uv] or [method add_color], then the last values would be used.
|
||||
The above [SurfaceTool] now contains one vertex of a triangle which has a UV coordinate and a specified [Color]. If another vertex were added without calling [method set_uv] or [method set_color], then the last values would be used.
|
||||
Vertex attributes must be passed [b]before[/b] calling [method add_vertex]. Failure to do so will result in an error when committing the vertex information to a mesh.
|
||||
Additionally, the attributes used before the first vertex is added determine the format of the mesh. For example, if you only add UVs to the first vertex, you cannot add color to any of the subsequent vertices.
|
||||
See also [ArrayMesh], [ImmediateGeometry3D] and [MeshDataTool] for procedural geometry generation.
|
||||
|
@ -22,25 +22,6 @@
|
|||
<link title="3D Voxel Demo">https://godotengine.org/asset-library/asset/676</link>
|
||||
</tutorials>
|
||||
<methods>
|
||||
<method name="add_bones">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="bones" type="PackedInt32Array">
|
||||
</argument>
|
||||
<description>
|
||||
Adds an array of bones for the next vertex to use. [code]bones[/code] must contain 4 integers.
|
||||
</description>
|
||||
</method>
|
||||
<method name="add_color">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="color" type="Color">
|
||||
</argument>
|
||||
<description>
|
||||
Specifies a [Color] for the next vertex to use.
|
||||
[b]Note:[/b] The material must have [member BaseMaterial3D.vertex_color_use_as_albedo] enabled for the vertex color to be visible.
|
||||
</description>
|
||||
</method>
|
||||
<method name="add_index">
|
||||
<return type="void">
|
||||
</return>
|
||||
|
@ -50,15 +31,6 @@
|
|||
Adds an index to index array if you are using indexed vertices. Does not need to be called before adding vertices.
|
||||
</description>
|
||||
</method>
|
||||
<method name="add_normal">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="normal" type="Vector3">
|
||||
</argument>
|
||||
<description>
|
||||
Specifies a normal for the next vertex to use.
|
||||
</description>
|
||||
</method>
|
||||
<method name="add_smooth_group">
|
||||
<return type="void">
|
||||
</return>
|
||||
|
@ -68,15 +40,6 @@
|
|||
Specifies whether the current vertex (if using only vertex arrays) or current index (if also using index arrays) should use smooth normals for normal calculation.
|
||||
</description>
|
||||
</method>
|
||||
<method name="add_tangent">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="tangent" type="Plane">
|
||||
</argument>
|
||||
<description>
|
||||
Specifies a tangent for the next vertex to use.
|
||||
</description>
|
||||
</method>
|
||||
<method name="add_triangle_fan">
|
||||
<return type="void">
|
||||
</return>
|
||||
|
@ -97,24 +60,6 @@
|
|||
Requires the primitive type be set to [constant Mesh.PRIMITIVE_TRIANGLES].
|
||||
</description>
|
||||
</method>
|
||||
<method name="add_uv">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="uv" type="Vector2">
|
||||
</argument>
|
||||
<description>
|
||||
Specifies a set of UV coordinates to use for the next vertex.
|
||||
</description>
|
||||
</method>
|
||||
<method name="add_uv2">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="uv2" type="Vector2">
|
||||
</argument>
|
||||
<description>
|
||||
Specifies an optional second set of UV coordinates to use for the next vertex.
|
||||
</description>
|
||||
</method>
|
||||
<method name="add_vertex">
|
||||
<return type="void">
|
||||
</return>
|
||||
|
@ -124,15 +69,6 @@
|
|||
Specifies the position of current vertex. Should be called after specifying other vertex properties (e.g. Color, UV).
|
||||
</description>
|
||||
</method>
|
||||
<method name="add_weights">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="weights" type="PackedFloat32Array">
|
||||
</argument>
|
||||
<description>
|
||||
Specifies weight values for next vertex to use. [code]weights[/code] must contain 4 values.
|
||||
</description>
|
||||
</method>
|
||||
<method name="append_from">
|
||||
<return type="void">
|
||||
</return>
|
||||
|
@ -167,11 +103,11 @@
|
|||
</return>
|
||||
<argument index="0" name="existing" type="ArrayMesh" default="null">
|
||||
</argument>
|
||||
<argument index="1" name="flags" type="int" default="31744">
|
||||
<argument index="1" name="flags" type="int" default="0">
|
||||
</argument>
|
||||
<description>
|
||||
Returns a constructed [ArrayMesh] from current information passed in. If an existing [ArrayMesh] is passed in as an argument, will add an extra surface to the existing [ArrayMesh].
|
||||
Default flag is [constant Mesh.ARRAY_COMPRESS_DEFAULT]. See [code]ARRAY_COMPRESS_*[/code] constants in [enum Mesh.ArrayFormat] for other flags.
|
||||
[b]FIXME:[/b] Document possible values for [code]flags[/code], it changed in 4.0. Likely some combinations of [enum Mesh.ArrayFormat].
|
||||
</description>
|
||||
</method>
|
||||
<method name="commit_to_arrays">
|
||||
|
@ -229,6 +165,20 @@
|
|||
Generates a tangent vector for each vertex. Requires that each vertex have UVs and normals set already.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_custom_format" qualifiers="const">
|
||||
<return type="int" enum="SurfaceTool.CustomFormat">
|
||||
</return>
|
||||
<argument index="0" name="index" type="int">
|
||||
</argument>
|
||||
<description>
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_skin_weight_count" qualifiers="const">
|
||||
<return type="int" enum="SurfaceTool.SkinWeightCount">
|
||||
</return>
|
||||
<description>
|
||||
</description>
|
||||
</method>
|
||||
<method name="index">
|
||||
<return type="void">
|
||||
</return>
|
||||
|
@ -236,6 +186,45 @@
|
|||
Shrinks the vertex array by creating an index array (avoids reusing vertices).
|
||||
</description>
|
||||
</method>
|
||||
<method name="set_bones">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="bones" type="PackedInt32Array">
|
||||
</argument>
|
||||
<description>
|
||||
Specifies an array of bones for the next vertex to use. [code]bones[/code] must contain 4 integers.
|
||||
</description>
|
||||
</method>
|
||||
<method name="set_color">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="color" type="Color">
|
||||
</argument>
|
||||
<description>
|
||||
Specifies a [Color] for the next vertex to use.
|
||||
[b]Note:[/b] The material must have [member BaseMaterial3D.vertex_color_use_as_albedo] enabled for the vertex color to be visible.
|
||||
</description>
|
||||
</method>
|
||||
<method name="set_custom">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="index" type="int">
|
||||
</argument>
|
||||
<argument index="1" name="custom" type="Color">
|
||||
</argument>
|
||||
<description>
|
||||
</description>
|
||||
</method>
|
||||
<method name="set_custom_format">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="index" type="int">
|
||||
</argument>
|
||||
<argument index="1" name="format" type="int" enum="SurfaceTool.CustomFormat">
|
||||
</argument>
|
||||
<description>
|
||||
</description>
|
||||
</method>
|
||||
<method name="set_material">
|
||||
<return type="void">
|
||||
</return>
|
||||
|
@ -245,7 +234,82 @@
|
|||
Sets [Material] to be used by the [Mesh] you are constructing.
|
||||
</description>
|
||||
</method>
|
||||
<method name="set_normal">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="normal" type="Vector3">
|
||||
</argument>
|
||||
<description>
|
||||
Specifies a normal for the next vertex to use.
|
||||
</description>
|
||||
</method>
|
||||
<method name="set_skin_weight_count">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="count" type="int" enum="SurfaceTool.SkinWeightCount">
|
||||
</argument>
|
||||
<description>
|
||||
</description>
|
||||
</method>
|
||||
<method name="set_tangent">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="tangent" type="Plane">
|
||||
</argument>
|
||||
<description>
|
||||
Specifies a tangent for the next vertex to use.
|
||||
</description>
|
||||
</method>
|
||||
<method name="set_uv">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="uv" type="Vector2">
|
||||
</argument>
|
||||
<description>
|
||||
Specifies a set of UV coordinates to use for the next vertex.
|
||||
</description>
|
||||
</method>
|
||||
<method name="set_uv2">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="uv2" type="Vector2">
|
||||
</argument>
|
||||
<description>
|
||||
Specifies an optional second set of UV coordinates to use for the next vertex.
|
||||
</description>
|
||||
</method>
|
||||
<method name="set_weights">
|
||||
<return type="void">
|
||||
</return>
|
||||
<argument index="0" name="weights" type="PackedFloat32Array">
|
||||
</argument>
|
||||
<description>
|
||||
Specifies weight values for next vertex to use. [code]weights[/code] must contain 4 values.
|
||||
</description>
|
||||
</method>
|
||||
</methods>
|
||||
<constants>
|
||||
<constant name="CUSTOM_RGBA8_UNORM" value="0" enum="CustomFormat">
|
||||
</constant>
|
||||
<constant name="CUSTOM_RGBA8_SNORM" value="1" enum="CustomFormat">
|
||||
</constant>
|
||||
<constant name="CUSTOM_RG_HALF" value="2" enum="CustomFormat">
|
||||
</constant>
|
||||
<constant name="CUSTOM_RGBA_HALF" value="3" enum="CustomFormat">
|
||||
</constant>
|
||||
<constant name="CUSTOM_R_FLOAT" value="4" enum="CustomFormat">
|
||||
</constant>
|
||||
<constant name="CUSTOM_RG_FLOAT" value="5" enum="CustomFormat">
|
||||
</constant>
|
||||
<constant name="CUSTOM_RGB_FLOAT" value="6" enum="CustomFormat">
|
||||
</constant>
|
||||
<constant name="CUSTOM_RGBA_FLOAT" value="7" enum="CustomFormat">
|
||||
</constant>
|
||||
<constant name="CUSTOM_MAX" value="8" enum="CustomFormat">
|
||||
</constant>
|
||||
<constant name="SKIN_4_WEIGHTS" value="0" enum="SkinWeightCount">
|
||||
</constant>
|
||||
<constant name="SKIN_8_WEIGHTS" value="1" enum="SkinWeightCount">
|
||||
</constant>
|
||||
</constants>
|
||||
</class>
|
||||
|
|
|
@ -1160,7 +1160,7 @@
|
|||
<constant name="FEATURE_FONT_SYSTEM" value="32" enum="Feature">
|
||||
TextServer supports loading system fonts.
|
||||
</constant>
|
||||
<constant name="FEATURE_USE_SUPPORT_DATA" value="128" enum="Feature">
|
||||
<constant name="FEATURE_USE_SUPPORT_DATA" value="64" enum="Feature">
|
||||
TextServer require external data file for some features.
|
||||
</constant>
|
||||
</constants>
|
||||
|
|
|
@ -26,7 +26,6 @@
|
|||
<member name="steering" type="float" setter="set_steering" getter="get_steering" default="0.0">
|
||||
The steering angle for the vehicle. Setting this to a non-zero value will result in the vehicle turning when it's moving. Wheels that have [member VehicleWheel3D.use_as_steering] set to [code]true[/code] will automatically be rotated.
|
||||
</member>
|
||||
<member name="weight" type="float" setter="set_weight" getter="get_weight" override="true" default="392.0" />
|
||||
</members>
|
||||
<constants>
|
||||
</constants>
|
||||
|
|
|
@ -234,6 +234,10 @@
|
|||
<member name="screen_space_aa" type="int" setter="set_screen_space_aa" getter="get_screen_space_aa" enum="Viewport.ScreenSpaceAA" default="0">
|
||||
Sets the screen-space antialiasing method used. Screen-space antialiasing works by selectively blurring edges in a post-process shader. It differs from MSAA which takes multiple coverage samples while rendering objects. Screen-space AA methods are typically faster than MSAA and will smooth out specular aliasing, but tend to make scenes appear blurry.
|
||||
</member>
|
||||
<member name="sdf_oversize" type="int" setter="set_sdf_oversize" getter="get_sdf_oversize" enum="Viewport.SDFOversize" default="1">
|
||||
</member>
|
||||
<member name="sdf_scale" type="int" setter="set_sdf_scale" getter="get_sdf_scale" enum="Viewport.SDFScale" default="1">
|
||||
</member>
|
||||
<member name="shadow_atlas_quad_0" type="int" setter="set_shadow_atlas_quadrant_subdiv" getter="get_shadow_atlas_quadrant_subdiv" enum="Viewport.ShadowAtlasQuadrantSubdiv" default="2">
|
||||
The subdivision amount of the first quadrant on the shadow atlas.
|
||||
</member>
|
||||
|
@ -428,5 +432,23 @@
|
|||
<constant name="DEFAULT_CANVAS_ITEM_TEXTURE_REPEAT_MAX" value="3" enum="DefaultCanvasItemTextureRepeat">
|
||||
Max value for [enum DefaultCanvasItemTextureRepeat] enum.
|
||||
</constant>
|
||||
<constant name="SDF_OVERSIZE_100_PERCENT" value="0" enum="SDFOversize">
|
||||
</constant>
|
||||
<constant name="SDF_OVERSIZE_120_PERCENT" value="1" enum="SDFOversize">
|
||||
</constant>
|
||||
<constant name="SDF_OVERSIZE_150_PERCENT" value="2" enum="SDFOversize">
|
||||
</constant>
|
||||
<constant name="SDF_OVERSIZE_200_PERCENT" value="3" enum="SDFOversize">
|
||||
</constant>
|
||||
<constant name="SDF_OVERSIZE_MAX" value="4" enum="SDFOversize">
|
||||
</constant>
|
||||
<constant name="SDF_SCALE_100_PERCENT" value="0" enum="SDFScale">
|
||||
</constant>
|
||||
<constant name="SDF_SCALE_50_PERCENT" value="1" enum="SDFScale">
|
||||
</constant>
|
||||
<constant name="SDF_SCALE_25_PERCENT" value="2" enum="SDFScale">
|
||||
</constant>
|
||||
<constant name="SDF_SCALE_MAX" value="3" enum="SDFScale">
|
||||
</constant>
|
||||
</constants>
|
||||
</class>
|
||||
|
|
|
@ -24,7 +24,7 @@
|
|||
<tutorials>
|
||||
</tutorials>
|
||||
<methods>
|
||||
<method name="get_image">
|
||||
<method name="get_image" qualifiers="const">
|
||||
<return type="Image">
|
||||
</return>
|
||||
<argument index="0" name="width" type="int">
|
||||
|
@ -35,7 +35,7 @@
|
|||
Generate a noise image with the requested [code]width[/code] and [code]height[/code], based on the current noise parameters.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_noise_1d">
|
||||
<method name="get_noise_1d" qualifiers="const">
|
||||
<return type="float">
|
||||
</return>
|
||||
<argument index="0" name="x" type="float">
|
||||
|
@ -45,7 +45,7 @@
|
|||
[b]Note:[/b] This method actually returns the 2D noise value [code][-1,1][/code] with fixed y-coordinate value 0.0.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_noise_2d">
|
||||
<method name="get_noise_2d" qualifiers="const">
|
||||
<return type="float">
|
||||
</return>
|
||||
<argument index="0" name="x" type="float">
|
||||
|
@ -56,7 +56,7 @@
|
|||
Returns the 2D noise value [code][-1,1][/code] at the given position.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_noise_2dv">
|
||||
<method name="get_noise_2dv" qualifiers="const">
|
||||
<return type="float">
|
||||
</return>
|
||||
<argument index="0" name="pos" type="Vector2">
|
||||
|
@ -65,7 +65,7 @@
|
|||
Returns the 2D noise value [code][-1,1][/code] at the given position.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_noise_3d">
|
||||
<method name="get_noise_3d" qualifiers="const">
|
||||
<return type="float">
|
||||
</return>
|
||||
<argument index="0" name="x" type="float">
|
||||
|
@ -78,7 +78,7 @@
|
|||
Returns the 3D noise value [code][-1,1][/code] at the given position.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_noise_3dv">
|
||||
<method name="get_noise_3dv" qualifiers="const">
|
||||
<return type="float">
|
||||
</return>
|
||||
<argument index="0" name="pos" type="Vector3">
|
||||
|
@ -87,7 +87,7 @@
|
|||
Returns the 3D noise value [code][-1,1][/code] at the given position.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_noise_4d">
|
||||
<method name="get_noise_4d" qualifiers="const">
|
||||
<return type="float">
|
||||
</return>
|
||||
<argument index="0" name="x" type="float">
|
||||
|
@ -102,7 +102,7 @@
|
|||
Returns the 4D noise value [code][-1,1][/code] at the given position.
|
||||
</description>
|
||||
</method>
|
||||
<method name="get_seamless_image">
|
||||
<method name="get_seamless_image" qualifiers="const">
|
||||
<return type="Image">
|
||||
</return>
|
||||
<argument index="0" name="size" type="int">
|
||||
|
|
|
@ -2983,7 +2983,6 @@ void Control::_bind_methods() {
|
|||
BIND_VMETHOD(MethodInfo("_structured_text_parser", PropertyInfo(Variant::ARRAY, "args"), PropertyInfo(Variant::STRING, "text")));
|
||||
|
||||
BIND_VMETHOD(MethodInfo("_gui_input", PropertyInfo(Variant::OBJECT, "event", PROPERTY_HINT_RESOURCE_TYPE, "InputEvent")));
|
||||
BIND_VMETHOD(MethodInfo("_unhandled_key_input", PropertyInfo(Variant::OBJECT, "event", PROPERTY_HINT_RESOURCE_TYPE, "InputEvent")));
|
||||
BIND_VMETHOD(MethodInfo(Variant::VECTOR2, "_get_minimum_size"));
|
||||
|
||||
MethodInfo get_drag_data = MethodInfo("get_drag_data", PropertyInfo(Variant::VECTOR2, "position"));
|
||||
|
|
|
@ -581,6 +581,7 @@ Vector<Ref<Shape3D>> Mesh::convex_decompose() const {
|
|||
|
||||
Mesh::Mesh() {
|
||||
}
|
||||
|
||||
#if 0
|
||||
static Vector<uint8_t> _fix_array_compatibility(const Vector<uint8_t> &p_src, uint32_t p_format, uint32_t p_elements) {
|
||||
enum ArrayType {
|
||||
|
@ -732,6 +733,7 @@ static Vector<uint8_t> _fix_array_compatibility(const Vector<uint8_t> &p_src, ui
|
|||
return ret;
|
||||
}
|
||||
#endif
|
||||
|
||||
bool ArrayMesh::_set(const StringName &p_name, const Variant &p_value) {
|
||||
String sname = p_name;
|
||||
|
||||
|
@ -1186,14 +1188,16 @@ void ArrayMesh::add_surface_from_arrays(PrimitiveType p_primitive, const Array &
|
|||
Error err = RS::get_singleton()->mesh_create_surface_data_from_arrays(&surface, (RenderingServer::PrimitiveType)p_primitive, p_arrays, p_blend_shapes, p_lods, p_flags);
|
||||
ERR_FAIL_COND(err != OK);
|
||||
|
||||
/* print_line("format: " + itos(surface.format));
|
||||
/* Debug code.
|
||||
print_line("format: " + itos(surface.format));
|
||||
print_line("aabb: " + surface.aabb);
|
||||
print_line("array size: " + itos(surface.vertex_data.size()));
|
||||
print_line("vertex count: " + itos(surface.vertex_count));
|
||||
print_line("index size: " + itos(surface.index_data.size()));
|
||||
print_line("index count: " + itos(surface.index_count));
|
||||
print_line("primitive: " + itos(surface.primitive));
|
||||
*/
|
||||
*/
|
||||
|
||||
add_surface(surface.format, PrimitiveType(surface.primitive), surface.vertex_data, surface.attribute_data, surface.skin_data, surface.vertex_count, surface.index_data, surface.index_count, surface.aabb, surface.blend_shape_data, surface.blend_shape_count, surface.bone_aabbs, surface.lods);
|
||||
}
|
||||
|
||||
|
@ -1611,63 +1615,6 @@ void ArrayMesh::_bind_methods() {
|
|||
ADD_PROPERTY(PropertyInfo(Variant::ARRAY, "_surfaces", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR | PROPERTY_USAGE_INTERNAL), "_set_surfaces", "_get_surfaces");
|
||||
ADD_PROPERTY(PropertyInfo(Variant::INT, "blend_shape_mode", PROPERTY_HINT_ENUM, "Normalized,Relative"), "set_blend_shape_mode", "get_blend_shape_mode");
|
||||
ADD_PROPERTY(PropertyInfo(Variant::AABB, "custom_aabb", PROPERTY_HINT_NONE, ""), "set_custom_aabb", "get_custom_aabb");
|
||||
|
||||
BIND_CONSTANT(NO_INDEX_ARRAY);
|
||||
BIND_CONSTANT(ARRAY_WEIGHTS_SIZE);
|
||||
|
||||
BIND_ENUM_CONSTANT(ARRAY_VERTEX);
|
||||
BIND_ENUM_CONSTANT(ARRAY_NORMAL);
|
||||
BIND_ENUM_CONSTANT(ARRAY_TANGENT);
|
||||
BIND_ENUM_CONSTANT(ARRAY_COLOR);
|
||||
BIND_ENUM_CONSTANT(ARRAY_TEX_UV);
|
||||
BIND_ENUM_CONSTANT(ARRAY_TEX_UV2);
|
||||
BIND_ENUM_CONSTANT(ARRAY_CUSTOM0);
|
||||
BIND_ENUM_CONSTANT(ARRAY_CUSTOM1);
|
||||
BIND_ENUM_CONSTANT(ARRAY_CUSTOM2);
|
||||
BIND_ENUM_CONSTANT(ARRAY_CUSTOM3);
|
||||
BIND_ENUM_CONSTANT(ARRAY_BONES);
|
||||
BIND_ENUM_CONSTANT(ARRAY_WEIGHTS);
|
||||
BIND_ENUM_CONSTANT(ARRAY_INDEX);
|
||||
BIND_ENUM_CONSTANT(ARRAY_MAX);
|
||||
|
||||
BIND_ENUM_CONSTANT(ARRAY_CUSTOM_RGBA8_UNORM);
|
||||
BIND_ENUM_CONSTANT(ARRAY_CUSTOM_RGBA8_SNORM);
|
||||
BIND_ENUM_CONSTANT(ARRAY_CUSTOM_RG_HALF);
|
||||
BIND_ENUM_CONSTANT(ARRAY_CUSTOM_RGBA_HALF);
|
||||
BIND_ENUM_CONSTANT(ARRAY_CUSTOM_R_FLOAT);
|
||||
BIND_ENUM_CONSTANT(ARRAY_CUSTOM_RG_FLOAT);
|
||||
BIND_ENUM_CONSTANT(ARRAY_CUSTOM_RGB_FLOAT);
|
||||
BIND_ENUM_CONSTANT(ARRAY_CUSTOM_RGBA_FLOAT);
|
||||
BIND_ENUM_CONSTANT(ARRAY_CUSTOM_MAX);
|
||||
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_VERTEX);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_NORMAL);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_TANGENT);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_COLOR);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_TEX_UV);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_TEX_UV2);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM0);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM1);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM2);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM3);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_BONES);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_WEIGHTS);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_INDEX);
|
||||
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_BLEND_SHAPE_MASK);
|
||||
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM_BASE);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM0_SHIFT);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM1_SHIFT);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM2_SHIFT);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM3_SHIFT);
|
||||
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM_MASK);
|
||||
BIND_ENUM_CONSTANT(ARRAY_COMPRESS_FLAGS_BASE);
|
||||
|
||||
BIND_ENUM_CONSTANT(ARRAY_FLAG_USE_2D_VERTICES);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FLAG_USE_DYNAMIC_UPDATE);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FLAG_USE_8_BONE_WEIGHTS);
|
||||
}
|
||||
|
||||
void ArrayMesh::reload_from_file() {
|
||||
|
|
|
@ -1847,6 +1847,10 @@ void RenderingServer::_bind_methods() {
|
|||
BIND_ENUM_CONSTANT(ARRAY_COLOR);
|
||||
BIND_ENUM_CONSTANT(ARRAY_TEX_UV);
|
||||
BIND_ENUM_CONSTANT(ARRAY_TEX_UV2);
|
||||
BIND_ENUM_CONSTANT(ARRAY_CUSTOM0);
|
||||
BIND_ENUM_CONSTANT(ARRAY_CUSTOM1);
|
||||
BIND_ENUM_CONSTANT(ARRAY_CUSTOM2);
|
||||
BIND_ENUM_CONSTANT(ARRAY_CUSTOM3);
|
||||
BIND_ENUM_CONSTANT(ARRAY_BONES);
|
||||
BIND_ENUM_CONSTANT(ARRAY_WEIGHTS);
|
||||
BIND_ENUM_CONSTANT(ARRAY_INDEX);
|
||||
|
@ -1858,12 +1862,28 @@ void RenderingServer::_bind_methods() {
|
|||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_COLOR);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_TEX_UV);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_TEX_UV2);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM0);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM1);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM2);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM3);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_BONES);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_WEIGHTS);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_INDEX);
|
||||
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_BLEND_SHAPE_MASK);
|
||||
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM_BASE);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM0_SHIFT);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM1_SHIFT);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM2_SHIFT);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM3_SHIFT);
|
||||
|
||||
BIND_ENUM_CONSTANT(ARRAY_FORMAT_CUSTOM_MASK);
|
||||
BIND_ENUM_CONSTANT(ARRAY_COMPRESS_FLAGS_BASE);
|
||||
|
||||
BIND_ENUM_CONSTANT(ARRAY_FLAG_USE_2D_VERTICES);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FLAG_USE_DYNAMIC_UPDATE);
|
||||
BIND_ENUM_CONSTANT(ARRAY_FLAG_USE_8_BONE_WEIGHTS);
|
||||
|
||||
BIND_ENUM_CONSTANT(PRIMITIVE_POINTS);
|
||||
BIND_ENUM_CONSTANT(PRIMITIVE_LINES);
|
||||
|
|
Loading…
Reference in a new issue