From 57bd304096e4b4521ee3148bd0b538cbfb5fb616 Mon Sep 17 00:00:00 2001
From: Cory Petkovsek <632766+TokisanGames@users.noreply.github.com>
Date: Sat, 7 Sep 2024 22:36:59 +0700
Subject: [PATCH] Update docs
---
Terrain3D.vcxproj | 7 +-
Terrain3D.vcxproj.filters | 141 ++-
...e_process.txt => _new_release_process.txt} | 0
doc/api/class_terrain3d.rst | 223 +++-
doc/api/class_terrain3dassets.rst | 102 +-
doc/api/class_terrain3ddata.rst | 1057 +++++++++++++++++
doc/api/class_terrain3deditor.rst | 28 +-
doc/api/class_terrain3dinstancer.rst | 108 +-
doc/api/class_terrain3dmaterial.rst | 4 +-
doc/api/class_terrain3dmeshasset.rst | 10 +-
doc/api/class_terrain3dregion.rst | 533 +++++++++
doc/api/class_terrain3dstorage.rst | 757 +-----------
doc/api/class_terrain3dtexture.rst | 4 +-
doc/api/class_terrain3dtextureasset.rst | 4 +-
doc/api/class_terrain3dtexturelist.rst | 4 +-
doc/api/class_terrain3dutil.rst | 130 +-
doc/api/index.rst | 4 +-
doc/build_docs.sh | 4 +-
doc/classes/Terrain3D.xml | 41 +-
doc/classes/Terrain3DAssets.xml | 42 +
doc/classes/Terrain3DData.xml | 490 ++++++++
doc/classes/Terrain3DEditor.xml | 15 +-
doc/classes/Terrain3DInstancer.xml | 53 +-
doc/classes/Terrain3DMeshAsset.xml | 6 +-
doc/classes/Terrain3DRegion.xml | 169 +++
doc/classes/Terrain3DStorage.xml | 361 +-----
doc/classes/Terrain3DUtil.xml | 14 +
.../{storage_format.md => data_format.md} | 7 +-
doc/docs/games.md | 10 +-
doc/docs/images/mesh_lods_flat.jpg | Bin 0 -> 157203 bytes
doc/docs/images/mesh_lods_height.jpg | Bin 0 -> 174832 bytes
doc/docs/installation.md | 23 +-
doc/docs/introduction.md | 64 +
doc/docs/programming_languages.md | 4 +-
doc/docs/project_status.md | 4 +-
doc/docs/troubleshooting.md | 7 +-
doc/docs/tutorial_videos.md | 2 +
doc/index.rst | 5 +-
38 files changed, 3082 insertions(+), 1355 deletions(-)
rename doc/{new_release_process.txt => _new_release_process.txt} (100%)
create mode 100644 doc/api/class_terrain3ddata.rst
create mode 100644 doc/api/class_terrain3dregion.rst
create mode 100644 doc/classes/Terrain3DData.xml
create mode 100644 doc/classes/Terrain3DRegion.xml
rename doc/docs/{storage_format.md => data_format.md} (53%)
create mode 100644 doc/docs/images/mesh_lods_flat.jpg
create mode 100644 doc/docs/images/mesh_lods_height.jpg
create mode 100644 doc/docs/introduction.md
diff --git a/Terrain3D.vcxproj b/Terrain3D.vcxproj
index 6699b89d..da03c654 100644
--- a/Terrain3D.vcxproj
+++ b/Terrain3D.vcxproj
@@ -191,6 +191,7 @@
+
@@ -198,7 +199,7 @@
-
+
@@ -230,7 +231,7 @@
-
+
@@ -238,10 +239,12 @@
+
+
diff --git a/Terrain3D.vcxproj.filters b/Terrain3D.vcxproj.filters
index 95927250..88c479c1 100644
--- a/Terrain3D.vcxproj.filters
+++ b/Terrain3D.vcxproj.filters
@@ -8,110 +8,116 @@
{cddadac5-d2a5-45b0-947d-d3e2b055c87c}
-
- {fa4f3a1c-e2a4-4421-9b19-e15c14fce184}
+
+ {4FC737F1-C7A5-4376-A066-2A32D752A2FF}
+ cpp;c;cc;cxx;c++;cppm;ixx;def;odl;idl;hpj;bat;asm;asmx
-
+
{93995380-89BD-4b04-88EB-625FBE52EBFB}
h;hh;hpp;hxx;h++;hm;inl;inc;ipp;xsd
-
- {4FC737F1-C7A5-4376-A066-2A32D752A2FF}
- cpp;c;cc;cxx;c++;cppm;ixx;def;odl;idl;hpj;bat;asm;asmx
+
+ {fa4f3a1c-e2a4-4421-9b19-e15c14fce184}
-
+
{0d771ba6-8e4a-4985-895c-d9b8eec8b3fd}
- 4. Headers
+ 5. Headers
- 4. Headers
+ 5. Headers
- 4. Headers
+ 5. Headers
- 4. Headers
+ 5. Headers
- 4. Headers
+ 5. Headers
- 4. Headers
+ 5. Headers
- 4. Headers
+ 5. Headers
- 4. Headers
+ 5. Headers
- 4. Headers
+ 5. Headers
- 4. Headers
+ 5. Headers
- 4. Headers
+ 5. Headers
- 4. Headers
+ 5. Headers
- 4. Headers
+ 5. Headers
- 4. Headers
+ 5. Headers
- 4. Headers
+ 5. Headers
- 4. Headers
+ 5. Headers
+
+
+ 5. Headers
- 5. C++
+ 6. C++
- 5. C++
+ 6. C++
- 5. C++
+ 6. C++
- 5. C++
+ 6. C++
- 5. C++
+ 6. C++
- 5. C++
+ 6. C++
- 5. C++
+ 6. C++
- 5. C++
+ 6. C++
- 5. C++
+ 6. C++
- 5. C++
+ 6. C++
- 5. C++
+ 6. C++
- 5. C++
+ 6. C++
- 5. C++
+ 6. C++
+
+
+ 6. C++
@@ -146,13 +152,13 @@
1. Project Files
- 3. Shaders
+ 4. Shaders
- 3. Shaders
+ 4. Shaders
- 3. Shaders
+ 4. Shaders
1. Project Files
@@ -173,16 +179,16 @@
2. Docs
- 3. Shaders
+ 4. Shaders
- 3. Shaders
+ 4. Shaders
- 3. Shaders
+ 4. Shaders
- 3. Shaders
+ 4. Shaders
2. Docs
@@ -208,9 +214,6 @@
2. Docs
-
- 2. Docs
-
2. Docs
@@ -229,7 +232,15 @@
1. Project Files
-
+
+ 2. Docs
+
+
+ 2. Docs
+
+
+ 2. Docs
+
@@ -283,49 +294,55 @@
2. Docs
-
- 2. Docs
-
2. Docs
- 3. Shaders
+ 4. Shaders
+
+
+ 2. Docs
- 2. Docs\XML
+ 3. XML
- 2. Docs\XML
+ 3. XML
- 2. Docs\XML
+ 3. XML
- 2. Docs\XML
+ 3. XML
- 2. Docs\XML
+ 3. XML
- 2. Docs\XML
+ 3. XML
- 2. Docs\XML
+ 3. XML
- 2. Docs\XML
+ 3. XML
- 2. Docs\XML
+ 3. XML
- 2. Docs\XML
+ 3. XML
- 2. Docs\XML
+ 3. XML
+
+
+ 3. XML
+
+
+ 3. XML
\ No newline at end of file
diff --git a/doc/new_release_process.txt b/doc/_new_release_process.txt
similarity index 100%
rename from doc/new_release_process.txt
rename to doc/_new_release_process.txt
diff --git a/doc/api/class_terrain3d.rst b/doc/api/class_terrain3d.rst
index 7fcba481..0f60501e 100644
--- a/doc/api/class_terrain3d.rst
+++ b/doc/api/class_terrain3d.rst
@@ -2,8 +2,8 @@
.. 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/../_plugins/Terrain3D/doc/classes/Terrain3D.xml.
+.. Generator: https://github.com/godotengine/godot/tree/4.3/doc/tools/make_rst.py.
+.. XML source: https://github.com/godotengine/godot/tree/4.3/../_plugins/Terrain3D/doc/classes/Terrain3D.xml.
.. _class_Terrain3D:
@@ -29,45 +29,55 @@ Properties
.. table::
:widths: auto
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`Terrain3DAssets` | :ref:`assets` | |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`bool` | :ref:`collision_enabled` | ``true`` |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`int` | :ref:`collision_layer` | ``1`` |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`int` | :ref:`collision_mask` | ``1`` |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`float` | :ref:`collision_priority` | ``1.0`` |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`int` | :ref:`debug_level` | ``0`` |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`bool` | :ref:`debug_show_collision` | ``false`` |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`Terrain3DInstancer` | :ref:`instancer` | |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`Terrain3DMaterial` | :ref:`material` | |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`int` | :ref:`mesh_lods` | ``7`` |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`int` | :ref:`mesh_size` | ``48`` |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`float` | :ref:`mesh_vertex_spacing` | ``1.0`` |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`ShadowCastingSetting` | :ref:`render_cast_shadows` | ``1`` |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`float` | :ref:`render_cull_margin` | ``0.0`` |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`int` | :ref:`render_layers` | ``2147483649`` |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`int` | :ref:`render_mouse_layer` | ``32`` |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`Terrain3DStorage` | :ref:`storage` | |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`Terrain3DTextureList` | :ref:`texture_list` | |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
- | :ref:`String` | :ref:`version` | ``"0.9.3-dev"`` |
- +---------------------------------------------------------------------------+----------------------------------------------------------------------------+-----------------+
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`Terrain3DAssets` | :ref:`assets` | |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`bool` | :ref:`collision_enabled` | ``true`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`int` | :ref:`collision_layer` | ``1`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`int` | :ref:`collision_mask` | ``1`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`float` | :ref:`collision_priority` | ``1.0`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`Terrain3DData` | :ref:`data` | |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`String` | :ref:`data_directory` | ``""`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`int` | :ref:`debug_level` | ``0`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`bool` | :ref:`debug_show_collision` | ``false`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`bool` | :ref:`debug_show_region_labels` | ``false`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`Terrain3DInstancer` | :ref:`instancer` | |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`Terrain3DMaterial` | :ref:`material` | |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`int` | :ref:`mesh_lods` | ``7`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`int` | :ref:`mesh_size` | ``48`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`float` | :ref:`mesh_vertex_spacing` | ``1.0`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`RegionSize` | :ref:`region_size` | ``1024`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`ShadowCastingSetting` | :ref:`render_cast_shadows` | ``1`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`float` | :ref:`render_cull_margin` | ``0.0`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`int` | :ref:`render_layers` | ``2147483649`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`int` | :ref:`render_mouse_layer` | ``32`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`bool` | :ref:`save_16_bit` | ``false`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`Terrain3DStorage` | :ref:`storage` | |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`Terrain3DTextureList` | :ref:`texture_list` | |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
+ | :ref:`String` | :ref:`version` | ``"0.9.3-dev"`` |
+ +---------------------------------------------------------------------------+------------------------------------------------------------------------------------+-----------------+
.. rst-class:: classref-reftable-group
@@ -78,7 +88,7 @@ Methods
:widths: auto
+-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
- | :ref:`Mesh` | :ref:`bake_mesh`\ (\ lod\: :ref:`int`, filter\: :ref:`HeightFilter`\ ) |const| |
+ | :ref:`Mesh` | :ref:`bake_mesh`\ (\ lod\: :ref:`int`, filter\: :ref:`HeightFilter`\ ) |const| |
+-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`PackedVector3Array` | :ref:`generate_nav_mesh_source_geometry`\ (\ global_aabb\: :ref:`AABB`, require_nav\: :ref:`bool` = true\ ) |const| |
+-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
@@ -98,6 +108,8 @@ Methods
+-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_plugin`\ (\ plugin\: :ref:`EditorPlugin`\ ) |
+-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | |void| | :ref:`split_storage`\ (\ ) |
+ +-----------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
.. rst-class:: classref-section-separator
@@ -128,17 +140,28 @@ Emitted when :ref:`assets` is changed.
Emitted when :ref:`material` is changed.
-.. rst-class:: classref-item-separator
+.. rst-class:: classref-section-separator
----
-.. _class_Terrain3D_signal_storage_changed:
+.. rst-class:: classref-descriptions-group
-.. rst-class:: classref-signal
+Enumerations
+------------
+
+.. _enum_Terrain3D_RegionSize:
+
+.. rst-class:: classref-enumeration
+
+enum **RegionSize**: :ref:`🔗`
+
+.. _class_Terrain3D_constant_SIZE_1024:
+
+.. rst-class:: classref-enumeration-constant
-**storage_changed**\ (\ ) :ref:`🔗`
+:ref:`RegionSize` **SIZE_1024** = ``1024``
-Emitted when :ref:`storage` is changed.
+Region size is 1024 x 1024 vertices and pixels on maps.
.. rst-class:: classref-section-separator
@@ -234,6 +257,39 @@ The priority used to solve collisions. The higher priority, the lower the penetr
----
+.. _class_Terrain3D_property_data:
+
+.. rst-class:: classref-property
+
+:ref:`Terrain3DData` **data** :ref:`🔗`
+
+.. rst-class:: classref-property-setget
+
+- :ref:`Terrain3DData` **get_data**\ (\ )
+
+This class manages loading, saving, adding, and removing of Terrain3DRegions and access to their content.
+
+.. rst-class:: classref-item-separator
+
+----
+
+.. _class_Terrain3D_property_data_directory:
+
+.. rst-class:: classref-property
+
+:ref:`String` **data_directory** = ``""`` :ref:`🔗`
+
+.. rst-class:: classref-property-setget
+
+- |void| **set_data_directory**\ (\ value\: :ref:`String`\ )
+- :ref:`String` **get_data_directory**\ (\ )
+
+The directory where terrain data will be saved to and loaded from.
+
+.. rst-class:: classref-item-separator
+
+----
+
.. _class_Terrain3D_property_debug_level:
.. rst-class:: classref-property
@@ -268,6 +324,23 @@ If collision is enabled, this generates collision in the editor and in game. It
----
+.. _class_Terrain3D_property_debug_show_region_labels:
+
+.. rst-class:: classref-property
+
+:ref:`bool` **debug_show_region_labels** = ``false`` :ref:`🔗`
+
+.. rst-class:: classref-property-setget
+
+- |void| **set_show_region_labels**\ (\ value\: :ref:`bool`\ )
+- :ref:`bool` **get_show_region_labels**\ (\ )
+
+Display an overlay that shows region locations in the viewport.
+
+.. rst-class:: classref-item-separator
+
+----
+
.. _class_Terrain3D_property_instancer:
.. rst-class:: classref-property
@@ -350,7 +423,7 @@ The distance between vertices. Godot units are typically considered to be meters
This variable changes the global position of landscape features. A mountain peak might be at (512, 512), but with a vertex spacing of 2.0 it is now located at (1024, 1024).
-All Terrain3D functions with a global_position expect an absolute global value. If you would normally use :ref:`Terrain3DStorage.import_images` to import an image in the region at (-1024, -1024), with a mesh_vertex_spacing of 2, you'll need to import that image at (-2048, -2048) to place it in the same region.
+All Terrain3D functions with a global_position expect an absolute global value. If you would normally use :ref:`Terrain3DData.import_images` to import an image in the region at (-1024, -1024), with a mesh_vertex_spacing of 2, you'll need to import that image at (-2048, -2048) to place it in the same region.
To scale heights, export the height map and reimport it with a new height scale.
@@ -358,6 +431,23 @@ To scale heights, export the height map and reimport it with a new height scale.
----
+.. _class_Terrain3D_property_region_size:
+
+.. rst-class:: classref-property
+
+:ref:`RegionSize` **region_size** = ``1024`` :ref:`🔗`
+
+.. rst-class:: classref-property-setget
+
+- |void| **set_region_size**\ (\ value\: :ref:`RegionSize`\ )
+- :ref:`RegionSize` **get_region_size**\ (\ )
+
+The number of vertices in each region, and the number of pixels for each map in Terrain3DRegion. 1 pixel corresponds to 1 vertex. :ref:`mesh_vertex_spacing` scales regions, but does not change the number of vertices or pixels.
+
+.. rst-class:: classref-item-separator
+
+----
+
.. _class_Terrain3D_property_render_cast_shadows:
.. rst-class:: classref-property
@@ -386,7 +476,7 @@ Tells the renderer how to cast shadows from the terrain onto other objects. This
- |void| **set_cull_margin**\ (\ value\: :ref:`float`\ )
- :ref:`float` **get_cull_margin**\ (\ )
-This margin is added to the vertical component of the terrain bounding box (AABB). The terrain already sets its AABB from :ref:`Terrain3DStorage.height_range`, which is calculated while sculpting. This setting only needs to be used if the shader has expanded the terrain beyond the AABB and the terrain meshes are being culled at certain viewing angles. This might happen from using :ref:`Terrain3DMaterial.world_background` with NOISE and a height value larger than the terrain heights. This setting is similar to ``GeometryInstance3D.extra_cull_margin``, but it only affects the Y axis.
+This margin is added to the vertical component of the terrain bounding box (AABB). The terrain already sets its AABB from :ref:`Terrain3DData.get_height_range`, which is calculated while sculpting. This setting only needs to be used if the shader has expanded the terrain beyond the AABB and the terrain meshes are being culled at certain viewing angles. This might happen from using :ref:`Terrain3DMaterial.world_background` with NOISE and a height value larger than the terrain heights. This setting is similar to ``GeometryInstance3D.extra_cull_margin``, but it only affects the Y axis.
.. rst-class:: classref-item-separator
@@ -432,6 +522,23 @@ See :ref:`get_intersection`.
----
+.. _class_Terrain3D_property_save_16_bit:
+
+.. rst-class:: classref-property
+
+:ref:`bool` **save_16_bit** = ``false`` :ref:`🔗`
+
+.. rst-class:: classref-property-setget
+
+- |void| **set_save_16_bit**\ (\ value\: :ref:`bool`\ )
+- :ref:`bool` **get_save_16_bit**\ (\ )
+
+Heightmaps are always loaded and edited in 32-bit. This option saves heightmaps as 16-bit half precision to reduce file size. This process is lossy, but does not change what is currently in memory.
+
+.. rst-class:: classref-item-separator
+
+----
+
.. _class_Terrain3D_property_storage:
.. rst-class:: classref-property
@@ -443,7 +550,7 @@ See :ref:`get_intersection`.
- |void| **set_storage**\ (\ value\: :ref:`Terrain3DStorage`\ )
- :ref:`Terrain3DStorage` **get_storage**\ (\ )
-The object that houses all Terrain3D region, height, control, and color maps. Make sure to save this as an external ``.res`` binary file.
+This object is deprecated and only used for upgrading. Don't use.
.. rst-class:: classref-item-separator
@@ -491,13 +598,13 @@ Method Descriptions
.. rst-class:: classref-method
-:ref:`Mesh` **bake_mesh**\ (\ lod\: :ref:`int`, filter\: :ref:`HeightFilter`\ ) |const| :ref:`🔗`
+:ref:`Mesh` **bake_mesh**\ (\ lod\: :ref:`int`, filter\: :ref:`HeightFilter`\ ) |const| :ref:`🔗`
Generates a static ArrayMesh for the terrain.
\ ``lod`` - Determines the granularity of the generated mesh. The range is 0-8. 4 is recommended.
-\ ``filter`` - Controls how vertex Y coordinates are generated from the height map. See :ref:`HeightFilter`.
+\ ``filter`` - Controls how vertex Y coordinates are generated from the height map. See :ref:`HeightFilter`.
.. rst-class:: classref-item-separator
@@ -625,6 +732,18 @@ Sets the current Terrain3DEditor instance.
Sets the EditorPlugin connected to Terrain3D.
+.. rst-class:: classref-item-separator
+
+----
+
+.. _class_Terrain3D_method_split_storage:
+
+.. rst-class:: classref-method
+
+|void| **split_storage**\ (\ ) :ref:`🔗`
+
+This function is deprecated. It facilitates upgrading the previous storage version to the new format.
+
.. |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.)`
diff --git a/doc/api/class_terrain3dassets.rst b/doc/api/class_terrain3dassets.rst
index a2993447..777e7ff9 100644
--- a/doc/api/class_terrain3dassets.rst
+++ b/doc/api/class_terrain3dassets.rst
@@ -2,8 +2,8 @@
.. 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/../_plugins/Terrain3D/doc/classes/Terrain3DAssets.xml.
+.. Generator: https://github.com/godotengine/godot/tree/4.3/doc/tools/make_rst.py.
+.. XML source: https://github.com/godotengine/godot/tree/4.3/../_plugins/Terrain3D/doc/classes/Terrain3DAssets.xml.
.. _class_Terrain3DAssets:
@@ -44,20 +44,34 @@ Methods
+-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`create_mesh_thumbnails`\ (\ id\: :ref:`int` = -1, size\: :ref:`Vector2i` = Vector2i(128, 128)\ ) |
+-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`RID` | :ref:`get_albedo_array_rid`\ (\ ) |const| |
+ +-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Terrain3DMeshAsset` | :ref:`get_mesh_asset`\ (\ id\: :ref:`int`\ ) |const| |
+-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int` | :ref:`get_mesh_count`\ (\ ) |const| |
+-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`RID` | :ref:`get_normal_array_rid`\ (\ ) |const| |
+ +-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Terrain3DTextureAsset` | :ref:`get_texture`\ (\ id\: :ref:`int`\ ) |const| |
+-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`PackedColorArray` | :ref:`get_texture_colors`\ (\ ) |const| |
+ +-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int` | :ref:`get_texture_count`\ (\ ) |const| |
+-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`PackedFloat32Array` | :ref:`get_texture_detiles`\ (\ ) |const| |
+ +-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`PackedFloat32Array` | :ref:`get_texture_uv_scales`\ (\ ) |const| |
+ +-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`save`\ (\ ) |
+-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_mesh_asset`\ (\ id\: :ref:`int`, mesh\: :ref:`Terrain3DMeshAsset`\ ) |
+-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_texture`\ (\ id\: :ref:`int`, texture\: :ref:`Terrain3DTextureAsset`\ ) |
+-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | |void| | :ref:`update_mesh_list`\ (\ ) |
+ +-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | |void| | :ref:`update_texture_list`\ (\ ) |
+ +-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
.. rst-class:: classref-section-separator
@@ -204,6 +218,18 @@ Generates mesh asset preview thumbnails for the asset dock, stored within each m
----
+.. _class_Terrain3DAssets_method_get_albedo_array_rid:
+
+.. rst-class:: classref-method
+
+:ref:`RID` **get_albedo_array_rid**\ (\ ) |const| :ref:`🔗`
+
+Returns the resource ID of the TextureArray generated from combining all albedo and height textures.
+
+.. rst-class:: classref-item-separator
+
+----
+
.. _class_Terrain3DAssets_method_get_mesh_asset:
.. rst-class:: classref-method
@@ -228,6 +254,18 @@ Returns the number of mesh assets in the list.
----
+.. _class_Terrain3DAssets_method_get_normal_array_rid:
+
+.. rst-class:: classref-method
+
+:ref:`RID` **get_normal_array_rid**\ (\ ) |const| :ref:`🔗`
+
+Returns the resource ID of the TextureArray generated from combining all normal and roughness textures.
+
+.. rst-class:: classref-item-separator
+
+----
+
.. _class_Terrain3DAssets_method_get_texture:
.. rst-class:: classref-method
@@ -240,6 +278,18 @@ Returns the Terrain3DTextureAsset with the requested ID.
----
+.. _class_Terrain3DAssets_method_get_texture_colors:
+
+.. rst-class:: classref-method
+
+:ref:`PackedColorArray` **get_texture_colors**\ (\ ) |const| :ref:`🔗`
+
+Returns the array of all albedo colors used in the texture assets, indexed by asset id.
+
+.. rst-class:: classref-item-separator
+
+----
+
.. _class_Terrain3DAssets_method_get_texture_count:
.. rst-class:: classref-method
@@ -252,6 +302,30 @@ Returns the number of texture slots used.
----
+.. _class_Terrain3DAssets_method_get_texture_detiles:
+
+.. rst-class:: classref-method
+
+:ref:`PackedFloat32Array` **get_texture_detiles**\ (\ ) |const| :ref:`🔗`
+
+Returns the array of all detiling values used in the texture assets, indexed by asset id.
+
+.. rst-class:: classref-item-separator
+
+----
+
+.. _class_Terrain3DAssets_method_get_texture_uv_scales:
+
+.. rst-class:: classref-method
+
+:ref:`PackedFloat32Array` **get_texture_uv_scales**\ (\ ) |const| :ref:`🔗`
+
+Returns the array of all uv scale values used in the texture assets, indexed by asset id.
+
+.. rst-class:: classref-item-separator
+
+----
+
.. _class_Terrain3DAssets_method_save:
.. rst-class:: classref-method
@@ -284,6 +358,30 @@ Assigns the Terrain3DMeshAsset to the specified ID slot. It can be null to clear
Adds a Terrain3DTextureAsset at the specified ID slot. The texture can be null to clear the slot, or remove it if its the last in the list. If the specified slot is full, it will be swapped with the source texture ID, or will find the next available ID.
+.. rst-class:: classref-item-separator
+
+----
+
+.. _class_Terrain3DAssets_method_update_mesh_list:
+
+.. rst-class:: classref-method
+
+|void| **update_mesh_list**\ (\ ) :ref:`🔗`
+
+Updates the internal list of meshes used by the instancer.
+
+.. rst-class:: classref-item-separator
+
+----
+
+.. _class_Terrain3DAssets_method_update_texture_list:
+
+.. rst-class:: classref-method
+
+|void| **update_texture_list**\ (\ ) :ref:`🔗`
+
+Regenerates the texture arrays from the list of texture assets, which is sent to the shader.
+
.. |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.)`
diff --git a/doc/api/class_terrain3ddata.rst b/doc/api/class_terrain3ddata.rst
new file mode 100644
index 00000000..00631b10
--- /dev/null
+++ b/doc/api/class_terrain3ddata.rst
@@ -0,0 +1,1057 @@
+:github_url: hide
+
+.. DO NOT EDIT THIS FILE!!!
+.. Generated automatically from Godot engine sources.
+.. Generator: https://github.com/godotengine/godot/tree/4.3/doc/tools/make_rst.py.
+.. XML source: https://github.com/godotengine/godot/tree/4.3/../_plugins/Terrain3D/doc/classes/Terrain3DData.xml.
+
+.. _class_Terrain3DData:
+
+Terrain3DData
+=============
+
+**Inherits:** :ref:`Object`
+
+.. rst-class:: classref-introduction-group
+
+Description
+-----------
+
+Terrain3D divides all data into regions which fit on a grid in the world. These coordinates are called region locations. The map data are stored in instances of :ref:`Terrain3DRegion`, which are saved to individual files. This class manages region loading, unloading, data retreival and manipulation.
+
+.. rst-class:: classref-reftable-group
+
+Properties
+----------
+
+.. table::
+ :widths: auto
+
+ +--------------------------------------------------------------+------------------------------------------------------------------------+--------+
+ | :ref:`Array`\[:ref:`Image`\] | :ref:`color_maps` | ``[]`` |
+ +--------------------------------------------------------------+------------------------------------------------------------------------+--------+
+ | :ref:`Array`\[:ref:`Image`\] | :ref:`control_maps` | ``[]`` |
+ +--------------------------------------------------------------+------------------------------------------------------------------------+--------+
+ | :ref:`Array`\[:ref:`Image`\] | :ref:`height_maps` | ``[]`` |
+ +--------------------------------------------------------------+------------------------------------------------------------------------+--------+
+ | :ref:`Array`\[:ref:`Vector2i`\] | :ref:`region_locations` | ``[]`` |
+ +--------------------------------------------------------------+------------------------------------------------------------------------+--------+
+
+.. rst-class:: classref-reftable-group
+
+Methods
+-------
+
+.. table::
+ :widths: auto
+
+ +----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`Error` | :ref:`add_region`\ (\ region\: :ref:`Terrain3DRegion`, update\: :ref:`bool` = true\ ) |
+ +----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`Terrain3DRegion` | :ref:`add_region_blank`\ (\ region_location\: :ref:`Vector2i`, update\: :ref:`bool` = true\ ) |
+ +----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`Terrain3DRegion` | :ref:`add_region_blankp`\ (\ global_position\: :ref:`Vector3`, update\: :ref:`bool` = true\ ) |
+ +----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | |void| | :ref:`calc_height_range`\ (\ recursive\: :ref:`bool` = false\ ) |
+ +----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`Error` | :ref:`export_image`\ (\ file_name\: :ref:`String`, map_type\: :ref:`MapType`\ ) |const| |
+ +----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | |void| | :ref:`force_update_maps`\ (\ map_type\: :ref:`MapType` = 3, generate_mipmaps\: :ref:`bool` = false\ ) |
+ +----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`float` | :ref:`get_angle`\ (\ global_position\: :ref:`Vector3`\ ) |const| |
+ +----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`Color` | :ref:`get_color`\ (\ global_position\: :ref:`Vector3`\ ) |const| |
+ +----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`RID` | :ref:`get_color_maps_rid`\ (\ ) |const| |
+ +----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`int` | :ref:`get_control`\ (\ global_position\: :ref:`Vector3`\ ) |const| |
+ +----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`RID` | :ref:`get_control_maps_rid`\ (\ ) |const| |
+ +----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`float` | :ref:`get_height`\ (\ global_position\: :ref:`Vector3`\ ) |const| |
+ +----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`RID` | :ref:`get_height_maps_rid`\ (\ ) |const| |
+ +----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`Vector2` | :ref:`get_height_range`\ (\ ) |const| |
+ +----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`Array`\[:ref:`Image`\] | :ref:`get_maps`\ (\ map_type\: :ref:`MapType`\ ) |const| |
+ +----------------------------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
+ | :ref:`Vector3` | :ref:`get_mesh_vertex