class_colorarray.rst 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. .. Generated automatically by doc/tools/makerst.py in Godot's source tree.
  2. .. DO NOT EDIT THIS FILE, but the doc/base/classes.xml source instead.
  3. .. _class_ColorArray:
  4. ColorArray
  5. ==========
  6. **Category:** Built-In Types
  7. Brief Description
  8. -----------------
  9. Array of Colors
  10. Member Functions
  11. ----------------
  12. +--------------------------------------+-----------------------------------------------------------------------------------------------------------+
  13. | void | :ref:`push_back<class_ColorArray_push_back>` **(** :ref:`Color<class_color>` color **)** |
  14. +--------------------------------------+-----------------------------------------------------------------------------------------------------------+
  15. | void | :ref:`resize<class_ColorArray_resize>` **(** :ref:`int<class_int>` idx **)** |
  16. +--------------------------------------+-----------------------------------------------------------------------------------------------------------+
  17. | void | :ref:`set<class_ColorArray_set>` **(** :ref:`int<class_int>` idx, :ref:`Color<class_color>` color **)** |
  18. +--------------------------------------+-----------------------------------------------------------------------------------------------------------+
  19. | :ref:`int<class_int>` | :ref:`size<class_ColorArray_size>` **(** **)** |
  20. +--------------------------------------+-----------------------------------------------------------------------------------------------------------+
  21. | :ref:`ColorArray<class_colorarray>` | :ref:`ColorArray<class_ColorArray_ColorArray>` **(** :ref:`Array<class_array>` from **)** |
  22. +--------------------------------------+-----------------------------------------------------------------------------------------------------------+
  23. Description
  24. -----------
  25. Array of Color, can only contains colors. Optimized for memory usage, can't fragment the memory.
  26. Member Function Description
  27. ---------------------------
  28. .. _class_ColorArray_push_back:
  29. - void **push_back** **(** :ref:`Color<class_color>` color **)**
  30. Append a value to the array.
  31. .. _class_ColorArray_resize:
  32. - void **resize** **(** :ref:`int<class_int>` idx **)**
  33. Resize the array.
  34. .. _class_ColorArray_set:
  35. - void **set** **(** :ref:`int<class_int>` idx, :ref:`Color<class_color>` color **)**
  36. Set an index in the array.
  37. .. _class_ColorArray_size:
  38. - :ref:`int<class_int>` **size** **(** **)**
  39. Return the array size.
  40. .. _class_ColorArray_ColorArray:
  41. - :ref:`ColorArray<class_colorarray>` **ColorArray** **(** :ref:`Array<class_array>` from **)**
  42. Create from a generic array.