LargeTexture.xml 2.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. <?xml version="1.0" encoding="UTF-8" ?>
  2. <class name="LargeTexture" inherits="Texture" version="3.2">
  3. <brief_description>
  4. A [Texture] capable of storing many smaller textures with offsets.
  5. </brief_description>
  6. <description>
  7. A [Texture] capable of storing many smaller textures with offsets.
  8. You can dynamically add pieces ([Texture]s) to this [LargeTexture] using different offsets.
  9. </description>
  10. <tutorials>
  11. </tutorials>
  12. <methods>
  13. <method name="add_piece">
  14. <return type="int">
  15. </return>
  16. <argument index="0" name="ofs" type="Vector2">
  17. </argument>
  18. <argument index="1" name="texture" type="Texture">
  19. </argument>
  20. <description>
  21. Adds [code]texture[/code] to this [LargeTexture], starting on offset [code]ofs[/code].
  22. </description>
  23. </method>
  24. <method name="clear">
  25. <return type="void">
  26. </return>
  27. <description>
  28. Clears the [LargeTexture].
  29. </description>
  30. </method>
  31. <method name="get_piece_count" qualifiers="const">
  32. <return type="int">
  33. </return>
  34. <description>
  35. Returns the number of pieces currently in this [LargeTexture].
  36. </description>
  37. </method>
  38. <method name="get_piece_offset" qualifiers="const">
  39. <return type="Vector2">
  40. </return>
  41. <argument index="0" name="idx" type="int">
  42. </argument>
  43. <description>
  44. Returns the offset of the piece with the index [code]idx[/code].
  45. </description>
  46. </method>
  47. <method name="get_piece_texture" qualifiers="const">
  48. <return type="Texture">
  49. </return>
  50. <argument index="0" name="idx" type="int">
  51. </argument>
  52. <description>
  53. Returns the [Texture] of the piece with the index [code]idx[/code].
  54. </description>
  55. </method>
  56. <method name="set_piece_offset">
  57. <return type="void">
  58. </return>
  59. <argument index="0" name="idx" type="int">
  60. </argument>
  61. <argument index="1" name="ofs" type="Vector2">
  62. </argument>
  63. <description>
  64. Sets the offset of the piece with the index [code]idx[/code] to [code]ofs[/code].
  65. </description>
  66. </method>
  67. <method name="set_piece_texture">
  68. <return type="void">
  69. </return>
  70. <argument index="0" name="idx" type="int">
  71. </argument>
  72. <argument index="1" name="texture" type="Texture">
  73. </argument>
  74. <description>
  75. Sets the [Texture] of the piece with index [code]idx[/code] to [code]texture[/code].
  76. </description>
  77. </method>
  78. <method name="set_size">
  79. <return type="void">
  80. </return>
  81. <argument index="0" name="size" type="Vector2">
  82. </argument>
  83. <description>
  84. Sets the size of this [LargeTexture].
  85. </description>
  86. </method>
  87. </methods>
  88. <members>
  89. <member name="flags" type="int" setter="set_flags" getter="get_flags" override="true" default="0" />
  90. </members>
  91. <constants>
  92. </constants>
  93. </class>