123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133 |
- :github_url: hide
- .. DO NOT EDIT THIS FILE!!!
- .. Generated automatically from Godot engine sources.
- .. Generator: https://github.com/godotengine/godot/tree/master/doc/tools/make_rst.py.
- .. XML source: https://github.com/godotengine/godot/tree/master/doc/classes/GDExtension.xml.
- .. _class_GDExtension:
- GDExtension
- ===========
- **Inherits:** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
- A native library for GDExtension.
- .. rst-class:: classref-introduction-group
- Description
- -----------
- The **GDExtension** resource type represents a `shared library <https://en.wikipedia.org/wiki/Shared_library>`__ which can expand the functionality of the engine. The :ref:`GDExtensionManager<class_GDExtensionManager>` singleton is responsible for loading, reloading, and unloading **GDExtension** resources.
- \ **Note:** GDExtension itself is not a scripting language and has no relation to :ref:`GDScript<class_GDScript>` resources.
- .. rst-class:: classref-introduction-group
- Tutorials
- ---------
- - :doc:`GDExtension overview <../tutorials/scripting/gdextension/what_is_gdextension>`
- - :doc:`GDExtension example in C++ <../tutorials/scripting/gdextension/gdextension_cpp_example>`
- .. rst-class:: classref-reftable-group
- Methods
- -------
- .. table::
- :widths: auto
- +------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------+
- | :ref:`InitializationLevel<enum_GDExtension_InitializationLevel>` | :ref:`get_minimum_library_initialization_level<class_GDExtension_method_get_minimum_library_initialization_level>`\ (\ ) |const| |
- +------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------+
- | :ref:`bool<class_bool>` | :ref:`is_library_open<class_GDExtension_method_is_library_open>`\ (\ ) |const| |
- +------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------+
- .. rst-class:: classref-section-separator
- ----
- .. rst-class:: classref-descriptions-group
- Enumerations
- ------------
- .. _enum_GDExtension_InitializationLevel:
- .. rst-class:: classref-enumeration
- enum **InitializationLevel**: :ref:`🔗<enum_GDExtension_InitializationLevel>`
- .. _class_GDExtension_constant_INITIALIZATION_LEVEL_CORE:
- .. rst-class:: classref-enumeration-constant
- :ref:`InitializationLevel<enum_GDExtension_InitializationLevel>` **INITIALIZATION_LEVEL_CORE** = ``0``
- The library is initialized at the same time as the core features of the engine.
- .. _class_GDExtension_constant_INITIALIZATION_LEVEL_SERVERS:
- .. rst-class:: classref-enumeration-constant
- :ref:`InitializationLevel<enum_GDExtension_InitializationLevel>` **INITIALIZATION_LEVEL_SERVERS** = ``1``
- The library is initialized at the same time as the engine's servers (such as :ref:`RenderingServer<class_RenderingServer>` or :ref:`PhysicsServer3D<class_PhysicsServer3D>`).
- .. _class_GDExtension_constant_INITIALIZATION_LEVEL_SCENE:
- .. rst-class:: classref-enumeration-constant
- :ref:`InitializationLevel<enum_GDExtension_InitializationLevel>` **INITIALIZATION_LEVEL_SCENE** = ``2``
- The library is initialized at the same time as the engine's scene-related classes.
- .. _class_GDExtension_constant_INITIALIZATION_LEVEL_EDITOR:
- .. rst-class:: classref-enumeration-constant
- :ref:`InitializationLevel<enum_GDExtension_InitializationLevel>` **INITIALIZATION_LEVEL_EDITOR** = ``3``
- The library is initialized at the same time as the engine's editor classes. Only happens when loading the GDExtension in the editor.
- .. rst-class:: classref-section-separator
- ----
- .. rst-class:: classref-descriptions-group
- Method Descriptions
- -------------------
- .. _class_GDExtension_method_get_minimum_library_initialization_level:
- .. rst-class:: classref-method
- :ref:`InitializationLevel<enum_GDExtension_InitializationLevel>` **get_minimum_library_initialization_level**\ (\ ) |const| :ref:`🔗<class_GDExtension_method_get_minimum_library_initialization_level>`
- Returns the lowest level required for this extension to be properly initialized (see the :ref:`InitializationLevel<enum_GDExtension_InitializationLevel>` enum).
- .. rst-class:: classref-item-separator
- ----
- .. _class_GDExtension_method_is_library_open:
- .. rst-class:: classref-method
- :ref:`bool<class_bool>` **is_library_open**\ (\ ) |const| :ref:`🔗<class_GDExtension_method_is_library_open>`
- Returns ``true`` if this extension's library has been opened.
- .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
- .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
- .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
- .. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)`
- .. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)`
- .. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)`
- .. |bitfield| replace:: :abbr:`BitField (This value is an integer composed as a bitmask of the following flags.)`
- .. |void| replace:: :abbr:`void (No return value.)`
|