class_gradienttexture.rst 2.1 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859
  1. .. Generated automatically by doc/tools/makerst.py in Godot's source tree.
  2. .. DO NOT EDIT THIS FILE, but the GradientTexture.xml source instead.
  3. .. The source is found in doc/classes or modules/<name>/doc_classes.
  4. .. _class_GradientTexture:
  5. GradientTexture
  6. ===============
  7. **Inherits:** :ref:`Texture<class_Texture>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
  8. **Category:** Core
  9. Brief Description
  10. -----------------
  11. Gradient filled texture.
  12. Properties
  13. ----------
  14. +---------------------------------+----------------------------------------------------------+
  15. | :ref:`Gradient<class_Gradient>` | :ref:`gradient<class_GradientTexture_property_gradient>` |
  16. +---------------------------------+----------------------------------------------------------+
  17. | :ref:`int<class_int>` | :ref:`width<class_GradientTexture_property_width>` |
  18. +---------------------------------+----------------------------------------------------------+
  19. Description
  20. -----------
  21. Uses a :ref:`Gradient<class_Gradient>` to fill the texture data, the gradient will be filled from left to right using colors obtained from the gradient, this means that the texture does not necessarily represent an exact copy of the gradient, but instead an interpolation of samples obtained from the gradient at fixed steps (see :ref:`width<class_GradientTexture_property_width>`).
  22. Property Descriptions
  23. ---------------------
  24. .. _class_GradientTexture_property_gradient:
  25. - :ref:`Gradient<class_Gradient>` **gradient**
  26. +----------+---------------------+
  27. | *Setter* | set_gradient(value) |
  28. +----------+---------------------+
  29. | *Getter* | get_gradient() |
  30. +----------+---------------------+
  31. The :ref:`Gradient<class_Gradient>` that will be used to fill the texture.
  32. .. _class_GradientTexture_property_width:
  33. - :ref:`int<class_int>` **width**
  34. +----------+------------------+
  35. | *Setter* | set_width(value) |
  36. +----------+------------------+
  37. | *Getter* | get_width() |
  38. +----------+------------------+
  39. The number of color samples that will be obtained from the :ref:`Gradient<class_Gradient>`.