mirror of
https://github.com/godotengine/godot-docs-l10n.git
synced 2026-01-05 14:10:19 +03:00
143 lines
4.7 KiB
ReStructuredText
143 lines
4.7 KiB
ReStructuredText
:github_url: hide
|
|
|
|
.. DO NOT EDIT THIS FILE!!!
|
|
.. Generated automatically from Godot engine sources.
|
|
.. Generator: https://github.com/godotengine/godot/tree/4.2/doc/tools/make_rst.py.
|
|
.. XML source: https://github.com/godotengine/godot/tree/4.2/doc/classes/SphereMesh.xml.
|
|
|
|
.. _class_SphereMesh:
|
|
|
|
SphereMesh
|
|
==========
|
|
|
|
**继承:** :ref:`PrimitiveMesh<class_PrimitiveMesh>` **<** :ref:`Mesh<class_Mesh>` **<** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
|
|
|
|
表示球形 :ref:`PrimitiveMesh<class_PrimitiveMesh>` 的类。
|
|
|
|
.. rst-class:: classref-introduction-group
|
|
|
|
描述
|
|
----
|
|
|
|
表示球形 :ref:`PrimitiveMesh<class_PrimitiveMesh>` 的类。
|
|
|
|
.. rst-class:: classref-reftable-group
|
|
|
|
属性
|
|
----
|
|
|
|
.. table::
|
|
:widths: auto
|
|
|
|
+---------------------------+-------------------------------------------------------------------+-----------+
|
|
| :ref:`float<class_float>` | :ref:`height<class_SphereMesh_property_height>` | ``1.0`` |
|
|
+---------------------------+-------------------------------------------------------------------+-----------+
|
|
| :ref:`bool<class_bool>` | :ref:`is_hemisphere<class_SphereMesh_property_is_hemisphere>` | ``false`` |
|
|
+---------------------------+-------------------------------------------------------------------+-----------+
|
|
| :ref:`int<class_int>` | :ref:`radial_segments<class_SphereMesh_property_radial_segments>` | ``64`` |
|
|
+---------------------------+-------------------------------------------------------------------+-----------+
|
|
| :ref:`float<class_float>` | :ref:`radius<class_SphereMesh_property_radius>` | ``0.5`` |
|
|
+---------------------------+-------------------------------------------------------------------+-----------+
|
|
| :ref:`int<class_int>` | :ref:`rings<class_SphereMesh_property_rings>` | ``32`` |
|
|
+---------------------------+-------------------------------------------------------------------+-----------+
|
|
|
|
.. rst-class:: classref-section-separator
|
|
|
|
----
|
|
|
|
.. rst-class:: classref-descriptions-group
|
|
|
|
属性说明
|
|
--------
|
|
|
|
.. _class_SphereMesh_property_height:
|
|
|
|
.. rst-class:: classref-property
|
|
|
|
:ref:`float<class_float>` **height** = ``1.0``
|
|
|
|
.. rst-class:: classref-property-setget
|
|
|
|
- void **set_height** **(** :ref:`float<class_float>` value **)**
|
|
- :ref:`float<class_float>` **get_height** **(** **)**
|
|
|
|
球体的全高。
|
|
|
|
.. rst-class:: classref-item-separator
|
|
|
|
----
|
|
|
|
.. _class_SphereMesh_property_is_hemisphere:
|
|
|
|
.. rst-class:: classref-property
|
|
|
|
:ref:`bool<class_bool>` **is_hemisphere** = ``false``
|
|
|
|
.. rst-class:: classref-property-setget
|
|
|
|
- void **set_is_hemisphere** **(** :ref:`bool<class_bool>` value **)**
|
|
- :ref:`bool<class_bool>` **get_is_hemisphere** **(** **)**
|
|
|
|
如果为 ``true``\ ,则创建一个半球而不是一个完整的球体。
|
|
|
|
\ **注意:**\ 要得到一个规则的半球,球体的高度和半径必须相等。
|
|
|
|
.. rst-class:: classref-item-separator
|
|
|
|
----
|
|
|
|
.. _class_SphereMesh_property_radial_segments:
|
|
|
|
.. rst-class:: classref-property
|
|
|
|
:ref:`int<class_int>` **radial_segments** = ``64``
|
|
|
|
.. rst-class:: classref-property-setget
|
|
|
|
- void **set_radial_segments** **(** :ref:`int<class_int>` value **)**
|
|
- :ref:`int<class_int>` **get_radial_segments** **(** **)**
|
|
|
|
球体上的径向段数。
|
|
|
|
.. rst-class:: classref-item-separator
|
|
|
|
----
|
|
|
|
.. _class_SphereMesh_property_radius:
|
|
|
|
.. rst-class:: classref-property
|
|
|
|
:ref:`float<class_float>` **radius** = ``0.5``
|
|
|
|
.. rst-class:: classref-property-setget
|
|
|
|
- void **set_radius** **(** :ref:`float<class_float>` value **)**
|
|
- :ref:`float<class_float>` **get_radius** **(** **)**
|
|
|
|
球体半径.
|
|
|
|
.. rst-class:: classref-item-separator
|
|
|
|
----
|
|
|
|
.. _class_SphereMesh_property_rings:
|
|
|
|
.. rst-class:: classref-property
|
|
|
|
:ref:`int<class_int>` **rings** = ``32``
|
|
|
|
.. rst-class:: classref-property-setget
|
|
|
|
- void **set_rings** **(** :ref:`int<class_int>` value **)**
|
|
- :ref:`int<class_int>` **get_rings** **(** **)**
|
|
|
|
沿着球体高度的段数。
|
|
|
|
.. |virtual| replace:: :abbr:`virtual (本方法通常需要用户覆盖才能生效。)`
|
|
.. |const| replace:: :abbr:`const (本方法没有副作用。不会修改该实例的任何成员变量。)`
|
|
.. |vararg| replace:: :abbr:`vararg (本方法除了在此处描述的参数外,还能够继续接受任意数量的参数。)`
|
|
.. |constructor| replace:: :abbr:`constructor (本方法用于构造某个类型。)`
|
|
.. |static| replace:: :abbr:`static (调用本方法无需实例,所以可以直接使用类名调用。)`
|
|
.. |operator| replace:: :abbr:`operator (本方法描述的是使用本类型作为左操作数的有效操作符。)`
|
|
.. |bitfield| replace:: :abbr:`BitField (这个值是由下列标志构成的位掩码整数。)`
|