class_sky.rst 3.9 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697
  1. :github_url: hide
  2. .. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
  3. .. DO NOT EDIT THIS FILE, but the Sky.xml source instead.
  4. .. The source is found in doc/classes or modules/<name>/doc_classes.
  5. .. _class_Sky:
  6. Sky
  7. ===
  8. **Inherits:** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
  9. **Inherited By:** :ref:`PanoramaSky<class_PanoramaSky>`, :ref:`ProceduralSky<class_ProceduralSky>`
  10. The base class for :ref:`PanoramaSky<class_PanoramaSky>` and :ref:`ProceduralSky<class_ProceduralSky>`.
  11. Description
  12. -----------
  13. The base class for :ref:`PanoramaSky<class_PanoramaSky>` and :ref:`ProceduralSky<class_ProceduralSky>`.
  14. Properties
  15. ----------
  16. +--------------------------------------------+--------------------------------------------------------+-------+
  17. | :ref:`RadianceSize<enum_Sky_RadianceSize>` | :ref:`radiance_size<class_Sky_property_radiance_size>` | ``2`` |
  18. +--------------------------------------------+--------------------------------------------------------+-------+
  19. Enumerations
  20. ------------
  21. .. _enum_Sky_RadianceSize:
  22. .. _class_Sky_constant_RADIANCE_SIZE_32:
  23. .. _class_Sky_constant_RADIANCE_SIZE_64:
  24. .. _class_Sky_constant_RADIANCE_SIZE_128:
  25. .. _class_Sky_constant_RADIANCE_SIZE_256:
  26. .. _class_Sky_constant_RADIANCE_SIZE_512:
  27. .. _class_Sky_constant_RADIANCE_SIZE_1024:
  28. .. _class_Sky_constant_RADIANCE_SIZE_2048:
  29. .. _class_Sky_constant_RADIANCE_SIZE_MAX:
  30. enum **RadianceSize**:
  31. - **RADIANCE_SIZE_32** = **0** --- Radiance texture size is 32×32 pixels.
  32. - **RADIANCE_SIZE_64** = **1** --- Radiance texture size is 64×64 pixels.
  33. - **RADIANCE_SIZE_128** = **2** --- Radiance texture size is 128×128 pixels.
  34. - **RADIANCE_SIZE_256** = **3** --- Radiance texture size is 256×256 pixels.
  35. - **RADIANCE_SIZE_512** = **4** --- Radiance texture size is 512×512 pixels.
  36. - **RADIANCE_SIZE_1024** = **5** --- Radiance texture size is 1024×1024 pixels.
  37. **Note:** :ref:`RADIANCE_SIZE_1024<class_Sky_constant_RADIANCE_SIZE_1024>` is not exposed in the inspector as it is known to cause GPU hangs on certain systems.
  38. - **RADIANCE_SIZE_2048** = **6** --- Radiance texture size is 2048×2048 pixels.
  39. **Note:** :ref:`RADIANCE_SIZE_2048<class_Sky_constant_RADIANCE_SIZE_2048>` is not exposed in the inspector as it is known to cause GPU hangs on certain systems.
  40. - **RADIANCE_SIZE_MAX** = **7** --- Represents the size of the :ref:`RadianceSize<enum_Sky_RadianceSize>` enum.
  41. Property Descriptions
  42. ---------------------
  43. .. _class_Sky_property_radiance_size:
  44. - :ref:`RadianceSize<enum_Sky_RadianceSize>` **radiance_size**
  45. +-----------+--------------------------+
  46. | *Default* | ``2`` |
  47. +-----------+--------------------------+
  48. | *Setter* | set_radiance_size(value) |
  49. +-----------+--------------------------+
  50. | *Getter* | get_radiance_size() |
  51. +-----------+--------------------------+
  52. The ``Sky``'s radiance map size. The higher the radiance map size, the more detailed the lighting from the ``Sky`` will be.
  53. See :ref:`RadianceSize<enum_Sky_RadianceSize>` constants for values.
  54. **Note:** You will only benefit from high radiance sizes if you have perfectly sharp reflective surfaces in your project and are not using :ref:`ReflectionProbe<class_ReflectionProbe>`\ s or :ref:`GIProbe<class_GIProbe>`\ s. For most projects, keeping :ref:`radiance_size<class_Sky_property_radiance_size>` to the default value is the best compromise between visuals and performance. Be careful when using high radiance size values as these can cause crashes on low-end GPUs.
  55. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
  56. .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
  57. .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`