From 13bb7a651befc51252a8f979d66efd616b0918d0 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?R=C3=A9mi=20Verschelde?= Date: Mon, 23 Mar 2020 20:23:01 +0100 Subject: [PATCH] Sync classref with current source --- classes/class_animationnodestatemachine.rst | 8 + classes/class_array.rst | 170 ++++----- classes/class_astar2d.rst | 24 ++ classes/class_dictionary.rst | 4 +- classes/class_directory.rst | 6 +- classes/class_editorinterface.rst | 8 + classes/class_filesystemdock.rst | 96 +++++ classes/class_inputeventmousemotion.rst | 4 +- classes/class_material.rst | 2 +- classes/class_object.rst | 12 +- ...asky.rst => class_panoramaskymaterial.rst} | 24 +- classes/class_physicalskymaterial.rst | 210 +++++++++++ classes/class_proceduralsky.rst | 347 ------------------ classes/class_proceduralskymaterial.rst | 228 ++++++++++++ classes/class_projectsettings.rst | 8 +- classes/class_shader.rst | 4 + classes/class_signal.rst | 4 +- classes/class_sky.rst | 28 +- classes/class_transform.rst | 8 +- classes/class_transform2d.rst | 8 +- classes/class_treeitem.rst | 4 +- classes/class_vboxcontainer.rst | 2 + classes/class_visibilityenabler.rst | 2 + classes/class_visibilityenabler2d.rst | 2 + classes/class_visualserver.rst | 14 +- 25 files changed, 746 insertions(+), 481 deletions(-) create mode 100644 classes/class_filesystemdock.rst rename classes/{class_panoramasky.rst => class_panoramaskymaterial.rst} (54%) create mode 100644 classes/class_physicalskymaterial.rst delete mode 100644 classes/class_proceduralsky.rst create mode 100644 classes/class_proceduralskymaterial.rst diff --git a/classes/class_animationnodestatemachine.rst b/classes/class_animationnodestatemachine.rst index 87489c98e..143b57eea 100644 --- a/classes/class_animationnodestatemachine.rst +++ b/classes/class_animationnodestatemachine.rst @@ -70,6 +70,8 @@ Methods +---------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`rename_node` **(** :ref:`StringName` name, :ref:`StringName` new_name **)** | +---------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`replace_node` **(** :ref:`StringName` name, :ref:`AnimationNode` node **)** | ++---------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`set_end_node` **(** :ref:`StringName` name **)** | +---------------------------------------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`set_graph_offset` **(** :ref:`Vector2` offset **)** | @@ -226,6 +228,12 @@ Renames the given node. ---- +.. _class_AnimationNodeStateMachine_method_replace_node: + +- void **replace_node** **(** :ref:`StringName` name, :ref:`AnimationNode` node **)** + +---- + .. _class_AnimationNodeStateMachine_method_set_end_node: - void **set_end_node** **(** :ref:`StringName` name **)** diff --git a/classes/class_array.rst b/classes/class_array.rst index b144711a4..8b8e4e230 100644 --- a/classes/class_array.rst +++ b/classes/class_array.rst @@ -40,85 +40,85 @@ Arrays are always passed by reference. Methods ------- -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`Array` | :ref:`Array` **(** :ref:`PackedColorArray` from **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`Array` | :ref:`Array` **(** :ref:`PackedVector3Array` from **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`Array` | :ref:`Array` **(** :ref:`PackedVector2Array` from **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`Array` | :ref:`Array` **(** :ref:`PackedStringArray` from **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`Array` | :ref:`Array` **(** :ref:`PackedFloat64Array` from **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`Array` | :ref:`Array` **(** :ref:`PackedFloat32Array` from **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`Array` | :ref:`Array` **(** :ref:`PackedInt64Array` from **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`Array` | :ref:`Array` **(** :ref:`PackedInt32Array` from **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`Array` | :ref:`Array` **(** :ref:`PackedByteArray` from **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`append` **(** :ref:`Variant` value **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`back` **(** **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`int` | :ref:`bsearch` **(** :ref:`Variant` value, :ref:`bool` before=true **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`int` | :ref:`bsearch_custom` **(** :ref:`Variant` value, :ref:`Object` obj, :ref:`String` func, :ref:`bool` before=true **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`clear` **(** **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`int` | :ref:`count` **(** :ref:`Variant` value **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`Array` | :ref:`duplicate` **(** :ref:`bool` deep=false **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`bool` | :ref:`empty` **(** **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`erase` **(** :ref:`Variant` value **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`int` | :ref:`find` **(** :ref:`Variant` what, :ref:`int` from=0 **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`int` | :ref:`find_last` **(** :ref:`Variant` value **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`front` **(** **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`bool` | :ref:`has` **(** :ref:`Variant` value **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`int` | :ref:`hash` **(** **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`insert` **(** :ref:`int` position, :ref:`Variant` value **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`invert` **(** **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`max` **(** **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`min` **(** **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`pop_back` **(** **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`pop_front` **(** **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`push_back` **(** :ref:`Variant` value **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`push_front` **(** :ref:`Variant` value **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`remove` **(** :ref:`int` position **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`resize` **(** :ref:`int` size **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`int` | :ref:`rfind` **(** :ref:`Variant` what, :ref:`int` from=-1 **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`shuffle` **(** **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`int` | :ref:`size` **(** **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`Array` | :ref:`slice` **(** :ref:`int` begin, :ref:`int` end, :ref:`int` step=1, :ref:`bool` deep=false **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`sort` **(** **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`sort_custom` **(** :ref:`Object` obj, :ref:`String` func **)** | -+---------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Array` | :ref:`Array` **(** :ref:`PackedColorArray` from **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Array` | :ref:`Array` **(** :ref:`PackedVector3Array` from **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Array` | :ref:`Array` **(** :ref:`PackedVector2Array` from **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Array` | :ref:`Array` **(** :ref:`PackedStringArray` from **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Array` | :ref:`Array` **(** :ref:`PackedFloat64Array` from **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Array` | :ref:`Array` **(** :ref:`PackedFloat32Array` from **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Array` | :ref:`Array` **(** :ref:`PackedInt64Array` from **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Array` | :ref:`Array` **(** :ref:`PackedInt32Array` from **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Array` | :ref:`Array` **(** :ref:`PackedByteArray` from **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`append` **(** :ref:`Variant` value **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Variant` | :ref:`back` **(** **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`int` | :ref:`bsearch` **(** :ref:`Variant` value, :ref:`bool` before=true **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`int` | :ref:`bsearch_custom` **(** :ref:`Variant` value, :ref:`Object` obj, :ref:`String` func, :ref:`bool` before=true **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`clear` **(** **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`int` | :ref:`count` **(** :ref:`Variant` value **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Array` | :ref:`duplicate` **(** :ref:`bool` deep=false **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`bool` | :ref:`empty` **(** **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`erase` **(** :ref:`Variant` value **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`int` | :ref:`find` **(** :ref:`Variant` what, :ref:`int` from=0 **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`int` | :ref:`find_last` **(** :ref:`Variant` value **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Variant` | :ref:`front` **(** **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`bool` | :ref:`has` **(** :ref:`Variant` value **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`int` | :ref:`hash` **(** **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`insert` **(** :ref:`int` position, :ref:`Variant` value **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`invert` **(** **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Variant` | :ref:`max` **(** **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Variant` | :ref:`min` **(** **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Variant` | :ref:`pop_back` **(** **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Variant` | :ref:`pop_front` **(** **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`push_back` **(** :ref:`Variant` value **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`push_front` **(** :ref:`Variant` value **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`remove` **(** :ref:`int` position **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`resize` **(** :ref:`int` size **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`int` | :ref:`rfind` **(** :ref:`Variant` what, :ref:`int` from=-1 **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`shuffle` **(** **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`int` | :ref:`size` **(** **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Array` | :ref:`slice` **(** :ref:`int` begin, :ref:`int` end, :ref:`int` step=1, :ref:`bool` deep=false **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`sort` **(** **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`sort_custom` **(** :ref:`Object` obj, :ref:`String` func **)** | ++-------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ Method Descriptions ------------------- @@ -189,7 +189,7 @@ Appends an element at the end of the array (alias of :ref:`push_back` **back** **(** **)** Returns the last element of the array, or ``null`` if the array is empty. @@ -275,7 +275,7 @@ Searches the array in reverse order for a value and returns its index or -1 if n .. _class_Array_method_front: -- void **front** **(** **)** +- :ref:`Variant` **front** **(** **)** Returns the first element of the array, or ``null`` if the array is empty. @@ -322,7 +322,7 @@ Reverses the order of the elements in the array. .. _class_Array_method_max: -- void **max** **(** **)** +- :ref:`Variant` **max** **(** **)** Returns the maximum value contained in the array if all elements are of comparable types. If the elements can't be compared, ``null`` is returned. @@ -330,7 +330,7 @@ Returns the maximum value contained in the array if all elements are of comparab .. _class_Array_method_min: -- void **min** **(** **)** +- :ref:`Variant` **min** **(** **)** Returns the minimum value contained in the array if all elements are of comparable types. If the elements can't be compared, ``null`` is returned. @@ -338,7 +338,7 @@ Returns the minimum value contained in the array if all elements are of comparab .. _class_Array_method_pop_back: -- void **pop_back** **(** **)** +- :ref:`Variant` **pop_back** **(** **)** Removes and returns the last element of the array. Returns ``null`` if the array is empty. @@ -346,7 +346,7 @@ Removes and returns the last element of the array. Returns ``null`` if the array .. _class_Array_method_pop_front: -- void **pop_front** **(** **)** +- :ref:`Variant` **pop_front** **(** **)** Removes and returns the first element of the array. Returns ``null`` if the array is empty. diff --git a/classes/class_astar2d.rst b/classes/class_astar2d.rst index 8d6c911c5..7f5d0aa0e 100644 --- a/classes/class_astar2d.rst +++ b/classes/class_astar2d.rst @@ -21,6 +21,10 @@ This is a wrapper for the :ref:`AStar` class which uses 2D vectors Methods ------- ++-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`float` | :ref:`_compute_cost` **(** :ref:`int` from_id, :ref:`int` to_id **)** virtual | ++-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`float` | :ref:`_estimate_cost` **(** :ref:`int` from_id, :ref:`int` to_id **)** virtual | +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`add_point` **(** :ref:`int` id, :ref:`Vector2` position, :ref:`float` weight_scale=1.0 **)** | +-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -72,6 +76,26 @@ Methods Method Descriptions ------------------- +.. _class_AStar2D_method__compute_cost: + +- :ref:`float` **_compute_cost** **(** :ref:`int` from_id, :ref:`int` to_id **)** virtual + +Called when computing the cost between two connected points. + +Note that this function is hidden in the default ``AStar2D`` class. + +---- + +.. _class_AStar2D_method__estimate_cost: + +- :ref:`float` **_estimate_cost** **(** :ref:`int` from_id, :ref:`int` to_id **)** virtual + +Called when estimating the cost between a point and the path's ending point. + +Note that this function is hidden in the default ``AStar2D`` class. + +---- + .. _class_AStar2D_method_add_point: - void **add_point** **(** :ref:`int` id, :ref:`Vector2` position, :ref:`float` weight_scale=1.0 **)** diff --git a/classes/class_dictionary.rst b/classes/class_dictionary.rst index f8f084c7c..a4dceef47 100644 --- a/classes/class_dictionary.rst +++ b/classes/class_dictionary.rst @@ -104,7 +104,7 @@ Methods +-------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`erase` **(** :ref:`Variant` key **)** | +-------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`get` **(** :ref:`Variant` key, :ref:`Variant` default=null **)** | +| :ref:`Variant` | :ref:`get` **(** :ref:`Variant` key, :ref:`Variant` default=null **)** | +-------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`has` **(** :ref:`Variant` key **)** | +-------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------+ @@ -156,7 +156,7 @@ Erase a dictionary key/value pair by key. Returns ``true`` if the given key was .. _class_Dictionary_method_get: -- void **get** **(** :ref:`Variant` key, :ref:`Variant` default=null **)** +- :ref:`Variant` **get** **(** :ref:`Variant` key, :ref:`Variant` default=null **)** Returns the current value for the specified key in the ``Dictionary``. If the key does not exist, the method returns the value of the optional default argument, or ``null`` if it is omitted. diff --git a/classes/class_directory.rst b/classes/class_directory.rst index e7be3a88b..67a0cd760 100644 --- a/classes/class_directory.rst +++ b/classes/class_directory.rst @@ -57,7 +57,7 @@ Methods +---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`file_exists` **(** :ref:`String` path **)** | +---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| :ref:`String` | :ref:`get_current_dir` **(** :ref:`bool` include_drive=true **)** | +| :ref:`String` | :ref:`get_current_dir` **(** **)** | +---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`int` | :ref:`get_current_drive` **(** **)** | +---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -133,12 +133,10 @@ Returns whether the target file exists. The argument can be relative to the curr .. _class_Directory_method_get_current_dir: -- :ref:`String` **get_current_dir** **(** :ref:`bool` include_drive=true **)** +- :ref:`String` **get_current_dir** **(** **)** Returns the absolute path to the currently opened directory (e.g. ``res://folder`` or ``C:\tmp\folder``). -On Windows, if ``include_drive`` is ``false``, the leading drive specificator is omitted from the returned value (e.g. ``\tmp\folder``). - ---- .. _class_Directory_method_get_current_drive: diff --git a/classes/class_editorinterface.rst b/classes/class_editorinterface.rst index 4f4c28494..f419ffb92 100644 --- a/classes/class_editorinterface.rst +++ b/classes/class_editorinterface.rst @@ -34,6 +34,8 @@ Methods +-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Control` | :ref:`get_editor_viewport` **(** **)** | +-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`FileSystemDock` | :ref:`get_file_system_dock` **(** **)** | ++-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`EditorInspector` | :ref:`get_inspector` **(** **)** const | +-----------------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Array` | :ref:`get_open_scenes` **(** **)** const | @@ -120,6 +122,12 @@ Returns the editor :ref:`Viewport`. ---- +.. _class_EditorInterface_method_get_file_system_dock: + +- :ref:`FileSystemDock` **get_file_system_dock** **(** **)** + +---- + .. _class_EditorInterface_method_get_inspector: - :ref:`EditorInspector` **get_inspector** **(** **)** const diff --git a/classes/class_filesystemdock.rst b/classes/class_filesystemdock.rst new file mode 100644 index 000000000..824bdc78e --- /dev/null +++ b/classes/class_filesystemdock.rst @@ -0,0 +1,96 @@ +:github_url: hide + +.. Generated automatically by doc/tools/makerst.py in Godot's source tree. +.. DO NOT EDIT THIS FILE, but the FileSystemDock.xml source instead. +.. The source is found in doc/classes or modules//doc_classes. + +.. _class_FileSystemDock: + +FileSystemDock +============== + +**Inherits:** :ref:`VBoxContainer` **<** :ref:`BoxContainer` **<** :ref:`Container` **<** :ref:`Control` **<** :ref:`CanvasItem` **<** :ref:`Node` **<** :ref:`Object` + + + +Methods +------- + ++-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`bool` | :ref:`can_drop_data_fw` **(** :ref:`Vector2` arg0, :ref:`Variant` arg1, :ref:`Control` arg2 **)** const | ++-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`drop_data_fw` **(** :ref:`Vector2` arg0, :ref:`Variant` arg1, :ref:`Control` arg2 **)** | ++-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`Variant` | :ref:`get_drag_data_fw` **(** :ref:`Vector2` arg0, :ref:`Control` arg1 **)** | ++-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| void | :ref:`navigate_to_path` **(** :ref:`String` arg0 **)** | ++-------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + +Signals +------- + +.. _class_FileSystemDock_signal_display_mode_changed: + +- **display_mode_changed** **(** **)** + +---- + +.. _class_FileSystemDock_signal_file_removed: + +- **file_removed** **(** :ref:`String` file **)** + +---- + +.. _class_FileSystemDock_signal_files_moved: + +- **files_moved** **(** :ref:`String` old_file, :ref:`String` new_file **)** + +---- + +.. _class_FileSystemDock_signal_folder_moved: + +- **folder_moved** **(** :ref:`String` old_folder, :ref:`String` new_file **)** + +---- + +.. _class_FileSystemDock_signal_folder_removed: + +- **folder_removed** **(** :ref:`String` folder **)** + +---- + +.. _class_FileSystemDock_signal_inherit: + +- **inherit** **(** :ref:`String` file **)** + +---- + +.. _class_FileSystemDock_signal_instance: + +- **instance** **(** :ref:`PackedStringArray` files **)** + +Method Descriptions +------------------- + +.. _class_FileSystemDock_method_can_drop_data_fw: + +- :ref:`bool` **can_drop_data_fw** **(** :ref:`Vector2` arg0, :ref:`Variant` arg1, :ref:`Control` arg2 **)** const + +---- + +.. _class_FileSystemDock_method_drop_data_fw: + +- void **drop_data_fw** **(** :ref:`Vector2` arg0, :ref:`Variant` arg1, :ref:`Control` arg2 **)** + +---- + +.. _class_FileSystemDock_method_get_drag_data_fw: + +- :ref:`Variant` **get_drag_data_fw** **(** :ref:`Vector2` arg0, :ref:`Control` arg1 **)** + +---- + +.. _class_FileSystemDock_method_navigate_to_path: + +- void **navigate_to_path** **(** :ref:`String` arg0 **)** + diff --git a/classes/class_inputeventmousemotion.rst b/classes/class_inputeventmousemotion.rst index b2d9b9968..ced1313ab 100644 --- a/classes/class_inputeventmousemotion.rst +++ b/classes/class_inputeventmousemotion.rst @@ -67,7 +67,9 @@ Represents the pressure the user puts on the pen. Ranges from ``0.0`` to ``1.0`` | *Getter* | get_relative() | +-----------+---------------------+ -The mouse position relative to the previous position (position at the last frame). +The mouse position relative to the previous position (position at the last frame). + +**Note:** Since ``InputEventMouseMotion`` is only emitted when the mouse moves, the last event won't have a relative position of ``Vector2(0, 0)`` when the user stops moving the mouse. ---- diff --git a/classes/class_material.rst b/classes/class_material.rst index 3058693fe..67623e309 100644 --- a/classes/class_material.rst +++ b/classes/class_material.rst @@ -11,7 +11,7 @@ Material **Inherits:** :ref:`Resource` **<** :ref:`Reference` **<** :ref:`Object` -**Inherited By:** :ref:`BaseMaterial3D`, :ref:`CanvasItemMaterial`, :ref:`ParticlesMaterial`, :ref:`ShaderMaterial` +**Inherited By:** :ref:`BaseMaterial3D`, :ref:`CanvasItemMaterial`, :ref:`PanoramaSkyMaterial`, :ref:`ParticlesMaterial`, :ref:`PhysicalSkyMaterial`, :ref:`ProceduralSkyMaterial`, :ref:`ShaderMaterial` Abstract base :ref:`Resource` for coloring and shading geometry. diff --git a/classes/class_object.rst b/classes/class_object.rst index 530074590..3682122e5 100644 --- a/classes/class_object.rst +++ b/classes/class_object.rst @@ -98,6 +98,8 @@ Methods +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`has_method` **(** :ref:`StringName` method **)** const | +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ +| :ref:`bool` | :ref:`has_signal` **(** :ref:`StringName` signal **)** const | ++---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`has_user_signal` **(** :ref:`StringName` signal **)** const | +---------------------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`is_blocking_signals` **(** **)** const | @@ -477,11 +479,19 @@ Returns ``true`` if the object contains the given ``method``. ---- +.. _class_Object_method_has_signal: + +- :ref:`bool` **has_signal** **(** :ref:`StringName` signal **)** const + +Returns ``true`` if the given ``signal`` exists. + +---- + .. _class_Object_method_has_user_signal: - :ref:`bool` **has_user_signal** **(** :ref:`StringName` signal **)** const -Returns ``true`` if the given user-defined ``signal`` exists. +Returns ``true`` if the given user-defined ``signal`` exists. Only signals added using :ref:`add_user_signal` are taken into account. ---- diff --git a/classes/class_panoramasky.rst b/classes/class_panoramaskymaterial.rst similarity index 54% rename from classes/class_panoramasky.rst rename to classes/class_panoramaskymaterial.rst index 7892ad069..c7a172d6a 100644 --- a/classes/class_panoramasky.rst +++ b/classes/class_panoramaskymaterial.rst @@ -1,22 +1,22 @@ :github_url: hide .. Generated automatically by doc/tools/makerst.py in Godot's source tree. -.. DO NOT EDIT THIS FILE, but the PanoramaSky.xml source instead. +.. DO NOT EDIT THIS FILE, but the PanoramaSkyMaterial.xml source instead. .. The source is found in doc/classes or modules//doc_classes. -.. _class_PanoramaSky: +.. _class_PanoramaSkyMaterial: -PanoramaSky -=========== +PanoramaSkyMaterial +=================== -**Inherits:** :ref:`Sky` **<** :ref:`Resource` **<** :ref:`Reference` **<** :ref:`Object` +**Inherits:** :ref:`Material` **<** :ref:`Resource` **<** :ref:`Reference` **<** :ref:`Object` -A type of :ref:`Sky` used to draw a background texture. +A :ref:`Material` used with :ref:`Sky` to draw a background texture. Description ----------- -A resource referenced in an :ref:`Environment` that is used to draw a background. The Panorama sky functions similar to skyboxes in other engines, except it uses an equirectangular sky map instead of a cube map. +A resource referenced in a :ref:`Sky` that is used to draw a background. The Panorama sky material functions similar to skyboxes in other engines, except it uses an equirectangular sky map instead of a cube map. Using an HDR panorama is strongly recommended for accurate, high-quality reflections. Godot supports the Radiance HDR (``.hdr``) and OpenEXR (``.exr``) image formats for this purpose. @@ -25,14 +25,14 @@ You can use `this tool ` | :ref:`panorama` | -+-----------------------------------+------------------------------------------------------+ ++-----------------------------------+--------------------------------------------------------------+ +| :ref:`Texture2D` | :ref:`panorama` | ++-----------------------------------+--------------------------------------------------------------+ Property Descriptions --------------------- -.. _class_PanoramaSky_property_panorama: +.. _class_PanoramaSkyMaterial_property_panorama: - :ref:`Texture2D` **panorama** @@ -42,5 +42,5 @@ Property Descriptions | *Getter* | get_panorama() | +----------+---------------------+ -:ref:`Texture2D` to be applied to the PanoramaSky. +:ref:`Texture2D` to be applied to the ``PanoramaSkyMaterial``. diff --git a/classes/class_physicalskymaterial.rst b/classes/class_physicalskymaterial.rst new file mode 100644 index 000000000..246595f9a --- /dev/null +++ b/classes/class_physicalskymaterial.rst @@ -0,0 +1,210 @@ +:github_url: hide + +.. Generated automatically by doc/tools/makerst.py in Godot's source tree. +.. DO NOT EDIT THIS FILE, but the PhysicalSkyMaterial.xml source instead. +.. The source is found in doc/classes or modules//doc_classes. + +.. _class_PhysicalSkyMaterial: + +PhysicalSkyMaterial +=================== + +**Inherits:** :ref:`Material` **<** :ref:`Resource` **<** :ref:`Reference` **<** :ref:`Object` + +:ref:`Sky` :ref:`Material` used for a physically based sky. + +Description +----------- + +The ``PhysicalSkyMaterial`` uses the Preetham analytic daylight model to draw a sky based on physical properties. This results in a substantially more realistic sky than the :ref:`ProceduralSkyMaterial`, but it is slightly slower and less flexible. + +The ``PhysicalSkyMaterial`` only supports one sun. The color, energy, and direction of the sun are taken from the first :ref:`DirectionalLight` in the scene tree. + +As it is based on a daylight model, the sky fades to black as the sunset ends. If you want a full day/night cycle, you will have to add a night sky by converting this to a :ref:`ShaderMaterial` and adding a night sky directly into the resulting shader. + +Properties +---------- + ++---------------------------+--------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`float` | :ref:`dither_strength` | ``1.0`` | ++---------------------------+--------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`float` | :ref:`exposure` | ``0.1`` | ++---------------------------+--------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`Color` | :ref:`ground_color` | ``Color( 1, 1, 1, 1 )`` | ++---------------------------+--------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`float` | :ref:`mie_coefficient` | ``0.005`` | ++---------------------------+--------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`Color` | :ref:`mie_color` | ``Color( 0.36, 0.56, 0.82, 1 )`` | ++---------------------------+--------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`float` | :ref:`mie_eccentricity` | ``0.8`` | ++---------------------------+--------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`float` | :ref:`rayleigh_coefficient` | ``2.0`` | ++---------------------------+--------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`Color` | :ref:`rayleigh_color` | ``Color( 0.056, 0.14, 0.3, 1 )`` | ++---------------------------+--------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`float` | :ref:`sun_disk_scale` | ``1.0`` | ++---------------------------+--------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`float` | :ref:`turbidity` | ``10.0`` | ++---------------------------+--------------------------------------------------------------------------------------+----------------------------------+ + +Property Descriptions +--------------------- + +.. _class_PhysicalSkyMaterial_property_dither_strength: + +- :ref:`float` **dither_strength** + ++-----------+----------------------------+ +| *Default* | ``1.0`` | ++-----------+----------------------------+ +| *Setter* | set_dither_strength(value) | ++-----------+----------------------------+ +| *Getter* | get_dither_strength() | ++-----------+----------------------------+ + +Sets the amount of dithering to use. Dithering helps reduce banding that appears from the smooth changes in color in the sky. Use the lowest value possible, higher amounts may add fuzziness to the sky. + +---- + +.. _class_PhysicalSkyMaterial_property_exposure: + +- :ref:`float` **exposure** + ++-----------+---------------------+ +| *Default* | ``0.1`` | ++-----------+---------------------+ +| *Setter* | set_exposure(value) | ++-----------+---------------------+ +| *Getter* | get_exposure() | ++-----------+---------------------+ + +Sets the exposure of the sky. Higher exposure values make the entire sky brighter. + +---- + +.. _class_PhysicalSkyMaterial_property_ground_color: + +- :ref:`Color` **ground_color** + ++-----------+-------------------------+ +| *Default* | ``Color( 1, 1, 1, 1 )`` | ++-----------+-------------------------+ +| *Setter* | set_ground_color(value) | ++-----------+-------------------------+ +| *Getter* | get_ground_color() | ++-----------+-------------------------+ + +Modulates the :ref:`Color` on the bottom half of the sky to represent the ground. + +---- + +.. _class_PhysicalSkyMaterial_property_mie_coefficient: + +- :ref:`float` **mie_coefficient** + ++-----------+----------------------------+ +| *Default* | ``0.005`` | ++-----------+----------------------------+ +| *Setter* | set_mie_coefficient(value) | ++-----------+----------------------------+ +| *Getter* | get_mie_coefficient() | ++-----------+----------------------------+ + +Controls the strength of mie scattering for the sky. Mie scattering results from light colliding with larger particles (like water). On earth, mie scattering results in a whiteish color around the sun and horizon. + +---- + +.. _class_PhysicalSkyMaterial_property_mie_color: + +- :ref:`Color` **mie_color** + ++-----------+----------------------------------+ +| *Default* | ``Color( 0.36, 0.56, 0.82, 1 )`` | ++-----------+----------------------------------+ +| *Setter* | set_mie_color(value) | ++-----------+----------------------------------+ +| *Getter* | get_mie_color() | ++-----------+----------------------------------+ + +Controls the :ref:`Color` of the mie scattering effect. While not physically accurate, this allows for the creation of alien looking planets. + +---- + +.. _class_PhysicalSkyMaterial_property_mie_eccentricity: + +- :ref:`float` **mie_eccentricity** + ++-----------+-----------------------------+ +| *Default* | ``0.8`` | ++-----------+-----------------------------+ +| *Setter* | set_mie_eccentricity(value) | ++-----------+-----------------------------+ +| *Getter* | get_mie_eccentricity() | ++-----------+-----------------------------+ + +Controls the direction of the mie scattering. A value of ``1`` means that when light hits a particle it passing through straight forward. A value of ``-1`` means that all light is scatter backwards. + +---- + +.. _class_PhysicalSkyMaterial_property_rayleigh_coefficient: + +- :ref:`float` **rayleigh_coefficient** + ++-----------+---------------------------------+ +| *Default* | ``2.0`` | ++-----------+---------------------------------+ +| *Setter* | set_rayleigh_coefficient(value) | ++-----------+---------------------------------+ +| *Getter* | get_rayleigh_coefficient() | ++-----------+---------------------------------+ + +Controls the strength of the rayleigh scattering. Rayleigh scattering results from light colliding with small particles. It is responsible for the blue color of the sky. + +---- + +.. _class_PhysicalSkyMaterial_property_rayleigh_color: + +- :ref:`Color` **rayleigh_color** + ++-----------+----------------------------------+ +| *Default* | ``Color( 0.056, 0.14, 0.3, 1 )`` | ++-----------+----------------------------------+ +| *Setter* | set_rayleigh_color(value) | ++-----------+----------------------------------+ +| *Getter* | get_rayleigh_color() | ++-----------+----------------------------------+ + +Controls the :ref:`Color` of the rayleigh scattering. While not physically accurate, this allows for the creation of alien looking planets. For example, setting this to a red :ref:`Color` results in a mars looking atmosphere with a corresponding blue sunset. + +---- + +.. _class_PhysicalSkyMaterial_property_sun_disk_scale: + +- :ref:`float` **sun_disk_scale** + ++-----------+---------------------------+ +| *Default* | ``1.0`` | ++-----------+---------------------------+ +| *Setter* | set_sun_disk_scale(value) | ++-----------+---------------------------+ +| *Getter* | get_sun_disk_scale() | ++-----------+---------------------------+ + +Sets the size of the sun disk. Default value is based on Sol's perceived size from Earth. + +---- + +.. _class_PhysicalSkyMaterial_property_turbidity: + +- :ref:`float` **turbidity** + ++-----------+----------------------+ +| *Default* | ``10.0`` | ++-----------+----------------------+ +| *Setter* | set_turbidity(value) | ++-----------+----------------------+ +| *Getter* | get_turbidity() | ++-----------+----------------------+ + +Sets the thickness of the atmosphere. High turbidity creates a foggy looking atmosphere, while a low turbidity results in a clearer atmosphere. + diff --git a/classes/class_proceduralsky.rst b/classes/class_proceduralsky.rst deleted file mode 100644 index 204a84424..000000000 --- a/classes/class_proceduralsky.rst +++ /dev/null @@ -1,347 +0,0 @@ -:github_url: hide - -.. Generated automatically by doc/tools/makerst.py in Godot's source tree. -.. DO NOT EDIT THIS FILE, but the ProceduralSky.xml source instead. -.. The source is found in doc/classes or modules//doc_classes. - -.. _class_ProceduralSky: - -ProceduralSky -============= - -**Inherits:** :ref:`Sky` **<** :ref:`Resource` **<** :ref:`Reference` **<** :ref:`Object` - -Type of :ref:`Sky` that is generated procedurally based on user input parameters. - -Description ------------ - -ProceduralSky provides a way to create an effective background quickly by defining procedural parameters for the sun, the sky and the ground. The sky and ground are very similar, they are defined by a color at the horizon, another color, and finally an easing curve to interpolate between these two colors. Similarly, the sun is described by a position in the sky, a color, and an easing curve. However, the sun also defines a minimum and maximum angle, these two values define at what distance the easing curve begins and ends from the sun, and thus end up defining the size of the sun in the sky. - -The ProceduralSky is updated on the CPU after the parameters change. It is stored in a texture and then displayed as a background in the scene. This makes it relatively unsuitable for real-time updates during gameplay. However, with a small enough texture size, it can still be updated relatively frequently, as it is updated on a background thread when multi-threading is available. - -Properties ----------- - -+----------------------------------------------------+--------------------------------------------------------------------------------+----------------------------------------------+ -| :ref:`Color` | :ref:`ground_bottom_color` | ``Color( 0.156863, 0.184314, 0.211765, 1 )`` | -+----------------------------------------------------+--------------------------------------------------------------------------------+----------------------------------------------+ -| :ref:`float` | :ref:`ground_curve` | ``0.02`` | -+----------------------------------------------------+--------------------------------------------------------------------------------+----------------------------------------------+ -| :ref:`float` | :ref:`ground_energy` | ``1.0`` | -+----------------------------------------------------+--------------------------------------------------------------------------------+----------------------------------------------+ -| :ref:`Color` | :ref:`ground_horizon_color` | ``Color( 0.423529, 0.396078, 0.372549, 1 )`` | -+----------------------------------------------------+--------------------------------------------------------------------------------+----------------------------------------------+ -| :ref:`float` | :ref:`sky_curve` | ``0.09`` | -+----------------------------------------------------+--------------------------------------------------------------------------------+----------------------------------------------+ -| :ref:`float` | :ref:`sky_energy` | ``1.0`` | -+----------------------------------------------------+--------------------------------------------------------------------------------+----------------------------------------------+ -| :ref:`Color` | :ref:`sky_horizon_color` | ``Color( 0.839216, 0.917647, 0.980392, 1 )`` | -+----------------------------------------------------+--------------------------------------------------------------------------------+----------------------------------------------+ -| :ref:`Color` | :ref:`sky_top_color` | ``Color( 0.647059, 0.839216, 0.945098, 1 )`` | -+----------------------------------------------------+--------------------------------------------------------------------------------+----------------------------------------------+ -| :ref:`float` | :ref:`sun_angle_max` | ``100.0`` | -+----------------------------------------------------+--------------------------------------------------------------------------------+----------------------------------------------+ -| :ref:`float` | :ref:`sun_angle_min` | ``1.0`` | -+----------------------------------------------------+--------------------------------------------------------------------------------+----------------------------------------------+ -| :ref:`Color` | :ref:`sun_color` | ``Color( 1, 1, 1, 1 )`` | -+----------------------------------------------------+--------------------------------------------------------------------------------+----------------------------------------------+ -| :ref:`float` | :ref:`sun_curve` | ``0.05`` | -+----------------------------------------------------+--------------------------------------------------------------------------------+----------------------------------------------+ -| :ref:`float` | :ref:`sun_energy` | ``1.0`` | -+----------------------------------------------------+--------------------------------------------------------------------------------+----------------------------------------------+ -| :ref:`float` | :ref:`sun_latitude` | ``35.0`` | -+----------------------------------------------------+--------------------------------------------------------------------------------+----------------------------------------------+ -| :ref:`float` | :ref:`sun_longitude` | ``0.0`` | -+----------------------------------------------------+--------------------------------------------------------------------------------+----------------------------------------------+ -| :ref:`TextureSize` | :ref:`texture_size` | ``2`` | -+----------------------------------------------------+--------------------------------------------------------------------------------+----------------------------------------------+ - -Enumerations ------------- - -.. _enum_ProceduralSky_TextureSize: - -.. _class_ProceduralSky_constant_TEXTURE_SIZE_256: - -.. _class_ProceduralSky_constant_TEXTURE_SIZE_512: - -.. _class_ProceduralSky_constant_TEXTURE_SIZE_1024: - -.. _class_ProceduralSky_constant_TEXTURE_SIZE_2048: - -.. _class_ProceduralSky_constant_TEXTURE_SIZE_4096: - -.. _class_ProceduralSky_constant_TEXTURE_SIZE_MAX: - -enum **TextureSize**: - -- **TEXTURE_SIZE_256** = **0** --- Sky texture will be 256x128. - -- **TEXTURE_SIZE_512** = **1** --- Sky texture will be 512x256. - -- **TEXTURE_SIZE_1024** = **2** --- Sky texture will be 1024x512. This is the default size. - -- **TEXTURE_SIZE_2048** = **3** --- Sky texture will be 2048x1024. - -- **TEXTURE_SIZE_4096** = **4** --- Sky texture will be 4096x2048. - -- **TEXTURE_SIZE_MAX** = **5** --- Represents the size of the :ref:`TextureSize` enum. - -Property Descriptions ---------------------- - -.. _class_ProceduralSky_property_ground_bottom_color: - -- :ref:`Color` **ground_bottom_color** - -+-----------+----------------------------------------------+ -| *Default* | ``Color( 0.156863, 0.184314, 0.211765, 1 )`` | -+-----------+----------------------------------------------+ -| *Setter* | set_ground_bottom_color(value) | -+-----------+----------------------------------------------+ -| *Getter* | get_ground_bottom_color() | -+-----------+----------------------------------------------+ - -Color of the ground at the bottom. - ----- - -.. _class_ProceduralSky_property_ground_curve: - -- :ref:`float` **ground_curve** - -+-----------+-------------------------+ -| *Default* | ``0.02`` | -+-----------+-------------------------+ -| *Setter* | set_ground_curve(value) | -+-----------+-------------------------+ -| *Getter* | get_ground_curve() | -+-----------+-------------------------+ - -How quickly the :ref:`ground_horizon_color` fades into the :ref:`ground_bottom_color`. - ----- - -.. _class_ProceduralSky_property_ground_energy: - -- :ref:`float` **ground_energy** - -+-----------+--------------------------+ -| *Default* | ``1.0`` | -+-----------+--------------------------+ -| *Setter* | set_ground_energy(value) | -+-----------+--------------------------+ -| *Getter* | get_ground_energy() | -+-----------+--------------------------+ - -Amount of energy contribution from the ground. - ----- - -.. _class_ProceduralSky_property_ground_horizon_color: - -- :ref:`Color` **ground_horizon_color** - -+-----------+----------------------------------------------+ -| *Default* | ``Color( 0.423529, 0.396078, 0.372549, 1 )`` | -+-----------+----------------------------------------------+ -| *Setter* | set_ground_horizon_color(value) | -+-----------+----------------------------------------------+ -| *Getter* | get_ground_horizon_color() | -+-----------+----------------------------------------------+ - -Color of the ground at the horizon. - ----- - -.. _class_ProceduralSky_property_sky_curve: - -- :ref:`float` **sky_curve** - -+-----------+----------------------+ -| *Default* | ``0.09`` | -+-----------+----------------------+ -| *Setter* | set_sky_curve(value) | -+-----------+----------------------+ -| *Getter* | get_sky_curve() | -+-----------+----------------------+ - -How quickly the :ref:`sky_horizon_color` fades into the :ref:`sky_top_color`. - ----- - -.. _class_ProceduralSky_property_sky_energy: - -- :ref:`float` **sky_energy** - -+-----------+-----------------------+ -| *Default* | ``1.0`` | -+-----------+-----------------------+ -| *Setter* | set_sky_energy(value) | -+-----------+-----------------------+ -| *Getter* | get_sky_energy() | -+-----------+-----------------------+ - -Amount of energy contribution from the sky. - ----- - -.. _class_ProceduralSky_property_sky_horizon_color: - -- :ref:`Color` **sky_horizon_color** - -+-----------+----------------------------------------------+ -| *Default* | ``Color( 0.839216, 0.917647, 0.980392, 1 )`` | -+-----------+----------------------------------------------+ -| *Setter* | set_sky_horizon_color(value) | -+-----------+----------------------------------------------+ -| *Getter* | get_sky_horizon_color() | -+-----------+----------------------------------------------+ - -Color of the sky at the horizon. - ----- - -.. _class_ProceduralSky_property_sky_top_color: - -- :ref:`Color` **sky_top_color** - -+-----------+----------------------------------------------+ -| *Default* | ``Color( 0.647059, 0.839216, 0.945098, 1 )`` | -+-----------+----------------------------------------------+ -| *Setter* | set_sky_top_color(value) | -+-----------+----------------------------------------------+ -| *Getter* | get_sky_top_color() | -+-----------+----------------------------------------------+ - -Color of the sky at the top. - ----- - -.. _class_ProceduralSky_property_sun_angle_max: - -- :ref:`float` **sun_angle_max** - -+-----------+--------------------------+ -| *Default* | ``100.0`` | -+-----------+--------------------------+ -| *Setter* | set_sun_angle_max(value) | -+-----------+--------------------------+ -| *Getter* | get_sun_angle_max() | -+-----------+--------------------------+ - -Distance from center of sun where it fades out completely. - ----- - -.. _class_ProceduralSky_property_sun_angle_min: - -- :ref:`float` **sun_angle_min** - -+-----------+--------------------------+ -| *Default* | ``1.0`` | -+-----------+--------------------------+ -| *Setter* | set_sun_angle_min(value) | -+-----------+--------------------------+ -| *Getter* | get_sun_angle_min() | -+-----------+--------------------------+ - -Distance from sun where it goes from solid to starting to fade. - ----- - -.. _class_ProceduralSky_property_sun_color: - -- :ref:`Color` **sun_color** - -+-----------+-------------------------+ -| *Default* | ``Color( 1, 1, 1, 1 )`` | -+-----------+-------------------------+ -| *Setter* | set_sun_color(value) | -+-----------+-------------------------+ -| *Getter* | get_sun_color() | -+-----------+-------------------------+ - -The sun's color. - ----- - -.. _class_ProceduralSky_property_sun_curve: - -- :ref:`float` **sun_curve** - -+-----------+----------------------+ -| *Default* | ``0.05`` | -+-----------+----------------------+ -| *Setter* | set_sun_curve(value) | -+-----------+----------------------+ -| *Getter* | get_sun_curve() | -+-----------+----------------------+ - -How quickly the sun fades away between :ref:`sun_angle_min` and :ref:`sun_angle_max`. - ----- - -.. _class_ProceduralSky_property_sun_energy: - -- :ref:`float` **sun_energy** - -+-----------+-----------------------+ -| *Default* | ``1.0`` | -+-----------+-----------------------+ -| *Setter* | set_sun_energy(value) | -+-----------+-----------------------+ -| *Getter* | get_sun_energy() | -+-----------+-----------------------+ - -Amount of energy contribution from the sun. - ----- - -.. _class_ProceduralSky_property_sun_latitude: - -- :ref:`float` **sun_latitude** - -+-----------+-------------------------+ -| *Default* | ``35.0`` | -+-----------+-------------------------+ -| *Setter* | set_sun_latitude(value) | -+-----------+-------------------------+ -| *Getter* | get_sun_latitude() | -+-----------+-------------------------+ - -The sun's height using polar coordinates. - ----- - -.. _class_ProceduralSky_property_sun_longitude: - -- :ref:`float` **sun_longitude** - -+-----------+--------------------------+ -| *Default* | ``0.0`` | -+-----------+--------------------------+ -| *Setter* | set_sun_longitude(value) | -+-----------+--------------------------+ -| *Getter* | get_sun_longitude() | -+-----------+--------------------------+ - -The direction of the sun using polar coordinates. - ----- - -.. _class_ProceduralSky_property_texture_size: - -- :ref:`TextureSize` **texture_size** - -+-----------+-------------------------+ -| *Default* | ``2`` | -+-----------+-------------------------+ -| *Setter* | set_texture_size(value) | -+-----------+-------------------------+ -| *Getter* | get_texture_size() | -+-----------+-------------------------+ - -Size of :ref:`Texture2D` that the ProceduralSky will generate. The size is set using :ref:`TextureSize`. - diff --git a/classes/class_proceduralskymaterial.rst b/classes/class_proceduralskymaterial.rst new file mode 100644 index 000000000..6861a28f2 --- /dev/null +++ b/classes/class_proceduralskymaterial.rst @@ -0,0 +1,228 @@ +:github_url: hide + +.. Generated automatically by doc/tools/makerst.py in Godot's source tree. +.. DO NOT EDIT THIS FILE, but the ProceduralSkyMaterial.xml source instead. +.. The source is found in doc/classes or modules//doc_classes. + +.. _class_ProceduralSkyMaterial: + +ProceduralSkyMaterial +===================== + +**Inherits:** :ref:`Material` **<** :ref:`Resource` **<** :ref:`Reference` **<** :ref:`Object` + +A :ref:`Material` used with :ref:`Sky` to generate a background based on user input parameters. + +Description +----------- + +ProceduralSkyMaterial provides a way to create an effective background quickly by defining procedural parameters for the sun, the sky and the ground. The sky and ground are very similar, they are defined by a color at the horizon, another color, and finally an easing curve to interpolate between these two colors. Similarly, the sun is described by a position in the sky, a color, and an easing curve. However, the sun also defines a minimum and maximum angle, these two values define at what distance the easing curve begins and ends from the sun, and thus end up defining the size of the sun in the sky. + +The ``ProceduralSkyMaterial`` uses a lightweight shader to draw the sky and is thus suited for real time updates. When you do not need a quick sky that is not realistic, this is a good option. + +The ``ProceduralSkyMaterial`` supports up to 4 suns. Each sun takes its color, energy, and direction from the corresponding :ref:`DirectionalLight` in the scene. + +Properties +---------- + ++---------------------------+----------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`Color` | :ref:`ground_bottom_color` | ``Color( 0.12, 0.12, 0.13, 1 )`` | ++---------------------------+----------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`float` | :ref:`ground_curve` | ``0.02`` | ++---------------------------+----------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`float` | :ref:`ground_energy` | ``1.0`` | ++---------------------------+----------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`Color` | :ref:`ground_horizon_color` | ``Color( 0.37, 0.33, 0.31, 1 )`` | ++---------------------------+----------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`float` | :ref:`sky_curve` | ``0.09`` | ++---------------------------+----------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`float` | :ref:`sky_energy` | ``1.0`` | ++---------------------------+----------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`Color` | :ref:`sky_horizon_color` | ``Color( 0.55, 0.69, 0.81, 1 )`` | ++---------------------------+----------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`Color` | :ref:`sky_top_color` | ``Color( 0.35, 0.46, 0.71, 1 )`` | ++---------------------------+----------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`float` | :ref:`sun_angle_max` | ``100.0`` | ++---------------------------+----------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`float` | :ref:`sun_angle_min` | ``1.0`` | ++---------------------------+----------------------------------------------------------------------------------------+----------------------------------+ +| :ref:`float` | :ref:`sun_curve` | ``0.05`` | ++---------------------------+----------------------------------------------------------------------------------------+----------------------------------+ + +Property Descriptions +--------------------- + +.. _class_ProceduralSkyMaterial_property_ground_bottom_color: + +- :ref:`Color` **ground_bottom_color** + ++-----------+----------------------------------+ +| *Default* | ``Color( 0.12, 0.12, 0.13, 1 )`` | ++-----------+----------------------------------+ +| *Setter* | set_ground_bottom_color(value) | ++-----------+----------------------------------+ +| *Getter* | get_ground_bottom_color() | ++-----------+----------------------------------+ + +Color of the ground at the bottom. Blends with :ref:`ground_horizon_color`. + +---- + +.. _class_ProceduralSkyMaterial_property_ground_curve: + +- :ref:`float` **ground_curve** + ++-----------+-------------------------+ +| *Default* | ``0.02`` | ++-----------+-------------------------+ +| *Setter* | set_ground_curve(value) | ++-----------+-------------------------+ +| *Getter* | get_ground_curve() | ++-----------+-------------------------+ + +How quickly the :ref:`ground_horizon_color` fades into the :ref:`ground_bottom_color`. + +---- + +.. _class_ProceduralSkyMaterial_property_ground_energy: + +- :ref:`float` **ground_energy** + ++-----------+--------------------------+ +| *Default* | ``1.0`` | ++-----------+--------------------------+ +| *Setter* | set_ground_energy(value) | ++-----------+--------------------------+ +| *Getter* | get_ground_energy() | ++-----------+--------------------------+ + +Amount of energy contribution from the ground. + +---- + +.. _class_ProceduralSkyMaterial_property_ground_horizon_color: + +- :ref:`Color` **ground_horizon_color** + ++-----------+----------------------------------+ +| *Default* | ``Color( 0.37, 0.33, 0.31, 1 )`` | ++-----------+----------------------------------+ +| *Setter* | set_ground_horizon_color(value) | ++-----------+----------------------------------+ +| *Getter* | get_ground_horizon_color() | ++-----------+----------------------------------+ + +Color of the ground at the horizon. Blends with :ref:`ground_bottom_color`. + +---- + +.. _class_ProceduralSkyMaterial_property_sky_curve: + +- :ref:`float` **sky_curve** + ++-----------+----------------------+ +| *Default* | ``0.09`` | ++-----------+----------------------+ +| *Setter* | set_sky_curve(value) | ++-----------+----------------------+ +| *Getter* | get_sky_curve() | ++-----------+----------------------+ + +How quickly the :ref:`sky_horizon_color` fades into the :ref:`sky_top_color`. + +---- + +.. _class_ProceduralSkyMaterial_property_sky_energy: + +- :ref:`float` **sky_energy** + ++-----------+-----------------------+ +| *Default* | ``1.0`` | ++-----------+-----------------------+ +| *Setter* | set_sky_energy(value) | ++-----------+-----------------------+ +| *Getter* | get_sky_energy() | ++-----------+-----------------------+ + +Amount of energy contribution from the sky. + +---- + +.. _class_ProceduralSkyMaterial_property_sky_horizon_color: + +- :ref:`Color` **sky_horizon_color** + ++-----------+----------------------------------+ +| *Default* | ``Color( 0.55, 0.69, 0.81, 1 )`` | ++-----------+----------------------------------+ +| *Setter* | set_sky_horizon_color(value) | ++-----------+----------------------------------+ +| *Getter* | get_sky_horizon_color() | ++-----------+----------------------------------+ + +Color of the sky at the horizon. Blends with :ref:`sky_top_color`. + +---- + +.. _class_ProceduralSkyMaterial_property_sky_top_color: + +- :ref:`Color` **sky_top_color** + ++-----------+----------------------------------+ +| *Default* | ``Color( 0.35, 0.46, 0.71, 1 )`` | ++-----------+----------------------------------+ +| *Setter* | set_sky_top_color(value) | ++-----------+----------------------------------+ +| *Getter* | get_sky_top_color() | ++-----------+----------------------------------+ + +Color of the sky at the top. Blends with :ref:`sky_horizon_color`. + +---- + +.. _class_ProceduralSkyMaterial_property_sun_angle_max: + +- :ref:`float` **sun_angle_max** + ++-----------+--------------------------+ +| *Default* | ``100.0`` | ++-----------+--------------------------+ +| *Setter* | set_sun_angle_max(value) | ++-----------+--------------------------+ +| *Getter* | get_sun_angle_max() | ++-----------+--------------------------+ + +Distance from center of sun where it fades out completely. + +---- + +.. _class_ProceduralSkyMaterial_property_sun_angle_min: + +- :ref:`float` **sun_angle_min** + ++-----------+--------------------------+ +| *Default* | ``1.0`` | ++-----------+--------------------------+ +| *Setter* | set_sun_angle_min(value) | ++-----------+--------------------------+ +| *Getter* | get_sun_angle_min() | ++-----------+--------------------------+ + +Distance from sun where it goes from solid to starting to fade. + +---- + +.. _class_ProceduralSkyMaterial_property_sun_curve: + +- :ref:`float` **sun_curve** + ++-----------+----------------------+ +| *Default* | ``0.05`` | ++-----------+----------------------+ +| *Setter* | set_sun_curve(value) | ++-----------+----------------------+ +| *Getter* | get_sun_curve() | ++-----------+----------------------+ + +How quickly the sun fades away between :ref:`sun_angle_min` and :ref:`sun_angle_max`. + diff --git a/classes/class_projectsettings.rst b/classes/class_projectsettings.rst index f99108d50..f7fcc6b5e 100644 --- a/classes/class_projectsettings.rst +++ b/classes/class_projectsettings.rst @@ -576,7 +576,7 @@ Properties +---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------+ | :ref:`int` | :ref:`rendering/quality/reflection_atlas/reflection_count` | ``64`` | +---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------+ -| :ref:`int` | :ref:`rendering/quality/reflection_atlas/reflection_size` | ``128`` | +| :ref:`int` | :ref:`rendering/quality/reflection_atlas/reflection_size` | ``256`` | +---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------+ | :ref:`int` | :ref:`rendering/quality/reflection_atlas/reflection_size.mobile` | ``128`` | +---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------+ @@ -586,7 +586,7 @@ Properties +---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------+ | :ref:`int` | :ref:`rendering/quality/reflections/ggx_samples.mobile` | ``128`` | +---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------+ -| :ref:`int` | :ref:`rendering/quality/reflections/roughness_layers` | ``6`` | +| :ref:`int` | :ref:`rendering/quality/reflections/roughness_layers` | ``8`` | +---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------+ | :ref:`bool` | :ref:`rendering/quality/reflections/texture_array_reflections` | ``true`` | +---------------------------------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------------------------+-------------------------------------------------------------------------------------------------+ @@ -3988,7 +3988,7 @@ Number of cubemaps to store in the reflection atlas. The number of :ref:`Reflect - :ref:`int` **rendering/quality/reflection_atlas/reflection_size** +-----------+---------+ -| *Default* | ``128`` | +| *Default* | ``256`` | +-----------+---------+ Size of cubemap faces for :ref:`ReflectionProbe`\ s. A higher number requires more VRAM and may make reflection probe updating slower. @@ -4048,7 +4048,7 @@ Lower-end override for :ref:`rendering/quality/reflections/ggx_samples` **rendering/quality/reflections/roughness_layers** +-----------+-------+ -| *Default* | ``6`` | +| *Default* | ``8`` | +-----------+-------+ Limits the number of layers to use in radiance maps when using importance sampling. A lower number will be slightly faster and take up less VRAM. diff --git a/classes/class_shader.rst b/classes/class_shader.rst index 7c21efc36..32fbe4a21 100644 --- a/classes/class_shader.rst +++ b/classes/class_shader.rst @@ -58,6 +58,8 @@ Enumerations .. _class_Shader_constant_MODE_PARTICLES: +.. _class_Shader_constant_MODE_SKY: + enum **Mode**: - **MODE_SPATIAL** = **0** --- Mode used to draw all 3D objects. @@ -66,6 +68,8 @@ enum **Mode**: - **MODE_PARTICLES** = **2** --- Mode used to calculate particle information on a per-particle basis. Not used for drawing. +- **MODE_SKY** = **3** --- Mode used for drawing skies. Only works with shaders attached to :ref:`Sky` objects. + Property Descriptions --------------------- diff --git a/classes/class_signal.rst b/classes/class_signal.rst index 9c7130a6e..b704007f1 100644 --- a/classes/class_signal.rst +++ b/classes/class_signal.rst @@ -19,7 +19,7 @@ Methods +-------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`int` | :ref:`connect` **(** :ref:`Callable` callable, :ref:`Array` binds=[ ], :ref:`int` flags=0 **)** | +-------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`disconnect` **(** :ref:`Callable` callable **)** | +| :ref:`Variant` | :ref:`disconnect` **(** :ref:`Callable` callable **)** | +-------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | void | :ref:`emit` **(** ... **)** vararg | +-------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -57,7 +57,7 @@ Connects this signal to the specified :ref:`Callable`, optionall .. _class_Signal_method_disconnect: -- void **disconnect** **(** :ref:`Callable` callable **)** +- :ref:`Variant` **disconnect** **(** :ref:`Callable` callable **)** Disconnects this signal from the specified :ref:`Callable`. diff --git a/classes/class_sky.rst b/classes/class_sky.rst index aadb6e369..5150288d4 100644 --- a/classes/class_sky.rst +++ b/classes/class_sky.rst @@ -11,14 +11,12 @@ Sky **Inherits:** :ref:`Resource` **<** :ref:`Reference` **<** :ref:`Object` -**Inherited By:** :ref:`PanoramaSky`, :ref:`ProceduralSky` - -The base class for :ref:`PanoramaSky` and :ref:`ProceduralSky`. +Background that uses a :ref:`Material` to draw a sky. Description ----------- -The base class for :ref:`PanoramaSky` and :ref:`ProceduralSky`. +The ``Sky`` class uses a :ref:`Material` to draw the background and update the reflection/radiance cubemaps. Properties ---------- @@ -26,7 +24,9 @@ Properties +--------------------------------------------+--------------------------------------------------------+-------+ | :ref:`ProcessMode` | :ref:`process_mode` | ``0`` | +--------------------------------------------+--------------------------------------------------------+-------+ -| :ref:`RadianceSize` | :ref:`radiance_size` | ``2`` | +| :ref:`RadianceSize` | :ref:`radiance_size` | ``3`` | ++--------------------------------------------+--------------------------------------------------------+-------+ +| :ref:`Material` | :ref:`sky_material` | | +--------------------------------------------+--------------------------------------------------------+-------+ Enumerations @@ -82,7 +82,7 @@ enum **ProcessMode**: - **PROCESS_MODE_REALTIME** = **1** --- Uses the fast filtering algorithm to process the radiance map. In general this results in lower quality, but substantially faster run times. -**Note:** The fast filtering algorithm is limited to 128x128 cubemaps, so :ref:`radiance_size` must be set to :ref:`RADIANCE_SIZE_128`. +**Note:** The fast filtering algorithm is limited to 256x256 cubemaps, so :ref:`radiance_size` must be set to :ref:`RADIANCE_SIZE_256`. Property Descriptions --------------------- @@ -108,7 +108,7 @@ Sets the method for generating the radiance map from the sky. The radiance map i - :ref:`RadianceSize` **radiance_size** +-----------+--------------------------+ -| *Default* | ``2`` | +| *Default* | ``3`` | +-----------+--------------------------+ | *Setter* | set_radiance_size(value) | +-----------+--------------------------+ @@ -121,3 +121,17 @@ See :ref:`RadianceSize` constants for values. **Note:** Some hardware will have trouble with higher radiance sizes, especially :ref:`RADIANCE_SIZE_512` and above. Only use such high values on high-end hardware. +---- + +.. _class_Sky_property_sky_material: + +- :ref:`Material` **sky_material** + ++----------+---------------------+ +| *Setter* | set_material(value) | ++----------+---------------------+ +| *Getter* | get_material() | ++----------+---------------------+ + +:ref:`Material` used to draw the background. Can be :ref:`PanoramaSkyMaterial`, :ref:`ProceduralSkyMaterial`, :ref:`PhysicalSkyMaterial`, or even a :ref:`ShaderMaterial` if you want to use your own custom shader. + diff --git a/classes/class_transform.rst b/classes/class_transform.rst index 309ca9a0b..832e1128c 100644 --- a/classes/class_transform.rst +++ b/classes/class_transform.rst @@ -64,9 +64,9 @@ Methods +-----------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Transform` | :ref:`translated` **(** :ref:`Vector3` offset **)** | +-----------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`xform` **(** :ref:`Variant` v **)** | +| :ref:`Variant` | :ref:`xform` **(** :ref:`Variant` v **)** | +-----------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`xform_inv` **(** :ref:`Variant` v **)** | +| :ref:`Variant` | :ref:`xform_inv` **(** :ref:`Variant` v **)** | +-----------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ Constants @@ -228,7 +228,7 @@ Unlike :ref:`rotated` and :ref:`scaled` v **)** +- :ref:`Variant` **xform** **(** :ref:`Variant` v **)** Transforms the given :ref:`Vector3`, :ref:`Plane`, :ref:`AABB`, or :ref:`PackedVector3Array` by this transform. @@ -236,7 +236,7 @@ Transforms the given :ref:`Vector3`, :ref:`Plane`, : .. _class_Transform_method_xform_inv: -- void **xform_inv** **(** :ref:`Variant` v **)** +- :ref:`Variant` **xform_inv** **(** :ref:`Variant` v **)** Inverse-transforms the given :ref:`Vector3`, :ref:`Plane`, :ref:`AABB`, or :ref:`PackedVector3Array` by this transform. diff --git a/classes/class_transform2d.rst b/classes/class_transform2d.rst index 4c5d9b0ed..f72ca8104 100644 --- a/classes/class_transform2d.rst +++ b/classes/class_transform2d.rst @@ -63,9 +63,9 @@ Methods +---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`Transform2D` | :ref:`translated` **(** :ref:`Vector2` offset **)** | +---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`xform` **(** :ref:`Variant` v **)** | +| :ref:`Variant` | :ref:`xform` **(** :ref:`Variant` v **)** | +---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`xform_inv` **(** :ref:`Variant` v **)** | +| :ref:`Variant` | :ref:`xform_inv` **(** :ref:`Variant` v **)** | +---------------------------------------+---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ Constants @@ -251,7 +251,7 @@ Unlike :ref:`rotated` and :ref:`scaled` v **)** +- :ref:`Variant` **xform** **(** :ref:`Variant` v **)** Transforms the given :ref:`Vector2`, :ref:`Rect2`, or :ref:`PackedVector2Array` by this transform. @@ -259,7 +259,7 @@ Transforms the given :ref:`Vector2`, :ref:`Rect2`, o .. _class_Transform2D_method_xform_inv: -- void **xform_inv** **(** :ref:`Variant` v **)** +- :ref:`Variant` **xform_inv** **(** :ref:`Variant` v **)** Inverse-transforms the given :ref:`Vector2`, :ref:`Rect2`, or :ref:`PackedVector2Array` by this transform. diff --git a/classes/class_treeitem.rst b/classes/class_treeitem.rst index 439aed9d4..bd3158dfc 100644 --- a/classes/class_treeitem.rst +++ b/classes/class_treeitem.rst @@ -249,9 +249,7 @@ Method Descriptions - void **add_button** **(** :ref:`int` column, :ref:`Texture2D` button, :ref:`int` button_idx=-1, :ref:`bool` disabled=false, :ref:`String` tooltip="" **)** -Adds a button with :ref:`Texture2D` ``button`` at column ``column``. The ``button_idx`` index is used to identify the button when calling other methods. If not specified, the next available index is used, which may be retrieved by calling :ref:`get_button_count` immediately after this method. Optionally, the button can be ``disabled`` and have a ``tooltip - -``. +Adds a button with :ref:`Texture2D` ``button`` at column ``column``. The ``button_idx`` index is used to identify the button when calling other methods. If not specified, the next available index is used, which may be retrieved by calling :ref:`get_button_count` immediately after this method. Optionally, the button can be ``disabled`` and have a ``tooltip``. ---- diff --git a/classes/class_vboxcontainer.rst b/classes/class_vboxcontainer.rst index 821c49953..451793a15 100644 --- a/classes/class_vboxcontainer.rst +++ b/classes/class_vboxcontainer.rst @@ -11,6 +11,8 @@ VBoxContainer **Inherits:** :ref:`BoxContainer` **<** :ref:`Container` **<** :ref:`Control` **<** :ref:`CanvasItem` **<** :ref:`Node` **<** :ref:`Object` +**Inherited By:** :ref:`FileSystemDock` + Vertical box container. Description diff --git a/classes/class_visibilityenabler.rst b/classes/class_visibilityenabler.rst index 18e1450a2..52d42b806 100644 --- a/classes/class_visibilityenabler.rst +++ b/classes/class_visibilityenabler.rst @@ -18,6 +18,8 @@ Description The VisibilityEnabler will disable :ref:`RigidBody` and :ref:`AnimationPlayer` nodes when they are not visible. It will only affect other nodes within the same scene as the VisibilityEnabler itself. +Note that VisibilityEnabler will not affect nodes added after scene initialization. + Properties ---------- diff --git a/classes/class_visibilityenabler2d.rst b/classes/class_visibilityenabler2d.rst index 6f4843a97..24ee4cc8f 100644 --- a/classes/class_visibilityenabler2d.rst +++ b/classes/class_visibilityenabler2d.rst @@ -18,6 +18,8 @@ Description The VisibilityEnabler2D will disable :ref:`RigidBody2D`, :ref:`AnimationPlayer`, and other nodes when they are not visible. It will only affect nodes with the same root node as the VisibilityEnabler2D, and the root node itself. +Note that VisibilityEnabler2D will not affect nodes added after scene initialization. + Properties ---------- diff --git a/classes/class_visualserver.rst b/classes/class_visualserver.rst index 19310b5b4..e92701e68 100644 --- a/classes/class_visualserver.rst +++ b/classes/class_visualserver.rst @@ -529,7 +529,7 @@ Methods +---------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`RID` | :ref:`sky_create` **(** **)** | +---------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ -| void | :ref:`sky_set_texture` **(** :ref:`RID` sky, :ref:`RID` panorama **)** | +| void | :ref:`sky_set_material` **(** :ref:`RID` sky, :ref:`RID` material **)** | +---------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ | :ref:`RID` | :ref:`spot_light_create` **(** **)** | +---------------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ @@ -668,6 +668,8 @@ enum **CubeMapLayer**: .. _class_VisualServer_constant_SHADER_PARTICLES: +.. _class_VisualServer_constant_SHADER_SKY: + .. _class_VisualServer_constant_SHADER_MAX: enum **ShaderMode**: @@ -678,7 +680,9 @@ enum **ShaderMode**: - **SHADER_PARTICLES** = **2** --- Shader is a particle shader. -- **SHADER_MAX** = **3** --- Represents the size of the :ref:`ShaderMode` enum. +- **SHADER_SKY** = **3** --- Shader is a sky shader. + +- **SHADER_MAX** = **4** --- Represents the size of the :ref:`ShaderMode` enum. ---- @@ -3782,9 +3786,11 @@ Once finished with your RID, you will want to free the RID using the VisualServe ---- -.. _class_VisualServer_method_sky_set_texture: +.. _class_VisualServer_method_sky_set_material: -- void **sky_set_texture** **(** :ref:`RID` sky, :ref:`RID` panorama **)** +- void **sky_set_material** **(** :ref:`RID` sky, :ref:`RID` material **)** + +Sets the material that the sky uses to render the background and reflection maps. ----