12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667 |
- :github_url: hide
- .. Generated automatically by doc/tools/makerst.py in Godot's source tree.
- .. DO NOT EDIT THIS FILE, but the VisualShaderNodeIntFunc.xml source instead.
- .. The source is found in doc/classes or modules/<name>/doc_classes.
- .. _class_VisualShaderNodeIntFunc:
- VisualShaderNodeIntFunc
- =======================
- **Inherits:** :ref:`VisualShaderNode<class_VisualShaderNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
- A scalar integer function to be used within the visual shader graph.
- Description
- -----------
- Accept an integer scalar (``x``) to the input port and transform it according to :ref:`function<class_VisualShaderNodeIntFunc_property_function>`.
- Properties
- ----------
- +--------------------------------------------------------+------------------------------------------------------------------+-------+
- | :ref:`Function<enum_VisualShaderNodeIntFunc_Function>` | :ref:`function<class_VisualShaderNodeIntFunc_property_function>` | ``3`` |
- +--------------------------------------------------------+------------------------------------------------------------------+-------+
- Enumerations
- ------------
- .. _enum_VisualShaderNodeIntFunc_Function:
- .. _class_VisualShaderNodeIntFunc_constant_FUNC_ABS:
- .. _class_VisualShaderNodeIntFunc_constant_FUNC_CLAMP:
- .. _class_VisualShaderNodeIntFunc_constant_FUNC_NEGATE:
- .. _class_VisualShaderNodeIntFunc_constant_FUNC_SIGN:
- enum **Function**:
- - **FUNC_ABS** = **0** --- Returns the absolute value of the parameter. Translates to ``abs(x)`` in the Godot Shader Language.
- - **FUNC_CLAMP** = **1** --- Constrains a parameter between ``min`` and ``max``. Translates to ``clamp(x, min, max)`` in the Godot Shader Language.
- - **FUNC_NEGATE** = **2** --- Negates the ``x`` using ``-(x)``.
- - **FUNC_SIGN** = **3** --- Extracts the sign of the parameter. Translates to ``sign(x)`` in the Godot Shader Language.
- Property Descriptions
- ---------------------
- .. _class_VisualShaderNodeIntFunc_property_function:
- - :ref:`Function<enum_VisualShaderNodeIntFunc_Function>` **function**
- +-----------+---------------------+
- | *Default* | ``3`` |
- +-----------+---------------------+
- | *Setter* | set_function(value) |
- +-----------+---------------------+
- | *Getter* | get_function() |
- +-----------+---------------------+
- A function to be applied to the scalar. See :ref:`Function<enum_VisualShaderNodeIntFunc_Function>` for options.
|