class_visualinstance.rst 4.6 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. .. Generated automatically by doc/tools/makerst.py in Godot's source tree.
  2. .. DO NOT EDIT THIS FILE, but the VisualInstance.xml source instead.
  3. .. The source is found in doc/classes or modules/<name>/doc_classes.
  4. .. _class_VisualInstance:
  5. VisualInstance
  6. ==============
  7. **Inherits:** :ref:`Spatial<class_Spatial>` **<** :ref:`Node<class_Node>` **<** :ref:`Object<class_Object>`
  8. **Inherited By:** :ref:`BakedLightmap<class_BakedLightmap>`, :ref:`CSGShape<class_CSGShape>`, :ref:`GIProbe<class_GIProbe>`, :ref:`GeometryInstance<class_GeometryInstance>`, :ref:`Light<class_Light>`, :ref:`ReflectionProbe<class_ReflectionProbe>`, :ref:`RootMotionView<class_RootMotionView>`
  9. **Category:** Core
  10. Brief Description
  11. -----------------
  12. Properties
  13. ----------
  14. +-----------------------+-----------------------------------------------------+
  15. | :ref:`int<class_int>` | :ref:`layers<class_VisualInstance_property_layers>` |
  16. +-----------------------+-----------------------------------------------------+
  17. Methods
  18. -------
  19. +-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------+
  20. | :ref:`AABB<class_AABB>` | :ref:`get_aabb<class_VisualInstance_method_get_aabb>` **(** **)** const |
  21. +-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------+
  22. | :ref:`bool<class_bool>` | :ref:`get_layer_mask_bit<class_VisualInstance_method_get_layer_mask_bit>` **(** :ref:`int<class_int>` layer **)** const |
  23. +-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------+
  24. | :ref:`AABB<class_AABB>` | :ref:`get_transformed_aabb<class_VisualInstance_method_get_transformed_aabb>` **(** **)** const |
  25. +-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------+
  26. | void | :ref:`set_base<class_VisualInstance_method_set_base>` **(** :ref:`RID<class_RID>` base **)** |
  27. +-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------+
  28. | void | :ref:`set_layer_mask_bit<class_VisualInstance_method_set_layer_mask_bit>` **(** :ref:`int<class_int>` layer, :ref:`bool<class_bool>` enabled **)** |
  29. +-------------------------+----------------------------------------------------------------------------------------------------------------------------------------------------+
  30. Property Descriptions
  31. ---------------------
  32. .. _class_VisualInstance_property_layers:
  33. - :ref:`int<class_int>` **layers**
  34. +----------+-----------------------+
  35. | *Setter* | set_layer_mask(value) |
  36. +----------+-----------------------+
  37. | *Getter* | get_layer_mask() |
  38. +----------+-----------------------+
  39. The render layer(s) this VisualInstance is drawn on.
  40. This object will only be visible for :ref:`Camera<class_Camera>`\ s whose cull mask includes the render object this VisualInstance is set to.
  41. Method Descriptions
  42. -------------------
  43. .. _class_VisualInstance_method_get_aabb:
  44. - :ref:`AABB<class_AABB>` **get_aabb** **(** **)** const
  45. Returns the :ref:`AABB<class_AABB>` (also known as the bounding box) for this VisualInstance.
  46. .. _class_VisualInstance_method_get_layer_mask_bit:
  47. - :ref:`bool<class_bool>` **get_layer_mask_bit** **(** :ref:`int<class_int>` layer **)** const
  48. .. _class_VisualInstance_method_get_transformed_aabb:
  49. - :ref:`AABB<class_AABB>` **get_transformed_aabb** **(** **)** const
  50. Returns the transformed :ref:`AABB<class_AABB>` (also known as the bounding box) for this VisualInstance.
  51. Transformed in this case means the :ref:`AABB<class_AABB>` plus the position, rotation, and scale of the :ref:`Spatial<class_Spatial>`\ s :ref:`Transform<class_Transform>`
  52. .. _class_VisualInstance_method_set_base:
  53. - void **set_base** **(** :ref:`RID<class_RID>` base **)**
  54. Sets the base of the VisualInstance, which changes how the engine handles the VisualInstance under the hood.
  55. It is recommended to only use set_base if you know what you're doing.
  56. .. _class_VisualInstance_method_set_layer_mask_bit:
  57. - void **set_layer_mask_bit** **(** :ref:`int<class_int>` layer, :ref:`bool<class_bool>` enabled **)**