class_audioeffectrecord.rst 3.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980
  1. :github_url: hide
  2. .. Generated automatically by doc/tools/makerst.py in Godot's source tree.
  3. .. DO NOT EDIT THIS FILE, but the AudioEffectRecord.xml source instead.
  4. .. The source is found in doc/classes or modules/<name>/doc_classes.
  5. .. _class_AudioEffectRecord:
  6. AudioEffectRecord
  7. =================
  8. **Inherits:** :ref:`AudioEffect<class_AudioEffect>` **<** :ref:`Resource<class_Resource>` **<** :ref:`Reference<class_Reference>` **<** :ref:`Object<class_Object>`
  9. Audio effect used for recording sound from a microphone.
  10. Tutorials
  11. ---------
  12. - :doc:`../tutorials/audio/recording_with_microphone`
  13. Properties
  14. ----------
  15. +----------------------------------------------+--------------------------------------------------------+-------+
  16. | :ref:`Format<enum_AudioStreamSample_Format>` | :ref:`format<class_AudioEffectRecord_property_format>` | ``1`` |
  17. +----------------------------------------------+--------------------------------------------------------+-------+
  18. Methods
  19. -------
  20. +---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------+
  21. | :ref:`AudioStreamSample<class_AudioStreamSample>` | :ref:`get_recording<class_AudioEffectRecord_method_get_recording>` **(** **)** const |
  22. +---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------+
  23. | :ref:`bool<class_bool>` | :ref:`is_recording_active<class_AudioEffectRecord_method_is_recording_active>` **(** **)** const |
  24. +---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------+
  25. | void | :ref:`set_recording_active<class_AudioEffectRecord_method_set_recording_active>` **(** :ref:`bool<class_bool>` record **)** |
  26. +---------------------------------------------------+-----------------------------------------------------------------------------------------------------------------------------+
  27. Property Descriptions
  28. ---------------------
  29. .. _class_AudioEffectRecord_property_format:
  30. - :ref:`Format<enum_AudioStreamSample_Format>` **format**
  31. +-----------+-------------------+
  32. | *Default* | ``1`` |
  33. +-----------+-------------------+
  34. | *Setter* | set_format(value) |
  35. +-----------+-------------------+
  36. | *Getter* | get_format() |
  37. +-----------+-------------------+
  38. Specifies the format in which the sample will be recorded. See :ref:`Format<enum_AudioStreamSample_Format>` for available formats.
  39. Method Descriptions
  40. -------------------
  41. .. _class_AudioEffectRecord_method_get_recording:
  42. - :ref:`AudioStreamSample<class_AudioStreamSample>` **get_recording** **(** **)** const
  43. Returns the recorded sample.
  44. ----
  45. .. _class_AudioEffectRecord_method_is_recording_active:
  46. - :ref:`bool<class_bool>` **is_recording_active** **(** **)** const
  47. Returns whether the recording is active or not.
  48. ----
  49. .. _class_AudioEffectRecord_method_set_recording_active:
  50. - void **set_recording_active** **(** :ref:`bool<class_bool>` record **)**
  51. If ``true``, the sound will be recorded. Note that restarting the recording will remove the previously recorded sample.