Files
godot-docs-l10n/classes/fr/class_rdshaderfile.rst

121 lines
6.0 KiB
ReStructuredText
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

:github_url: hide
.. _class_RDShaderFile:
RDShaderFile
============
**Hérite de:** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
Compiled shader file in SPIR-V form (used by :ref:`RenderingDevice<class_RenderingDevice>`). Not to be confused with Godot's own :ref:`Shader<class_Shader>`.
.. rst-class:: classref-introduction-group
Description
-----------
Compiled shader file in SPIR-V form.
See also :ref:`RDShaderSource<class_RDShaderSource>`. **RDShaderFile** is only meant to be used with the :ref:`RenderingDevice<class_RenderingDevice>` API. It should not be confused with Godot's own :ref:`Shader<class_Shader>` resource, which is what Godot's various nodes use for high-level shader programming.
.. rst-class:: classref-reftable-group
Propriétés
--------------------
.. table::
:widths: auto
+-----------------------------+-----------------------------------------------------------+--------+
| :ref:`String<class_String>` | :ref:`base_error<class_RDShaderFile_property_base_error>` | ``""`` |
+-----------------------------+-----------------------------------------------------------+--------+
.. rst-class:: classref-reftable-group
Méthodes
----------------
.. table::
:widths: auto
+------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`RDShaderSPIRV<class_RDShaderSPIRV>` | :ref:`get_spirv<class_RDShaderFile_method_get_spirv>`\ (\ version\: :ref:`StringName<class_StringName>` = &""\ ) |const| |
+------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Array<class_Array>`\[:ref:`StringName<class_StringName>`\] | :ref:`get_version_list<class_RDShaderFile_method_get_version_list>`\ (\ ) |const| |
+------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_bytecode<class_RDShaderFile_method_set_bytecode>`\ (\ bytecode\: :ref:`RDShaderSPIRV<class_RDShaderSPIRV>`, version\: :ref:`StringName<class_StringName>` = &""\ ) |
+------------------------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
.. rst-class:: classref-section-separator
----
.. rst-class:: classref-descriptions-group
Descriptions des propriétés
------------------------------------------------------
.. _class_RDShaderFile_property_base_error:
.. rst-class:: classref-property
:ref:`String<class_String>` **base_error** = ``""`` :ref:`🔗<class_RDShaderFile_property_base_error>`
.. rst-class:: classref-property-setget
- |void| **set_base_error**\ (\ value\: :ref:`String<class_String>`\ )
- :ref:`String<class_String>` **get_base_error**\ (\ )
The base compilation error message, which indicates errors not related to a specific shader stage if non-empty. If empty, shader compilation is not necessarily successful (check :ref:`RDShaderSPIRV<class_RDShaderSPIRV>`'s error message members).
.. rst-class:: classref-section-separator
----
.. rst-class:: classref-descriptions-group
Descriptions des méthodes
--------------------------------------------------
.. _class_RDShaderFile_method_get_spirv:
.. rst-class:: classref-method
:ref:`RDShaderSPIRV<class_RDShaderSPIRV>` **get_spirv**\ (\ version\: :ref:`StringName<class_StringName>` = &""\ ) |const| :ref:`🔗<class_RDShaderFile_method_get_spirv>`
Returns the SPIR-V intermediate representation for the specified shader ``version``.
.. rst-class:: classref-item-separator
----
.. _class_RDShaderFile_method_get_version_list:
.. rst-class:: classref-method
:ref:`Array<class_Array>`\[:ref:`StringName<class_StringName>`\] **get_version_list**\ (\ ) |const| :ref:`🔗<class_RDShaderFile_method_get_version_list>`
Returns the list of compiled versions for this shader.
.. rst-class:: classref-item-separator
----
.. _class_RDShaderFile_method_set_bytecode:
.. rst-class:: classref-method
|void| **set_bytecode**\ (\ bytecode\: :ref:`RDShaderSPIRV<class_RDShaderSPIRV>`, version\: :ref:`StringName<class_StringName>` = &""\ ) :ref:`🔗<class_RDShaderFile_method_set_bytecode>`
Sets the SPIR-V ``bytecode`` that will be compiled for the specified ``version``.
.. |virtual| replace:: :abbr:`virtual (Cette méthode doit typiquement être redéfinie par l'utilisateur pour avoir un effet.)`
.. |required| replace:: :abbr:`required (This method is required to be overridden when extending its base class.)`
.. |const| replace:: :abbr:`const (Cette méthode n'a pas d'effets de bord. Elle ne modifie aucune des variables membres de l'instance.)`
.. |vararg| replace:: :abbr:`vararg (Cette méthode accepte n'importe quel nombre d'arguments après ceux décris ici.)`
.. |constructor| replace:: :abbr:`constructor (Cette méthode est utilisée pour construire un type.)`
.. |static| replace:: :abbr:`static (Cette méthode n'a pas besoin d'instance pour être appelée, elle peut donc être directement appelée en utilisant le nom de la classe.)`
.. |operator| replace:: :abbr:`operator (Cette méthode décrit un opérateur valide à utiliser avec ce type en tant qu'opérande gauche.)`
.. |bitfield| replace:: :abbr:`BitField (Cette valeur est un nombre entier composé d'un masque de bits des options suivantes.)`
.. |void| replace:: :abbr:`void (Aucune valeur de retour.)`