class_performance.rst 22 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510
  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/Performance.xml.
  6. .. _class_Performance:
  7. Performance
  8. ===========
  9. **Inherits:** :ref:`Object<class_Object>`
  10. Exposes performance-related data.
  11. .. rst-class:: classref-introduction-group
  12. Description
  13. -----------
  14. This class provides access to a number of different monitors related to performance, such as memory usage, draw calls, and FPS. These are the same as the values displayed in the **Monitor** tab in the editor's **Debugger** panel. By using the :ref:`get_monitor<class_Performance_method_get_monitor>` method of this class, you can access this data from your code.
  15. You can add custom monitors using the :ref:`add_custom_monitor<class_Performance_method_add_custom_monitor>` method. Custom monitors are available in **Monitor** tab in the editor's **Debugger** panel together with built-in monitors.
  16. \ **Note:** Some of the built-in monitors are only available in debug mode and will always return ``0`` when used in a project exported in release mode.
  17. \ **Note:** Some of the built-in monitors are not updated in real-time for performance reasons, so there may be a delay of up to 1 second between changes.
  18. \ **Note:** Custom monitors do not support negative values. Negative values are clamped to 0.
  19. .. rst-class:: classref-reftable-group
  20. Methods
  21. -------
  22. .. table::
  23. :widths: auto
  24. +---------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  25. | void | :ref:`add_custom_monitor<class_Performance_method_add_custom_monitor>` **(** :ref:`StringName<class_StringName>` id, :ref:`Callable<class_Callable>` callable, :ref:`Array<class_Array>` arguments=[] **)** |
  26. +---------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  27. | :ref:`Variant<class_Variant>` | :ref:`get_custom_monitor<class_Performance_method_get_custom_monitor>` **(** :ref:`StringName<class_StringName>` id **)** |
  28. +---------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  29. | :ref:`StringName[]<class_StringName>` | :ref:`get_custom_monitor_names<class_Performance_method_get_custom_monitor_names>` **(** **)** |
  30. +---------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  31. | :ref:`float<class_float>` | :ref:`get_monitor<class_Performance_method_get_monitor>` **(** :ref:`Monitor<enum_Performance_Monitor>` monitor **)** |const| |
  32. +---------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  33. | :ref:`int<class_int>` | :ref:`get_monitor_modification_time<class_Performance_method_get_monitor_modification_time>` **(** **)** |
  34. +---------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  35. | :ref:`bool<class_bool>` | :ref:`has_custom_monitor<class_Performance_method_has_custom_monitor>` **(** :ref:`StringName<class_StringName>` id **)** |
  36. +---------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  37. | void | :ref:`remove_custom_monitor<class_Performance_method_remove_custom_monitor>` **(** :ref:`StringName<class_StringName>` id **)** |
  38. +---------------------------------------+-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
  39. .. rst-class:: classref-section-separator
  40. ----
  41. .. rst-class:: classref-descriptions-group
  42. Enumerations
  43. ------------
  44. .. _enum_Performance_Monitor:
  45. .. rst-class:: classref-enumeration
  46. enum **Monitor**:
  47. .. _class_Performance_constant_TIME_FPS:
  48. .. rst-class:: classref-enumeration-constant
  49. :ref:`Monitor<enum_Performance_Monitor>` **TIME_FPS** = ``0``
  50. The number of frames rendered in the last second. This metric is only updated once per second, even if queried more often. *Higher is better.*
  51. .. _class_Performance_constant_TIME_PROCESS:
  52. .. rst-class:: classref-enumeration-constant
  53. :ref:`Monitor<enum_Performance_Monitor>` **TIME_PROCESS** = ``1``
  54. Time it took to complete one frame, in seconds. *Lower is better.*
  55. .. _class_Performance_constant_TIME_PHYSICS_PROCESS:
  56. .. rst-class:: classref-enumeration-constant
  57. :ref:`Monitor<enum_Performance_Monitor>` **TIME_PHYSICS_PROCESS** = ``2``
  58. Time it took to complete one physics frame, in seconds. *Lower is better.*
  59. .. _class_Performance_constant_TIME_NAVIGATION_PROCESS:
  60. .. rst-class:: classref-enumeration-constant
  61. :ref:`Monitor<enum_Performance_Monitor>` **TIME_NAVIGATION_PROCESS** = ``3``
  62. Time it took to complete one navigation step, in seconds. This includes navigation map updates as well as agent avoidance calculations. *Lower is better.*
  63. .. _class_Performance_constant_MEMORY_STATIC:
  64. .. rst-class:: classref-enumeration-constant
  65. :ref:`Monitor<enum_Performance_Monitor>` **MEMORY_STATIC** = ``4``
  66. Static memory currently used, in bytes. Not available in release builds. *Lower is better.*
  67. .. _class_Performance_constant_MEMORY_STATIC_MAX:
  68. .. rst-class:: classref-enumeration-constant
  69. :ref:`Monitor<enum_Performance_Monitor>` **MEMORY_STATIC_MAX** = ``5``
  70. Available static memory. Not available in release builds. *Lower is better.*
  71. .. _class_Performance_constant_MEMORY_MESSAGE_BUFFER_MAX:
  72. .. rst-class:: classref-enumeration-constant
  73. :ref:`Monitor<enum_Performance_Monitor>` **MEMORY_MESSAGE_BUFFER_MAX** = ``6``
  74. Largest amount of memory the message queue buffer has used, in bytes. The message queue is used for deferred functions calls and notifications. *Lower is better.*
  75. .. _class_Performance_constant_OBJECT_COUNT:
  76. .. rst-class:: classref-enumeration-constant
  77. :ref:`Monitor<enum_Performance_Monitor>` **OBJECT_COUNT** = ``7``
  78. Number of objects currently instantiated (including nodes). *Lower is better.*
  79. .. _class_Performance_constant_OBJECT_RESOURCE_COUNT:
  80. .. rst-class:: classref-enumeration-constant
  81. :ref:`Monitor<enum_Performance_Monitor>` **OBJECT_RESOURCE_COUNT** = ``8``
  82. Number of resources currently used. *Lower is better.*
  83. .. _class_Performance_constant_OBJECT_NODE_COUNT:
  84. .. rst-class:: classref-enumeration-constant
  85. :ref:`Monitor<enum_Performance_Monitor>` **OBJECT_NODE_COUNT** = ``9``
  86. Number of nodes currently instantiated in the scene tree. This also includes the root node. *Lower is better.*
  87. .. _class_Performance_constant_OBJECT_ORPHAN_NODE_COUNT:
  88. .. rst-class:: classref-enumeration-constant
  89. :ref:`Monitor<enum_Performance_Monitor>` **OBJECT_ORPHAN_NODE_COUNT** = ``10``
  90. Number of orphan nodes, i.e. nodes which are not parented to a node of the scene tree. *Lower is better.*
  91. .. _class_Performance_constant_RENDER_TOTAL_OBJECTS_IN_FRAME:
  92. .. rst-class:: classref-enumeration-constant
  93. :ref:`Monitor<enum_Performance_Monitor>` **RENDER_TOTAL_OBJECTS_IN_FRAME** = ``11``
  94. The total number of objects in the last rendered frame. This metric doesn't include culled objects (either via hiding nodes, frustum culling or occlusion culling). *Lower is better.*
  95. .. _class_Performance_constant_RENDER_TOTAL_PRIMITIVES_IN_FRAME:
  96. .. rst-class:: classref-enumeration-constant
  97. :ref:`Monitor<enum_Performance_Monitor>` **RENDER_TOTAL_PRIMITIVES_IN_FRAME** = ``12``
  98. The total number of vertices or indices rendered in the last rendered frame. This metric doesn't include primitives from culled objects (either via hiding nodes, frustum culling or occlusion culling). Due to the depth prepass and shadow passes, the number of primitives is always higher than the actual number of vertices in the scene (typically double or triple the original vertex count). *Lower is better.*
  99. .. _class_Performance_constant_RENDER_TOTAL_DRAW_CALLS_IN_FRAME:
  100. .. rst-class:: classref-enumeration-constant
  101. :ref:`Monitor<enum_Performance_Monitor>` **RENDER_TOTAL_DRAW_CALLS_IN_FRAME** = ``13``
  102. The total number of draw calls performed in the last rendered frame. This metric doesn't include culled objects (either via hiding nodes, frustum culling or occlusion culling), since they do not result in draw calls. *Lower is better.*
  103. .. _class_Performance_constant_RENDER_VIDEO_MEM_USED:
  104. .. rst-class:: classref-enumeration-constant
  105. :ref:`Monitor<enum_Performance_Monitor>` **RENDER_VIDEO_MEM_USED** = ``14``
  106. The amount of video memory used (texture and vertex memory combined, in bytes). Since this metric also includes miscellaneous allocations, this value is always greater than the sum of :ref:`RENDER_TEXTURE_MEM_USED<class_Performance_constant_RENDER_TEXTURE_MEM_USED>` and :ref:`RENDER_BUFFER_MEM_USED<class_Performance_constant_RENDER_BUFFER_MEM_USED>`. *Lower is better.*
  107. .. _class_Performance_constant_RENDER_TEXTURE_MEM_USED:
  108. .. rst-class:: classref-enumeration-constant
  109. :ref:`Monitor<enum_Performance_Monitor>` **RENDER_TEXTURE_MEM_USED** = ``15``
  110. The amount of texture memory used (in bytes). *Lower is better.*
  111. .. _class_Performance_constant_RENDER_BUFFER_MEM_USED:
  112. .. rst-class:: classref-enumeration-constant
  113. :ref:`Monitor<enum_Performance_Monitor>` **RENDER_BUFFER_MEM_USED** = ``16``
  114. The amount of render buffer memory used (in bytes). *Lower is better.*
  115. .. _class_Performance_constant_PHYSICS_2D_ACTIVE_OBJECTS:
  116. .. rst-class:: classref-enumeration-constant
  117. :ref:`Monitor<enum_Performance_Monitor>` **PHYSICS_2D_ACTIVE_OBJECTS** = ``17``
  118. Number of active :ref:`RigidBody2D<class_RigidBody2D>` nodes in the game. *Lower is better.*
  119. .. _class_Performance_constant_PHYSICS_2D_COLLISION_PAIRS:
  120. .. rst-class:: classref-enumeration-constant
  121. :ref:`Monitor<enum_Performance_Monitor>` **PHYSICS_2D_COLLISION_PAIRS** = ``18``
  122. Number of collision pairs in the 2D physics engine. *Lower is better.*
  123. .. _class_Performance_constant_PHYSICS_2D_ISLAND_COUNT:
  124. .. rst-class:: classref-enumeration-constant
  125. :ref:`Monitor<enum_Performance_Monitor>` **PHYSICS_2D_ISLAND_COUNT** = ``19``
  126. Number of islands in the 2D physics engine. *Lower is better.*
  127. .. _class_Performance_constant_PHYSICS_3D_ACTIVE_OBJECTS:
  128. .. rst-class:: classref-enumeration-constant
  129. :ref:`Monitor<enum_Performance_Monitor>` **PHYSICS_3D_ACTIVE_OBJECTS** = ``20``
  130. Number of active :ref:`RigidBody3D<class_RigidBody3D>` and :ref:`VehicleBody3D<class_VehicleBody3D>` nodes in the game. *Lower is better.*
  131. .. _class_Performance_constant_PHYSICS_3D_COLLISION_PAIRS:
  132. .. rst-class:: classref-enumeration-constant
  133. :ref:`Monitor<enum_Performance_Monitor>` **PHYSICS_3D_COLLISION_PAIRS** = ``21``
  134. Number of collision pairs in the 3D physics engine. *Lower is better.*
  135. .. _class_Performance_constant_PHYSICS_3D_ISLAND_COUNT:
  136. .. rst-class:: classref-enumeration-constant
  137. :ref:`Monitor<enum_Performance_Monitor>` **PHYSICS_3D_ISLAND_COUNT** = ``22``
  138. Number of islands in the 3D physics engine. *Lower is better.*
  139. .. _class_Performance_constant_AUDIO_OUTPUT_LATENCY:
  140. .. rst-class:: classref-enumeration-constant
  141. :ref:`Monitor<enum_Performance_Monitor>` **AUDIO_OUTPUT_LATENCY** = ``23``
  142. Output latency of the :ref:`AudioServer<class_AudioServer>`. Equivalent to calling :ref:`AudioServer.get_output_latency<class_AudioServer_method_get_output_latency>`, it is not recommended to call this every frame.
  143. .. _class_Performance_constant_NAVIGATION_ACTIVE_MAPS:
  144. .. rst-class:: classref-enumeration-constant
  145. :ref:`Monitor<enum_Performance_Monitor>` **NAVIGATION_ACTIVE_MAPS** = ``24``
  146. Number of active navigation maps in the :ref:`NavigationServer3D<class_NavigationServer3D>`. This also includes the two empty default navigation maps created by World2D and World3D.
  147. .. _class_Performance_constant_NAVIGATION_REGION_COUNT:
  148. .. rst-class:: classref-enumeration-constant
  149. :ref:`Monitor<enum_Performance_Monitor>` **NAVIGATION_REGION_COUNT** = ``25``
  150. Number of active navigation regions in the :ref:`NavigationServer3D<class_NavigationServer3D>`.
  151. .. _class_Performance_constant_NAVIGATION_AGENT_COUNT:
  152. .. rst-class:: classref-enumeration-constant
  153. :ref:`Monitor<enum_Performance_Monitor>` **NAVIGATION_AGENT_COUNT** = ``26``
  154. Number of active navigation agents processing avoidance in the :ref:`NavigationServer3D<class_NavigationServer3D>`.
  155. .. _class_Performance_constant_NAVIGATION_LINK_COUNT:
  156. .. rst-class:: classref-enumeration-constant
  157. :ref:`Monitor<enum_Performance_Monitor>` **NAVIGATION_LINK_COUNT** = ``27``
  158. Number of active navigation links in the :ref:`NavigationServer3D<class_NavigationServer3D>`.
  159. .. _class_Performance_constant_NAVIGATION_POLYGON_COUNT:
  160. .. rst-class:: classref-enumeration-constant
  161. :ref:`Monitor<enum_Performance_Monitor>` **NAVIGATION_POLYGON_COUNT** = ``28``
  162. Number of navigation mesh polygons in the :ref:`NavigationServer3D<class_NavigationServer3D>`.
  163. .. _class_Performance_constant_NAVIGATION_EDGE_COUNT:
  164. .. rst-class:: classref-enumeration-constant
  165. :ref:`Monitor<enum_Performance_Monitor>` **NAVIGATION_EDGE_COUNT** = ``29``
  166. Number of navigation mesh polygon edges in the :ref:`NavigationServer3D<class_NavigationServer3D>`.
  167. .. _class_Performance_constant_NAVIGATION_EDGE_MERGE_COUNT:
  168. .. rst-class:: classref-enumeration-constant
  169. :ref:`Monitor<enum_Performance_Monitor>` **NAVIGATION_EDGE_MERGE_COUNT** = ``30``
  170. Number of navigation mesh polygon edges that were merged due to edge key overlap in the :ref:`NavigationServer3D<class_NavigationServer3D>`.
  171. .. _class_Performance_constant_NAVIGATION_EDGE_CONNECTION_COUNT:
  172. .. rst-class:: classref-enumeration-constant
  173. :ref:`Monitor<enum_Performance_Monitor>` **NAVIGATION_EDGE_CONNECTION_COUNT** = ``31``
  174. Number of polygon edges that are considered connected by edge proximity :ref:`NavigationServer3D<class_NavigationServer3D>`.
  175. .. _class_Performance_constant_NAVIGATION_EDGE_FREE_COUNT:
  176. .. rst-class:: classref-enumeration-constant
  177. :ref:`Monitor<enum_Performance_Monitor>` **NAVIGATION_EDGE_FREE_COUNT** = ``32``
  178. Number of navigation mesh polygon edges that could not be merged in the :ref:`NavigationServer3D<class_NavigationServer3D>`. The edges still may be connected by edge proximity or with links.
  179. .. _class_Performance_constant_MONITOR_MAX:
  180. .. rst-class:: classref-enumeration-constant
  181. :ref:`Monitor<enum_Performance_Monitor>` **MONITOR_MAX** = ``33``
  182. Represents the size of the :ref:`Monitor<enum_Performance_Monitor>` enum.
  183. .. rst-class:: classref-section-separator
  184. ----
  185. .. rst-class:: classref-descriptions-group
  186. Method Descriptions
  187. -------------------
  188. .. _class_Performance_method_add_custom_monitor:
  189. .. rst-class:: classref-method
  190. void **add_custom_monitor** **(** :ref:`StringName<class_StringName>` id, :ref:`Callable<class_Callable>` callable, :ref:`Array<class_Array>` arguments=[] **)**
  191. Adds a custom monitor with the name ``id``. You can specify the category of the monitor using slash delimiters in ``id`` (for example: ``"Game/NumberOfNPCs"``). If there is more than one slash delimiter, then the default category is used. The default category is ``"Custom"``. Prints an error if given ``id`` is already present.
  192. .. tabs::
  193. .. code-tab:: gdscript
  194. func _ready():
  195. var monitor_value = Callable(self, "get_monitor_value")
  196. # Adds monitor with name "MyName" to category "MyCategory".
  197. Performance.add_custom_monitor("MyCategory/MyMonitor", monitor_value)
  198. # Adds monitor with name "MyName" to category "Custom".
  199. # Note: "MyCategory/MyMonitor" and "MyMonitor" have same name but different IDs, so the code is valid.
  200. Performance.add_custom_monitor("MyMonitor", monitor_value)
  201. # Adds monitor with name "MyName" to category "Custom".
  202. # Note: "MyMonitor" and "Custom/MyMonitor" have same name and same category but different IDs, so the code is valid.
  203. Performance.add_custom_monitor("Custom/MyMonitor", monitor_value)
  204. # Adds monitor with name "MyCategoryOne/MyCategoryTwo/MyMonitor" to category "Custom".
  205. Performance.add_custom_monitor("MyCategoryOne/MyCategoryTwo/MyMonitor", monitor_value)
  206. func get_monitor_value():
  207. return randi() % 25
  208. .. code-tab:: csharp
  209. public override void _Ready()
  210. {
  211. var monitorValue = new Callable(this, MethodName.GetMonitorValue);
  212. // Adds monitor with name "MyName" to category "MyCategory".
  213. Performance.AddCustomMonitor("MyCategory/MyMonitor", monitorValue);
  214. // Adds monitor with name "MyName" to category "Custom".
  215. // Note: "MyCategory/MyMonitor" and "MyMonitor" have same name but different ids so the code is valid.
  216. Performance.AddCustomMonitor("MyMonitor", monitorValue);
  217. // Adds monitor with name "MyName" to category "Custom".
  218. // Note: "MyMonitor" and "Custom/MyMonitor" have same name and same category but different ids so the code is valid.
  219. Performance.AddCustomMonitor("Custom/MyMonitor", monitorValue);
  220. // Adds monitor with name "MyCategoryOne/MyCategoryTwo/MyMonitor" to category "Custom".
  221. Performance.AddCustomMonitor("MyCategoryOne/MyCategoryTwo/MyMonitor", monitorValue);
  222. }
  223. public int GetMonitorValue()
  224. {
  225. return GD.Randi() % 25;
  226. }
  227. The debugger calls the callable to get the value of custom monitor. The callable must return a zero or positive integer or floating-point number.
  228. Callables are called with arguments supplied in argument array.
  229. .. rst-class:: classref-item-separator
  230. ----
  231. .. _class_Performance_method_get_custom_monitor:
  232. .. rst-class:: classref-method
  233. :ref:`Variant<class_Variant>` **get_custom_monitor** **(** :ref:`StringName<class_StringName>` id **)**
  234. Returns the value of custom monitor with given ``id``. The callable is called to get the value of custom monitor. See also :ref:`has_custom_monitor<class_Performance_method_has_custom_monitor>`. Prints an error if the given ``id`` is absent.
  235. .. rst-class:: classref-item-separator
  236. ----
  237. .. _class_Performance_method_get_custom_monitor_names:
  238. .. rst-class:: classref-method
  239. :ref:`StringName[]<class_StringName>` **get_custom_monitor_names** **(** **)**
  240. Returns the names of active custom monitors in an :ref:`Array<class_Array>`.
  241. .. rst-class:: classref-item-separator
  242. ----
  243. .. _class_Performance_method_get_monitor:
  244. .. rst-class:: classref-method
  245. :ref:`float<class_float>` **get_monitor** **(** :ref:`Monitor<enum_Performance_Monitor>` monitor **)** |const|
  246. Returns the value of one of the available built-in monitors. You should provide one of the :ref:`Monitor<enum_Performance_Monitor>` constants as the argument, like this:
  247. .. tabs::
  248. .. code-tab:: gdscript
  249. print(Performance.get_monitor(Performance.TIME_FPS)) # Prints the FPS to the console.
  250. .. code-tab:: csharp
  251. GD.Print(Performance.GetMonitor(Performance.Monitor.TimeFps)); // Prints the FPS to the console.
  252. See :ref:`get_custom_monitor<class_Performance_method_get_custom_monitor>` to query custom performance monitors' values.
  253. .. rst-class:: classref-item-separator
  254. ----
  255. .. _class_Performance_method_get_monitor_modification_time:
  256. .. rst-class:: classref-method
  257. :ref:`int<class_int>` **get_monitor_modification_time** **(** **)**
  258. Returns the last tick in which custom monitor was added/removed (in microseconds since the engine started). This is set to :ref:`Time.get_ticks_usec<class_Time_method_get_ticks_usec>` when the monitor is updated.
  259. .. rst-class:: classref-item-separator
  260. ----
  261. .. _class_Performance_method_has_custom_monitor:
  262. .. rst-class:: classref-method
  263. :ref:`bool<class_bool>` **has_custom_monitor** **(** :ref:`StringName<class_StringName>` id **)**
  264. Returns ``true`` if custom monitor with the given ``id`` is present, ``false`` otherwise.
  265. .. rst-class:: classref-item-separator
  266. ----
  267. .. _class_Performance_method_remove_custom_monitor:
  268. .. rst-class:: classref-method
  269. void **remove_custom_monitor** **(** :ref:`StringName<class_StringName>` id **)**
  270. Removes the custom monitor with given ``id``. Prints an error if the given ``id`` is already absent.
  271. .. |virtual| replace:: :abbr:`virtual (This method should typically be overridden by the user to have any effect.)`
  272. .. |const| replace:: :abbr:`const (This method has no side effects. It doesn't modify any of the instance's member variables.)`
  273. .. |vararg| replace:: :abbr:`vararg (This method accepts any number of arguments after the ones described here.)`
  274. .. |constructor| replace:: :abbr:`constructor (This method is used to construct a type.)`
  275. .. |static| replace:: :abbr:`static (This method doesn't need an instance to be called, so it can be called directly using the class name.)`
  276. .. |operator| replace:: :abbr:`operator (This method describes a valid operator to use with this type as left-hand operand.)`
  277. .. |bitfield| replace:: :abbr:`BitField (This value is an integer composed as a bitmask of the following flags.)`