class_visualshadernodeuvfunc.rst 3.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465
  1. :github_url: hide
  2. .. DO NOT EDIT THIS FILE!!!
  3. .. Generated automatically from Godot engine sources.
  4. .. Generator: https://github.com/godotengine/godot/tree/master/doc/tools/make_rst.py.
  5. .. XML source: https://github.com/godotengine/godot/tree/master/doc/classes/VisualShaderNodeUVFunc.xml.
  6. .. _class_VisualShaderNodeUVFunc:
  7. VisualShaderNodeUVFunc
  8. ======================
  9. **Inherits:** :ref:`VisualShaderNode<class_VisualShaderNode>` **<** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
  10. Contains functions to modify texture coordinates (``uv``) to be used within the visual shader graph.
  11. Properties
  12. ----------
  13. +-------------------------------------------------------+-----------------------------------------------------------------+-------+
  14. | :ref:`Function<enum_VisualShaderNodeUVFunc_Function>` | :ref:`function<class_VisualShaderNodeUVFunc_property_function>` | ``0`` |
  15. +-------------------------------------------------------+-----------------------------------------------------------------+-------+
  16. Enumerations
  17. ------------
  18. .. _enum_VisualShaderNodeUVFunc_Function:
  19. .. _class_VisualShaderNodeUVFunc_constant_FUNC_PANNING:
  20. .. _class_VisualShaderNodeUVFunc_constant_FUNC_SCALING:
  21. .. _class_VisualShaderNodeUVFunc_constant_FUNC_MAX:
  22. enum **Function**:
  23. - **FUNC_PANNING** = **0** --- Translates ``uv`` by using ``scale`` and ``offset`` values using the following formula: ``uv = uv + offset * scale``. ``uv`` port is connected to ``UV`` built-in by default.
  24. - **FUNC_SCALING** = **1** --- Scales ``uv[/uv] by using [code]scale`` and ``pivot`` values using the following formula: ``uv = (uv - pivot) * scale + pivot``. ``uv`` port is connected to ``UV`` built-in by default.
  25. - **FUNC_MAX** = **2** --- Represents the size of the :ref:`Function<enum_VisualShaderNodeUVFunc_Function>` enum.
  26. Property Descriptions
  27. ---------------------
  28. .. _class_VisualShaderNodeUVFunc_property_function:
  29. - :ref:`Function<enum_VisualShaderNodeUVFunc_Function>` **function**
  30. +-----------+---------------------+
  31. | *Default* | ``0`` |
  32. +-----------+---------------------+
  33. | *Setter* | set_function(value) |
  34. +-----------+---------------------+
  35. | *Getter* | get_function() |
  36. +-----------+---------------------+
  37. A function to be applied to the texture coordinates. See :ref:`Function<enum_VisualShaderNodeUVFunc_Function>` for options.
  38. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
  39. .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
  40. .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
  41. .. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)`
  42. .. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)`
  43. .. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)`