Skip to content

Commit 2408a9d

Browse files
committed
add audio capture functions
1 parent 1490927 commit 2408a9d

7 files changed

Lines changed: 129 additions & 1 deletion

File tree

source/scripting/api/index.rst

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -378,6 +378,10 @@ Functions related to audio.
378378
- Sets the master gain.
379379
* - :doc:`/types/Script/getMasterGain/index`
380380
- Returns the master gain.
381+
* - :doc:`/types/Script/startAudioInputCapture/index`
382+
- Starts audio input capture.
383+
* - :doc:`/types/Script/stopAudioInputCapture/index`
384+
- Ends audio input capture.
381385

382386
Animation
383387
---------

source/types/AudioModuleInterface/index.rst

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,6 +54,10 @@ Functions
5454
- Sets the master gain.
5555
* - :doc:`/types/AudioModuleInterface/getMasterGain/index`
5656
- Returns the master gain.
57+
* - :doc:`/types/AudioModuleInterface/startAudioInputCapture/index`
58+
- Starts audio input capture.
59+
* - :doc:`/types/AudioModuleInterface/stopAudioInputCapture/index`
60+
- Ends audio input capture.
5761

5862
.. toctree::
5963
:hidden:
@@ -77,4 +81,6 @@ Functions
7781
./setSoundSourceLooping/index.rst
7882
./isSoundSourceLooping/index.rst
7983
./setMasterGain/index.rst
80-
./getMasterGain/index.rst
84+
./getMasterGain/index.rst
85+
./startAudioInputCapture/index.rst
86+
./stopAudioInputCapture/index.rst
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
startAudioInputCapture
2+
======================
3+
4+
:doc:`/types/AudioModuleInterface/index`::startAudioInputCapture
5+
6+
Starts audio input capture.
7+
8+
Declaration
9+
-----------
10+
11+
.. code-block:: cpp
12+
13+
virtual void startAudioInputCapture() = 0;
14+
15+
Parameters
16+
----------
17+
18+
None.
19+
20+
Returns
21+
-------
22+
23+
None.
24+
25+
Notes
26+
-----
27+
28+
End the audio input capture with :doc:`/scripting/api/index`'s function :doc:`/types/Script/stopAudioInputCapture/index` or the :doc:`/module/audio_module/index`'s :doc:`/types/AudioModuleInterface/stopAudioInputCapture/index` function.
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
stopAudioInputCapture
2+
=====================
3+
4+
:doc:`/types/AudioModuleInterface/index`::stopAudioInputCapture
5+
6+
Ends audio input capture.
7+
8+
Declaration
9+
-----------
10+
11+
.. code-block:: cpp
12+
13+
virtual SoundID stopAudioInputCapture() = 0;
14+
15+
Parameters
16+
----------
17+
18+
None.
19+
20+
Returns
21+
-------
22+
23+
The :doc:`/types/SoundID` of the captured sound.
24+
25+
Notes
26+
-----
27+
28+
End the audio input capture started with :doc:`/scripting/api/index`'s function :doc:`/types/Script/startAudioInputCapture/index` or the :doc:`/module/audio_module/index`'s :doc:`/types/AudioModuleInterface/startAudioInputCapture/index` function.

source/types/Script/index.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -324,6 +324,10 @@ Functions
324324
- Sets the master gain.
325325
* - :doc:`/types/Script/getMasterGain/index`
326326
- Returns the master gain.
327+
* - :doc:`/types/Script/startAudioInputCapture/index`
328+
- Starts audio input capture.
329+
* - :doc:`/types/Script/stopAudioInputCapture/index`
330+
- Ends audio input capture.
327331
* - :doc:`/types/Script/playAnimation/index`
328332
- Plays an :doc:`/types/Animation/index` on an :doc:`/entity_component_system/entity/index`.
329333
* - :doc:`/types/Script/resumeAnimation/index`
@@ -535,6 +539,8 @@ Functions
535539
./isSoundSourceLooping/index.rst
536540
./setMasterGain/index.rst
537541
./getMasterGain/index.rst
542+
./startAudioInputCapture/index.rst
543+
./stopAudioInputCapture/index.rst
538544

539545
./intersect/index.rst
540546
./raycast/index.rst
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
startAudioInputCapture
2+
======================
3+
4+
:doc:`/types/Script/index`::startAudioInputCapture
5+
6+
Starts audio input capture.
7+
8+
Declaration
9+
-----------
10+
11+
.. code-block:: cpp
12+
13+
void startAudioInputCapture();
14+
15+
Parameters
16+
----------
17+
18+
None.
19+
20+
Returns
21+
-------
22+
23+
None.
24+
25+
Notes
26+
-----
27+
28+
End the audio input capture with :doc:`/scripting/api/index`'s function :doc:`/types/Script/stopAudioInputCapture/index` or the :doc:`/module/audio_module/index`'s :doc:`/types/AudioModuleInterface/stopAudioInputCapture/index` function.
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
stopAudioInputCapture
2+
=====================
3+
4+
:doc:`/types/Script/index`::stopAudioInputCapture
5+
6+
Ends audio input capture.
7+
8+
Declaration
9+
-----------
10+
11+
.. code-block:: cpp
12+
13+
SoundID stopAudioInputCapture();
14+
15+
Parameters
16+
----------
17+
18+
None.
19+
20+
Returns
21+
-------
22+
23+
The :doc:`/types/SoundID` of the captured sound.
24+
25+
Notes
26+
-----
27+
28+
End the audio input capture started with :doc:`/scripting/api/index`'s function :doc:`/types/Script/startAudioInputCapture/index` or the :doc:`/module/audio_module/index`'s :doc:`/types/AudioModuleInterface/startAudioInputCapture/index` function.

0 commit comments

Comments
 (0)