: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/RDPipelineMultisampleState.xml. .. _class_RDPipelineMultisampleState: RDPipelineMultisampleState ========================== **Inherits:** :ref:`RefCounted` **<** :ref:`Object` Pipeline multisample state (used by :ref:`RenderingDevice`). .. rst-class:: classref-introduction-group Description ----------- **RDPipelineMultisampleState** is used to control how multisample or supersample antialiasing is being performed when rendering using :ref:`RenderingDevice`. .. rst-class:: classref-reftable-group Properties ---------- .. table:: :widths: auto +------------------------------------------------------------+-----------------------------------------------------------------------------------------------------+-----------+ | :ref:`bool` | :ref:`enable_alpha_to_coverage` | ``false`` | +------------------------------------------------------------+-----------------------------------------------------------------------------------------------------+-----------+ | :ref:`bool` | :ref:`enable_alpha_to_one` | ``false`` | +------------------------------------------------------------+-----------------------------------------------------------------------------------------------------+-----------+ | :ref:`bool` | :ref:`enable_sample_shading` | ``false`` | +------------------------------------------------------------+-----------------------------------------------------------------------------------------------------+-----------+ | :ref:`float` | :ref:`min_sample_shading` | ``0.0`` | +------------------------------------------------------------+-----------------------------------------------------------------------------------------------------+-----------+ | :ref:`TextureSamples` | :ref:`sample_count` | ``0`` | +------------------------------------------------------------+-----------------------------------------------------------------------------------------------------+-----------+ | :ref:`Array`\[:ref:`int`\] | :ref:`sample_masks` | ``[]`` | +------------------------------------------------------------+-----------------------------------------------------------------------------------------------------+-----------+ .. rst-class:: classref-section-separator ---- .. rst-class:: classref-descriptions-group Property Descriptions --------------------- .. _class_RDPipelineMultisampleState_property_enable_alpha_to_coverage: .. rst-class:: classref-property :ref:`bool` **enable_alpha_to_coverage** = ``false`` :ref:`🔗` .. rst-class:: classref-property-setget - |void| **set_enable_alpha_to_coverage**\ (\ value\: :ref:`bool`\ ) - :ref:`bool` **get_enable_alpha_to_coverage**\ (\ ) If ``true``, alpha to coverage is enabled. This generates a temporary coverage value based on the alpha component of the fragment's first color output. This allows alpha transparency to make use of multisample antialiasing. .. rst-class:: classref-item-separator ---- .. _class_RDPipelineMultisampleState_property_enable_alpha_to_one: .. rst-class:: classref-property :ref:`bool` **enable_alpha_to_one** = ``false`` :ref:`🔗` .. rst-class:: classref-property-setget - |void| **set_enable_alpha_to_one**\ (\ value\: :ref:`bool`\ ) - :ref:`bool` **get_enable_alpha_to_one**\ (\ ) If ``true``, alpha is forced to either ``0.0`` or ``1.0``. This allows hardening the edges of antialiased alpha transparencies. Only relevant if :ref:`enable_alpha_to_coverage` is ``true``. .. rst-class:: classref-item-separator ---- .. _class_RDPipelineMultisampleState_property_enable_sample_shading: .. rst-class:: classref-property :ref:`bool` **enable_sample_shading** = ``false`` :ref:`🔗` .. rst-class:: classref-property-setget - |void| **set_enable_sample_shading**\ (\ value\: :ref:`bool`\ ) - :ref:`bool` **get_enable_sample_shading**\ (\ ) If ``true``, enables per-sample shading which replaces MSAA by SSAA. This provides higher quality antialiasing that works with transparent (alpha scissor) edges. This has a very high performance cost. See also :ref:`min_sample_shading`. See the `per-sample shading Vulkan documentation `__ for more details. .. rst-class:: classref-item-separator ---- .. _class_RDPipelineMultisampleState_property_min_sample_shading: .. rst-class:: classref-property :ref:`float` **min_sample_shading** = ``0.0`` :ref:`🔗` .. rst-class:: classref-property-setget - |void| **set_min_sample_shading**\ (\ value\: :ref:`float`\ ) - :ref:`float` **get_min_sample_shading**\ (\ ) The multiplier of :ref:`sample_count` that determines how many samples are performed for each fragment. Must be between ``0.0`` and ``1.0`` (inclusive). Only effective if :ref:`enable_sample_shading` is ``true``. If :ref:`min_sample_shading` is ``1.0``, fragment invocation must only read from the coverage index sample. Tile image access must not be used if :ref:`enable_sample_shading` is *not* ``1.0``. .. rst-class:: classref-item-separator ---- .. _class_RDPipelineMultisampleState_property_sample_count: .. rst-class:: classref-property :ref:`TextureSamples` **sample_count** = ``0`` :ref:`🔗` .. rst-class:: classref-property-setget - |void| **set_sample_count**\ (\ value\: :ref:`TextureSamples`\ ) - :ref:`TextureSamples` **get_sample_count**\ (\ ) The number of MSAA samples (or SSAA samples if :ref:`enable_sample_shading` is ``true``) to perform. Higher values result in better antialiasing, at the cost of performance. .. rst-class:: classref-item-separator ---- .. _class_RDPipelineMultisampleState_property_sample_masks: .. rst-class:: classref-property :ref:`Array`\[:ref:`int`\] **sample_masks** = ``[]`` :ref:`🔗` .. rst-class:: classref-property-setget - |void| **set_sample_masks**\ (\ value\: :ref:`Array`\[:ref:`int`\]\ ) - :ref:`Array`\[:ref:`int`\] **get_sample_masks**\ (\ ) The sample mask array. See the `sample mask Vulkan documentation `__ for more details. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)` .. |required| replace:: :abbr:`required (This method is required to be overridden when extending its base class.)` .. |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.)` .. |bitfield| replace:: :abbr:`BitField (This value is an integer composed as a bitmask of the following flags.)` .. |void| replace:: :abbr:`void (No return value.)`