2
0

VisualShaderNodeIntOp.xml 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <class name="VisualShaderNodeIntOp" inherits="VisualShaderNode" version="4.0">
  3. <brief_description>
  4. An integer scalar operator to be used within the visual shader graph.
  5. </brief_description>
  6. <description>
  7. Applies [member operator] to two integer inputs: [code]a[/code] and [code]b[/code].
  8. </description>
  9. <tutorials>
  10. </tutorials>
  11. <members>
  12. <member name="operator" type="int" setter="set_operator" getter="get_operator" enum="VisualShaderNodeIntOp.Operator" default="0">
  13. An operator to be applied to the inputs. See [enum Operator] for options.
  14. </member>
  15. </members>
  16. <constants>
  17. <constant name="OP_ADD" value="0" enum="Operator">
  18. Sums two numbers using [code]a + b[/code].
  19. </constant>
  20. <constant name="OP_SUB" value="1" enum="Operator">
  21. Subtracts two numbers using [code]a - b[/code].
  22. </constant>
  23. <constant name="OP_MUL" value="2" enum="Operator">
  24. Multiplies two numbers using [code]a * b[/code].
  25. </constant>
  26. <constant name="OP_DIV" value="3" enum="Operator">
  27. Divides two numbers using [code]a / b[/code].
  28. </constant>
  29. <constant name="OP_MOD" value="4" enum="Operator">
  30. Calculates the remainder of two numbers using [code]a % b[/code].
  31. </constant>
  32. <constant name="OP_MAX" value="5" enum="Operator">
  33. Returns the greater of two numbers. Translates to [code]max(a, b)[/code] in the Godot Shader Language.
  34. </constant>
  35. <constant name="OP_MIN" value="6" enum="Operator">
  36. Returns the lesser of two numbers. Translates to [code]max(a, b)[/code] in the Godot Shader Language.
  37. </constant>
  38. <constant name="OP_ENUM_SIZE" value="7" enum="Operator">
  39. Represents the size of the [enum Operator] enum.
  40. </constant>
  41. </constants>
  42. </class>