:github_url: hide .. DO NOT EDIT THIS FILE!!! .. Generated automatically from Godot engine sources. .. Generator: https://github.com/godotengine/godot/tree/master/doc/tools/make_rst.py. .. XML source: https://github.com/godotengine/godot/tree/master/doc/classes/FogVolume.xml. .. _class_FogVolume: FogVolume ========= **Inherits:** :ref:`VisualInstance3D` **<** :ref:`Node3D` **<** :ref:`Node` **<** :ref:`Object` A node used to add local fog with the volumetric fog effect. Description ----------- ``FogVolume``\ s are used to add localized fog into the global volumetric fog effect. Performance of ``FogVolume``\ s is directly related to their relative size on the screen and the complexity of their attached :ref:`FogMaterial`. It is best to keep ``FogVolume``\ s relatively small and simple where possible. Properties ---------- +------------------------------------------------------------+----------------------------------------------------+----------------------+ | :ref:`Vector3` | :ref:`extents` | ``Vector3(1, 1, 1)`` | +------------------------------------------------------------+----------------------------------------------------+----------------------+ | :ref:`Material` | :ref:`material` | | +------------------------------------------------------------+----------------------------------------------------+----------------------+ | :ref:`FogVolumeShape` | :ref:`shape` | ``3`` | +------------------------------------------------------------+----------------------------------------------------+----------------------+ Property Descriptions --------------------- .. _class_FogVolume_property_extents: - :ref:`Vector3` **extents** +-----------+----------------------+ | *Default* | ``Vector3(1, 1, 1)`` | +-----------+----------------------+ | *Setter* | set_extents(value) | +-----------+----------------------+ | *Getter* | get_extents() | +-----------+----------------------+ Sets the size of the ``FogVolume`` when :ref:`shape` is :ref:`RenderingServer.FOG_VOLUME_SHAPE_ELLIPSOID`, :ref:`RenderingServer.FOG_VOLUME_SHAPE_CONE`, :ref:`RenderingServer.FOG_VOLUME_SHAPE_CYLINDER` or :ref:`RenderingServer.FOG_VOLUME_SHAPE_BOX`. \ **Note:** Thin fog volumes may appear to flicker when the camera moves or rotates. This can be alleviated by increasing :ref:`ProjectSettings.rendering/environment/volumetric_fog/volume_depth` (at a performance cost) or by decreasing :ref:`Environment.volumetric_fog_length` (at no performance cost, but at the cost of lower fog range). Alternatively, the ``FogVolume`` can be made thicker and use a lower density in the :ref:`material`. \ **Note:** If :ref:`shape` is :ref:`RenderingServer.FOG_VOLUME_SHAPE_CONE` or :ref:`RenderingServer.FOG_VOLUME_SHAPE_CYLINDER`, the cone/cylinder will be adjusted to fit within the extents. Non-uniform scaling of cone/cylinder shapes via the :ref:`extents` property is not supported, but you can scale the ``FogVolume`` node instead. ---- .. _class_FogVolume_property_material: - :ref:`Material` **material** +----------+---------------------+ | *Setter* | set_material(value) | +----------+---------------------+ | *Getter* | get_material() | +----------+---------------------+ Sets the :ref:`Material` to be used by the ``FogVolume``. Can be either a :ref:`FogMaterial` or a custom :ref:`ShaderMaterial`. ---- .. _class_FogVolume_property_shape: - :ref:`FogVolumeShape` **shape** +-----------+------------------+ | *Default* | ``3`` | +-----------+------------------+ | *Setter* | set_shape(value) | +-----------+------------------+ | *Getter* | get_shape() | +-----------+------------------+ Sets the shape of the ``FogVolume`` to either :ref:`RenderingServer.FOG_VOLUME_SHAPE_ELLIPSOID`, :ref:`RenderingServer.FOG_VOLUME_SHAPE_CONE`, :ref:`RenderingServer.FOG_VOLUME_SHAPE_CYLINDER`, :ref:`RenderingServer.FOG_VOLUME_SHAPE_BOX` or :ref:`RenderingServer.FOG_VOLUME_SHAPE_WORLD`. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)` .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)` .. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)` .. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)` .. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)`