Skip to content

Commit

Permalink
Renames from GDNative to GDExtension
Browse files Browse the repository at this point in the history
  • Loading branch information
paddy-exe committed Oct 8, 2022
1 parent 7c7ee2f commit 8f72d0f
Show file tree
Hide file tree
Showing 25 changed files with 147 additions and 180 deletions.
10 changes: 5 additions & 5 deletions _tools/redirects/redirects.csv
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
source,destination
/classes/_classes.html,/classes/
/community/tutorials/3d/mesh_generation_with_heightmap_and_shaders.html,/tutorials/3d/mesh_generation_with_heightmap_and_shaders.html
/community/tutorials/gdnative/gdnative-c-example.html,/tutorials/plugins/gdnative/gdnative-c-example.html
/community/tutorials/gdnative/index.html,/tutorials/plugins/gdnative/index.html
/community/tutorials/gdextension/gdextension-c-example.html,/tutorials/plugins/gdextension/gdextension-c-example.html
/community/tutorials/gdextension/index.html,/tutorials/plugins/gdextension/index.html
/community/tutorials/vr/index.html,/tutorials/vr/index.html
/community/tutorials/vr/vr_primer.html,/tutorials/vr/vr_primer.html
/content/3d/making_trees.html,/tutorials/content/making_trees.html
Expand Down Expand Up @@ -310,9 +310,9 @@ source,destination
/tutorials/platform/android_in_app_purchases.html,/tutorials/platform/android/android_in_app_purchases.html
/tutorials/plugins/android/android_plugin.html,/tutorials/platform/android/android_plugin.html
/tutorials/plugins/android/index.html,/tutorials/platform/android/index.html
/tutorials/plugins/gdnative/gdnative-c-example.html,/tutorials/scripting/gdnative/gdnative_c_example.html
/tutorials/plugins/gdnative/gdnative-cpp-example.html,/tutorials/scripting/gdnative/gdnative_cpp_example.html
/tutorials/plugins/gdnative/index.html,/tutorials/scripting/gdnative/index.html
/tutorials/plugins/gdextension/gdextension-c-example.html,/tutorials/scripting/gdextension/gdextension_c_example.html
/tutorials/plugins/gdextension/gdextension-cpp-example.html,/tutorials/scripting/gdextension/gdextension_cpp_example.html
/tutorials/plugins/gdextension/index.html,/tutorials/scripting/gdextension/index.html
/tutorials/shading/advanced_postprocessing.html,/tutorials/shaders/advanced_postprocessing.html
/tutorials/shading/godot_shader_language_style_guide.html,/tutorials/shaders/shaders_style_guide.html
/tutorials/shading/index.html,/tutorials/shaders/index.html
Expand Down
2 changes: 1 addition & 1 deletion about/docs_changelog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ Scripting
- :ref:`doc_debugger_panel`
- :ref:`doc_creating_script_templates`
- :ref:`doc_evaluating_expressions`
- :ref:`doc_what_is_gdnative`
- :ref:`doc_what_is_gdextension`
- :ref:`doc_gdscript_warning_system` (split from :ref:`doc_gdscript_static_typing`)

VR
Expand Down
7 changes: 3 additions & 4 deletions about/faq.rst
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@ we recommend that you first do some due diligence yourself. Searching through
discussions on `open issues <https://github.com/godotengine/godot/issues>`_ is a
great way to start your troubleshooting.

As for new languages, support is possible via third parties using the GDNative /
As for new languages, support is possible via third parties using the GDExtension /
NativeScript / PluginScript facilities. (See the question about plugins below.)
Work is currently underway, for example, on unofficial bindings for Godot
to `Python <https://github.com/touilleMan/godot-python>`_ and `Nim <https://github.com/pragmagic/godot-nim>`_.
Expand Down Expand Up @@ -368,8 +368,7 @@ and tool scripts.

Also, see the official blog posts on these topics:

* `A look at the GDNative architecture <https://godotengine.org/article/look-gdnative-architecture>`_
* `GDNative is here! <https://godotengine.org/article/dlscript-here>`_
* `Introducing GDNative's successor, GDExtension <https://godotengine.org/article/introducing-gd-extensions>`_

