Browse Source

Merge pull request #9719 from Calinou/importing-images-cubemap-templates

Add cubemap template images to Importing images
Max Hilbrunner 1 year ago
parent
commit
7b26368c5c

BIN
tutorials/assets_pipeline/img/cubemap_template_1x6.webp


BIN
tutorials/assets_pipeline/img/cubemap_template_2x3.webp


BIN
tutorials/assets_pipeline/img/cubemap_template_3x2.webp


BIN
tutorials/assets_pipeline/img/cubemap_template_6x1.webp


+ 11 - 2
tutorials/assets_pipeline/importing_images.rst

@@ -97,12 +97,21 @@ It is possible to choose other types of imported resources in the Import dock:
   texture applied onto a 3D surface. Texture3D is similar to a texture array, but
   texture applied onto a 3D surface. Texture3D is similar to a texture array, but
   with interpolation between layers. Texture3D is typically used for
   with interpolation between layers. Texture3D is typically used for
   :ref:`class_FogMaterial` density maps in :ref:`volumetric fog
   :ref:`class_FogMaterial` density maps in :ref:`volumetric fog
-  <doc_volumetric_fog>`, :ref:`class_Environment` 3D LUT color correction and
-  custom shaders.
+  <doc_volumetric_fog>`, :ref:`particle attractor <doc_3d_particles_attractors>`
+  vector fields, :ref:`class_Environment` 3D LUT color correction, and custom shaders.
 - **TextureAtlas:** Import the image as an *atlas* of different textures. Can be
 - **TextureAtlas:** Import the image as an *atlas* of different textures. Can be
   used to reduce memory usage for animated 2D sprites. Only supported in 2D due
   used to reduce memory usage for animated 2D sprites. Only supported in 2D due
   to missing support in built-in 3D shaders.
   to missing support in built-in 3D shaders.
 
 
+For **Cubemap**, the expected image order is X+, X-, Y+, Y-, Z+, Z-
+(in Godot's coordinate system, so Y+ is "up" and Z- is "forward").
+Here are templates you can use for cubemap images (right-click > **Save Link As…**):
+
+- :download:`2×3 cubemap template (default layout option) <img/cubemap_template_2x3.webp>`
+- :download:`3×2 cubemap template <img/cubemap_template_3x2.webp>`
+- :download:`1×6 cubemap template <img/cubemap_template_1x6.webp>`
+- :download:`6×1 cubemap template <img/cubemap_template_6x1.webp>`
+
 Detect 3D
 Detect 3D
 ^^^^^^^^^
 ^^^^^^^^^
 
 

+ 4 - 2
tutorials/shaders/shader_reference/shading_language.rst

@@ -83,6 +83,7 @@ Most GLSL ES 3.0 datatypes are supported:
 | **samplerCube**      | Sampler type for binding Cubemaps, which are read as float.                     |
 | **samplerCube**      | Sampler type for binding Cubemaps, which are read as float.                     |
 +----------------------+---------------------------------------------------------------------------------+
 +----------------------+---------------------------------------------------------------------------------+
 | **samplerCubeArray** | Sampler type for binding Cubemap arrays, which are read as float.               |
 | **samplerCubeArray** | Sampler type for binding Cubemap arrays, which are read as float.               |
+|                      | Only supported in Forward+ and Mobile, not Compatibility.                       |
 +----------------------+---------------------------------------------------------------------------------+
 +----------------------+---------------------------------------------------------------------------------+
 
 
 Comments
 Comments
@@ -927,9 +928,10 @@ table of the corresponding types:
 +----------------------+-------------------------+------------------------------------------------------------+
 +----------------------+-------------------------+------------------------------------------------------------+
 | **usampler3D**       | **Texture3D**           |                                                            |
 | **usampler3D**       | **Texture3D**           |                                                            |
 +----------------------+-------------------------+------------------------------------------------------------+
 +----------------------+-------------------------+------------------------------------------------------------+
-| **samplerCube**      | **Cubemap**             |                                                            |
+| **samplerCube**      | **Cubemap**             | See :ref:`doc_importing_images_changing_import_type` for   |
+|                      |                         | instructions on importing cubemaps for use in Godot.       |
 +----------------------+-------------------------+------------------------------------------------------------+
 +----------------------+-------------------------+------------------------------------------------------------+
-| **samplerCubeArray** | **CubemapArray**        |                                                            |
+| **samplerCubeArray** | **CubemapArray**        | Only supported in Forward+ and Mobile, not Compatibility.  |
 +----------------------+-------------------------+------------------------------------------------------------+
 +----------------------+-------------------------+------------------------------------------------------------+
 
 
 .. note:: Be careful when setting shader uniforms from GDScript, no error will
 .. note:: Be careful when setting shader uniforms from GDScript, no error will