class_audiostreamsample.rst 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172
  1. .. Generated automatically by doc/tools/makerst.py in Godot's source tree.
  2. .. DO NOT EDIT THIS FILE, but the AudioStreamSample.xml source instead.
  3. .. The source is found in doc/classes or modules/<name>/doc_classes.
  4. .. _class_AudioStreamSample:
  5. AudioStreamSample
  6. =================
  7. **Inherits:** :ref:`AudioStream<class_audiostream>` **<** :ref:`Resource<class_resource>` **<** :ref:`Reference<class_reference>` **<** :ref:`Object<class_object>`
  8. **Category:** Core
  9. Brief Description
  10. -----------------
  11. Plays audio.
  12. Member Variables
  13. ----------------
  14. .. _class_AudioStreamSample_format:
  15. - :ref:`Format<enum_audiostreamsample_format>` **format** - Audio format. See FORMAT\_\* constants for values.
  16. .. _class_AudioStreamSample_loop_begin:
  17. - :ref:`int<class_int>` **loop_begin** - Loop start in bytes.
  18. .. _class_AudioStreamSample_loop_end:
  19. - :ref:`int<class_int>` **loop_end** - Loop end in bytes.
  20. .. _class_AudioStreamSample_loop_mode:
  21. - :ref:`LoopMode<enum_audiostreamsample_loopmode>` **loop_mode** - Loop mode. See LOOP\_\* constants for values.
  22. .. _class_AudioStreamSample_mix_rate:
  23. - :ref:`int<class_int>` **mix_rate** - The sample rate for mixing this audio.
  24. .. _class_AudioStreamSample_stereo:
  25. - :ref:`bool<class_bool>` **stereo** - If ``true``, audio is stereo. Default value: ``false``.
  26. Enums
  27. -----
  28. .. _enum_AudioStreamSample_LoopMode:
  29. enum **LoopMode**
  30. - **LOOP_DISABLED** = **0** --- Audio does not loop.
  31. - **LOOP_FORWARD** = **1** --- Audio loops the data between loop_begin and loop_end playing forward only.
  32. - **LOOP_PING_PONG** = **2** --- Audio loops the data between loop_begin and loop_end playing back and forth.
  33. .. _enum_AudioStreamSample_Format:
  34. enum **Format**
  35. - **FORMAT_8_BITS** = **0** --- Audio codec 8 bit.
  36. - **FORMAT_16_BITS** = **1** --- Audio codec 16 bit.
  37. - **FORMAT_IMA_ADPCM** = **2** --- Audio codec IMA ADPCM.
  38. Description
  39. -----------
  40. Plays audio, can loop.