You can also take a look at the GDScript implementation, the Godot modules,
as well as the `unofficial Python support <https://github.com/touilleMan/godot-python>`_ for Godot.
Expand Down Expand Up @@ -547,7 +546,7 @@ The vast majority of games do not need this and Godot provides handy helpers
to do the job for most cases when you do.

If a game that really needs to process such large amount of objects is
needed, our recommendation is to use C++ and GDNative for the high
needed, our recommendation is to use C++ and GDExtension for the high
performance parts and GDScript (or C#) for the rest of the game.

How can I support Godot development or contribute?
Expand Down
2 changes: 1 addition & 1 deletion about/list_of_features.rst
Original file line number Diff line number Diff line change
Expand Up @@ -413,7 +413,7 @@ Scripting
- Supports all platforms.
- Using an external editor is recommended to benefit from IDE functionality.

**GDNative (C, C++, Rust, D, ...):**
**GDExtension (C, C++, Rust, D, ...):**

- When you need it, link to native libraries for higher performance and third-party integrations.

Expand Down
2 changes: 1 addition & 1 deletion community/contributing/bug_triage_guidelines.rst
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ feature request, or one that is not precise enough to be worked on.
- *Core*: anything related to the core engine. It might be further
split later on as it's a pretty big topic.
- *Editor*: relates to issues in the editor (mainly UI).
- *GDNative*: relates to the GDNative module.
- *GDExtension*: relates to the GDExtension module.
- *GDScript*: relates to GDScript.
- *GUI*: relates to GUI (Control) nodes.
- *Import*: relates to the resource import system.
Expand Down
2 changes: 1 addition & 1 deletion community/contributing/cpp_usage_guidelines.rst
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ reasons:

To get your pull request merged, it needs to follow the C++ usage guidelines
outlined here. Of course, you can use features not allowed here in your own C++
modules or GDNative scripts.
modules or GDExtension scripts.

.. note::

Expand Down
2 changes: 1 addition & 1 deletion development/compiling/compiling_for_web.rst
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ And ``webassembly_debug.zip`` for the debug template::

mv bin/godot.javascript.opt.debug.zip bin/webassembly_debug.zip

Threads and GDNative
Threads and GDExtension
--------------------

The default export templates do not include threads and GDNative support for
Expand Down
2 changes: 1 addition & 1 deletion development/cpp/binding_to_external_libraries.rst
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ can link to them instead by adding them as submodules (from within the modules/t
Please note that Git submodules are not used in the Godot repository. If
you are developing a module to be merged into the main Godot repository, you should not
use submodules. If your module doesn't get merged in, you can always try to implement
the external library as a GDNative C++ plugin.
the external library as a GDExtension C++ plugin.

To add include directories for the compiler to look at you can append it to the
environment's paths:
Expand Down
2 changes: 1 addition & 1 deletion development/cpp/custom_modules_in_cpp.rst
Original file line number Diff line number Diff line change
Expand Up @@ -397,7 +397,7 @@ Improving the build system for development

This shared library support is not designed to support distributing a module
to other users without recompiling the engine. For that purpose, use
:ref:`GDNative <doc_what_is_gdnative>` instead.
:ref:`GDExtension <doc_what_is_gdextension>` instead.

So far, we defined a clean SCsub that allows us to add the sources
of our new module as part of the Godot binary.
Expand Down
2 changes: 1 addition & 1 deletion getting_started/first_2d_game/01.project_setup.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ Launch Godot and create a new project.
You need the .NET Core 3.1 SDK, and an editor such as VS Code.
See :ref:`doc_c_sharp_setup`.

.. tab:: GDNative C++
.. tab:: GDExtension C++

Download :download:`dodge_assets_with_gdnative.zip
<files/dodge_assets_with_gdnative.zip>`.
Expand Down
2 changes: 1 addition & 1 deletion getting_started/first_2d_game/06.heads_up_display.rst
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ temporarily, such as "Get Ready".
.. code-tab:: cpp

// This code goes in `hud.cpp`.
// There is no `yield` in GDNative, so we need to have every
// There is no `yield` in GDExtension, so we need to have every
// step be its own method that is called on timer timeout.
void HUD::show_get_ready() {
_message_label->set_text("Get Ready");
Expand Down
2 changes: 1 addition & 1 deletion getting_started/introduction/godot_design_philosophy.rst
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ GDScript lets you write code using an indentation-based syntax,
yet it detects types and offers a static language's quality of auto-completion.
It is also optimized for gameplay code with built-in types like Vectors and Colors.

Note that with GDNative, you can write high-performance code using compiled
Note that with GDExtension, you can write high-performance code using compiled
languages like C, C++, Rust, or Python (using the Cython compiler)
without recompiling the engine.

Expand Down
6 changes: 3 additions & 3 deletions getting_started/introduction/introduction_to_godot.rst
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ Godot-specific and tightly integrated language with a lightweight syntax, or
:ref:`C# <toc-learn-scripting-C#>`, which is popular in the games industry.
These are the two main scripting languages we support.

With the :ref:`GDNative <toc-tutorials-gdnative>` technology, you can also write
With the :ref:`GDExtension <toc-tutorials-gdextension>` technology, you can also write
gameplay or high-performance algorithms in C or C++ without recompiling the
engine. You can use this technology to integrate third-party libraries and other
Software Development Kits (SDK) in the engine.
Expand All @@ -86,8 +86,8 @@ completely free and open-source.

.. seealso:: These are the five officially supported programming languages. The
community maintains support for many more. For more information,
see :ref:`GDNative third-party bindings
<doc_what_is_gdnative_third_party_bindings>`.
see :ref:`GDExtension third-party bindings
<doc_what_is_gdextension_third_party_bindings>`.

.. doc_learning_programming
Expand Down
12 changes: 6 additions & 6 deletions getting_started/step_by_step/scripting_languages.rst
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ Available scripting languages
-----------------------------

Godot offers **four gameplay programming languages**: GDScript, C#,
and, via its GDNative technology, C and C++. There are more
:ref:`community-supported languages <doc_what_is_gdnative_third_party_bindings>`,
and, via its GDExtension technology, C and C++. There are more
:ref:`community-supported languages <doc_what_is_gdextension_third_party_bindings>`,
but these are the official ones.

You can use multiple languages in a single project. For instance, in a team, you
Expand Down Expand Up @@ -125,21 +125,21 @@ or ClojureCLR. However, C# is the only officially supported .NET option.
in GDScript, C#, or C++ won't have a significant impact on
performance.

C and C++ via GDNative
C and C++ via GDExtension
~~~~~~~~~~~~~~~~~~~~~~

GDNative allows you to write game code in C or C++ without needing to recompile
GDExtension allows you to write game code in C or C++ without needing to recompile
or even restart Godot.

.. image:: img/scripting_cpp.png

You can use any version of the language or mix compiler brands and versions for
the generated shared libraries, thanks to our use of an internal C API Bridge.

GDNative is the best choice for performance. You don't need to use it
GDExtension is the best choice for performance. You don't need to use it
throughout an entire game, as you can write other parts in GDScript or C#.

When working with GDNative, the available types, functions, and properties
When working with GDExtension, the available types, functions, and properties
closely resemble Godot's actual C++ API.

Summary
Expand Down
2 changes: 1 addition & 1 deletion tutorials/editor/using_the_web_editor.rst
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ Due to limitations on the Godot or Web platform side, the following features
are currently missing:

- No C#/Mono support.
- No GDNative support.
- No GDExtension support.
- No debugging support. This means GDScript debugging/profiling, live scene
editing, the Remote Scene tree dock and other features that rely on the debugger
protocol will not work.
Expand Down
2 changes: 1 addition & 1 deletion tutorials/export/exporting_for_macos.rst
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ See `Hardened Runtime <https://developer.apple.com/documentation/security/harden
+---------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Allow DYLD Environment Variables [4]_ | Allows app to uss dynamic linker environment variables to inject code. f you are using add-ons with dynamic or self-modifying native code, enable them according to the add-on documentation. |
+---------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Disable Library Validation | Allows app to load arbitrary libraries and frameworks. Enabled it if you are using GDNative add-ons and ad-hoc signature, or want to support user-provided external add-ons. |
| Disable Library Validation | Allows app to load arbitrary libraries and frameworks. Enabled it if you are using GDExtension add-ons and ad-hoc signature, or want to support user-provided external add-ons. |
+---------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| Audio Input | Enable if you need to use the microphone or other audio input sources, if it's enabled you should also provide usage message in the `privacy/microphone_usage_description` option. |
+---------------------------------------+--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
Expand Down
10 changes: 5 additions & 5 deletions tutorials/export/exporting_for_web.rst
Original file line number Diff line number Diff line change
Expand Up @@ -61,12 +61,12 @@ game in the default browser for testing.
You can choose the **Export Type** to select which features will be available:

- *Regular*: is the most compatible across browsers, will not support threads,
nor GDNative.
nor GDExtension.
- *Threads*: will require the browser to support `SharedArrayBuffer
<https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/SharedArrayBuffer>`__.
See `Can I use SharedArrayBuffer <https://caniuse.com/sharedarraybuffer>`__
for details.
- *GDNative*: enables GDNative support but makes the binary bigger and slower
- *GDExtension*: enables GDExtension support but makes the binary bigger and slower
to load.

If you plan to use :ref:`VRAM compression <doc_import_images>` make sure that
Expand Down Expand Up @@ -147,13 +147,13 @@ across browsers is still limited.
Browsers also require that the web page is served with specific
`cross-origin isolation headers <https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Cross-Origin-Embedder-Policy>`__.

GDNative
GDExtension
~~~~~~~~

As mentioned :ref:`above <doc_javascript_export_options>` GDNative is only
As mentioned :ref:`above <doc_javascript_export_options>` GDExtension is only
available if the appropriate **Export Type** is set.

The export will also copy the required GDNative ``.wasm`` files to the output
The export will also copy the required GDExtension ``.wasm`` files to the output
folder (and must be uploaded to your server along with your game).

Full screen and mouse capture
Expand Down
2 changes: 1 addition & 1 deletion tutorials/export/feature_tags.rst
Original file line number Diff line number Diff line change
Expand Up @@ -174,4 +174,4 @@ Customizing the build
---------------------

Feature tags can be used to customize a build process too, by writing a custom **ExportPlugin**.
They are also used to specify which shared library is loaded and exported in **GDNative**.
They are also used to specify which shared library is loaded and exported in **GDExtension**.
2 changes: 1 addition & 1 deletion tutorials/networking/webrtc.rst
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ Using WebRTC in Godot

WebRTC is implemented in Godot via two main classes :ref:`WebRTCPeerConnection <class_WebRTCPeerConnection>` and :ref:`WebRTCDataChannel <class_WebRTCDataChannel>`, plus the multiplayer API implementation :ref:`WebRTCMultiplayer <class_WebRTCMultiplayer>`. See section on :ref:`high-level multiplayer <doc_high_level_multiplayer>` for more details.

.. note:: These classes are available automatically in HTML5, but **require an external GDNative plugin on native (non-HTML5) platforms**. Check out the `webrtc-native plugin repository <https://github.com/godotengine/webrtc-native>`__ for instructions and to get the latest `release <https://github.com/godotengine/webrtc-native/releases>`__.
.. note:: These classes are available automatically in HTML5, but **require an external GDExtension plugin on native (non-HTML5) platforms**. Check out the `webrtc-native plugin repository <https://github.com/godotengine/webrtc-native>`__ for instructions and to get the latest `release <https://github.com/godotengine/webrtc-native/releases>`__.

.. warning::

Expand Down
4 changes: 2 additions & 2 deletions tutorials/performance/cpu_optimization.rst
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ will be able to work as fast as possible.
Godot usually takes care of such low-level details for you. For example, the
Server APIs make sure data is optimized for caching already for things like
rendering and physics. Still, you should be especially aware of caching when
using :ref:`GDNative <toc-tutorials-gdnative>`.
using :ref:`GDExtension <toc-tutorials-gdextension>`.

Languages
=========
Expand Down Expand Up @@ -198,7 +198,7 @@ C++
Godot is written in C++. Using C++ will usually result in the fastest code.
However, on a practical level, it is the most difficult to deploy to end users'
machines on different platforms. Options for using C++ include
:ref:`GDNative <toc-tutorials-gdnative>` and
:ref:`GDExtension <toc-tutorials-gdextension>` and
:ref:`custom modules <doc_custom_modules_in_c++>`.

Threads
Expand Down
2 changes: 1 addition & 1 deletion tutorials/performance/using_multimesh.rst
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ see the :ref:`Animating thousands of fish <doc_animating_thousands_of_fish>` tut
to the shader can be provided via textures (there are floating-point :ref:`Image<class_Image>` formats
which are ideal for this).

Another alternative is to use GDNative and C++, which should be extremely efficient (it's possible
Another alternative is to use GDExtension and C++, which should be extremely efficient (it's possible
to set the entire state for all objects using linear memory via the
:ref:`RenderingServer.multimesh_set_buffer() <class_RenderingServer_method_multimesh_set_buffer>`
function). This way, the array can be created with multiple threads, then set in one call, providing
Expand Down
14 changes: 7 additions & 7 deletions tutorials/platform/android/android_plugin.rst
Original file line number Diff line number Diff line change
Expand Up @@ -133,19 +133,19 @@ From your script::
print(singleton.myPluginFunction("World"))


Bundling GDNative resources
Bundling GDExtension resources
^^^^^^^^^^^^^^^^^^^^^^^^^^^

An Android plugin can define and provide C/C++ GDNative resources, either to provide and/or access functionality from the game logic.
The GDNative resources can be bundled within the plugin ``aar`` file which simplifies the distribution and deployment process:
An Android plugin can define and provide C/C++ GDExtension resources, either to provide and/or access functionality from the game logic.
The GDExtension resources can be bundled within the plugin ``aar`` file which simplifies the distribution and deployment process:

- The shared libraries (``.so``) for the defined GDNative libraries will be automatically bundled by the ``aar`` build system.
- The shared libraries (``.so``) for the defined GDExtension libraries will be automatically bundled by the ``aar`` build system.
- Godot ``*.gdnlib`` and ``*.gdns`` resource files must be manually defined in the plugin ``assets`` directory.
The recommended path for these resources relative to the ``assets`` directory should be: ``godot/plugin/v1/[PluginName]/``.

For GDNative libraries, the plugin singleton object must override the ``org.godotengine.godot.plugin.GodotPlugin::getPluginGDNativeLibrariesPaths()`` method,
and return the paths to the bundled GDNative libraries config files (``*.gdnlib``). The paths must be relative to the ``assets`` directory.
At runtime, the plugin will provide these paths to Godot core which will use them to load and initialize the bundled GDNative libraries.
For GDExtension libraries, the plugin singleton object must override the ``org.godotengine.godot.plugin.GodotPlugin::getPluginGDNativeLibrariesPaths()`` method,
and return the paths to the bundled GDExtension libraries config files (``*.gdextension``). The paths must be relative to the ``assets`` directory.
At runtime, the plugin will provide these paths to Godot core which will use them to load and initialize the bundled GDExtension libraries.

Reference implementations
^^^^^^^^^^^^^^^^^^^^^^^^^
Expand Down
6 changes: 3 additions & 3 deletions tutorials/scripting/gdextension/gdextension_c_example.rst
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
.. _doc_gdnative_c_example:
.. _doc_gdextension_c_example:

GDExtension C example
==================

Introduction
------------

This tutorial introduces the bare minimum required to create GDNative
modules. This should be your starting point into the world of GDNative.
This tutorial introduces the bare minimum required to create GDExtension
modules. This should be your starting point into the world of GDExtension.
Understanding the contents of this tutorial will help you in understanding all
that is to come after this.

Expand Down
Loading

0 comments on commit 8f72d0f

Please sign in to comment.