class_visualshadernodederivativefunc.rst 4.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113
  1. :github_url: hide
  2. .. Generated automatically by doc/tools/make_rst.py in Godot's source tree.
  3. .. DO NOT EDIT THIS FILE, but the VisualShaderNodeDerivativeFunc.xml source instead.
  4. .. The source is found in doc/classes or modules/<name>/doc_classes.
  5. .. _class_VisualShaderNodeDerivativeFunc:
  6. VisualShaderNodeDerivativeFunc
  7. ==============================
  8. **Inherits:** :ref:`VisualShaderNode<class_VisualShaderNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
  9. Calculates a derivative within the visual shader graph.
  10. Description
  11. -----------
  12. This node is only available in ``Fragment`` and ``Light`` visual shaders.
  13. Properties
  14. ----------
  15. +---------------------------------------------------------------+-------------------------------------------------------------------------+-------+
  16. | :ref:`Function<enum_VisualShaderNodeDerivativeFunc_Function>` | :ref:`function<class_VisualShaderNodeDerivativeFunc_property_function>` | ``0`` |
  17. +---------------------------------------------------------------+-------------------------------------------------------------------------+-------+
  18. | :ref:`OpType<enum_VisualShaderNodeDerivativeFunc_OpType>` | :ref:`op_type<class_VisualShaderNodeDerivativeFunc_property_op_type>` | ``0`` |
  19. +---------------------------------------------------------------+-------------------------------------------------------------------------+-------+
  20. Enumerations
  21. ------------
  22. .. _enum_VisualShaderNodeDerivativeFunc_OpType:
  23. .. _class_VisualShaderNodeDerivativeFunc_constant_OP_TYPE_SCALAR:
  24. .. _class_VisualShaderNodeDerivativeFunc_constant_OP_TYPE_VECTOR_2D:
  25. .. _class_VisualShaderNodeDerivativeFunc_constant_OP_TYPE_VECTOR_3D:
  26. .. _class_VisualShaderNodeDerivativeFunc_constant_OP_TYPE_MAX:
  27. enum **OpType**:
  28. - **OP_TYPE_SCALAR** = **0** --- A floating-point scalar.
  29. - **OP_TYPE_VECTOR_2D** = **1** --- A 2D vector type.
  30. - **OP_TYPE_VECTOR_3D** = **2** --- A 3D vector type.
  31. - **OP_TYPE_MAX** = **3** --- Represents the size of the :ref:`OpType<enum_VisualShaderNodeDerivativeFunc_OpType>` enum.
  32. ----
  33. .. _enum_VisualShaderNodeDerivativeFunc_Function:
  34. .. _class_VisualShaderNodeDerivativeFunc_constant_FUNC_SUM:
  35. .. _class_VisualShaderNodeDerivativeFunc_constant_FUNC_X:
  36. .. _class_VisualShaderNodeDerivativeFunc_constant_FUNC_Y:
  37. .. _class_VisualShaderNodeDerivativeFunc_constant_FUNC_MAX:
  38. enum **Function**:
  39. - **FUNC_SUM** = **0** --- Sum of absolute derivative in ``x`` and ``y``.
  40. - **FUNC_X** = **1** --- Derivative in ``x`` using local differencing.
  41. - **FUNC_Y** = **2** --- Derivative in ``y`` using local differencing.
  42. - **FUNC_MAX** = **3** --- Represents the size of the :ref:`Function<enum_VisualShaderNodeDerivativeFunc_Function>` enum.
  43. Property Descriptions
  44. ---------------------
  45. .. _class_VisualShaderNodeDerivativeFunc_property_function:
  46. - :ref:`Function<enum_VisualShaderNodeDerivativeFunc_Function>` **function**
  47. +-----------+---------------------+
  48. | *Default* | ``0`` |
  49. +-----------+---------------------+
  50. | *Setter* | set_function(value) |
  51. +-----------+---------------------+
  52. | *Getter* | get_function() |
  53. +-----------+---------------------+
  54. A derivative function type. See :ref:`Function<enum_VisualShaderNodeDerivativeFunc_Function>` for options.
  55. ----
  56. .. _class_VisualShaderNodeDerivativeFunc_property_op_type:
  57. - :ref:`OpType<enum_VisualShaderNodeDerivativeFunc_OpType>` **op_type**
  58. +-----------+--------------------+
  59. | *Default* | ``0`` |
  60. +-----------+--------------------+
  61. | *Setter* | set_op_type(value) |
  62. +-----------+--------------------+
  63. | *Getter* | get_op_type() |
  64. +-----------+--------------------+
  65. A type of operands and returned value. See :ref:`OpType<enum_VisualShaderNodeDerivativeFunc_OpType>` for options.
  66. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
  67. .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
  68. .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
  69. .. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)`
  70. .. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)`
  71. .. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)`