21 #include "../../gfx.h"
23 #if GFX_USE_GAUDIO || defined(__DOXYGEN__)
27 #include "gaudio_play_config.h"
29 #if GAUDIO_NEED_RECORD
30 #include "gaudio_record_config.h"
38 #define GEVENT_AUDIO_PLAY (GEVENT_GAUDIO_FIRST+0)
39 #define GEVENT_AUDIO_RECORD (GEVENT_GAUDIO_FIRST+1)
41 #if GFX_USE_GEVENT || defined(__DOXYGEN__)
59 #define GAUDIO_PLAY_LOSTEVENT 0x0001
60 #define GAUDIO_PLAY_PLAYING 0x0002
61 #define GAUDIO_PLAY_FREEBLOCK 0x0004
83 #define GAUDIO_RECORD_LOSTEVENT 0x0001
84 #define GAUDIO_RECORD_RECORDING 0x0002
85 #define GAUDIO_RECORD_GOTBUFFER 0x0004
86 #define GAUDIO_RECORD_STALL 0x0008
96 #if GAUDIO_NEED_PLAY || defined(__DOXYGEN__)
169 #if GFX_USE_GEVENT || defined(__DOXYGEN__)
199 #if GAUDIO_NEED_RECORD || defined(__DOXYGEN__)
265 #if GFX_USE_GEVENT || defined(__DOXYGEN__)
void gaudioPlayStop(void)
Stop any currently playing sounds.
GSourceHandle gaudioPlayGetSource(void)
Turn on sending results to the GEVENT sub-system.
void gaudioRecordStart(void)
Start the audio recording.
struct GEventAudioRecord_t GEventAudioRecord
The Audio record event structure.
gBool gaudioPlaySetVolume(gU8 vol)
Set the output volume.
GDataBuffer * gaudioRecordGetData(gDelay ms)
Get a filled audio buffer from the recording list.
void gaudioRecordStop(void)
Stop the audio recording.
gBool gaudioPlayInit(gU16 channel, gU32 frequency, ArrayDataFormat format)
Set the audio device to play on the specified channel and with the specified sample frequency.
struct GEventAudioPlay_t GEventAudioPlay
The Audio play event structure.
gBool gaudioRecordInit(gU16 channel, gU32 frequency, ArrayDataFormat format)
Initialise (but not start) the Audio Recording sub-system.
void gaudioPlayPause(void)
Pause any currently playing sounds.
void gaudioPlay(GDataBuffer *paud)
Play the specified sample data.
GSourceHandle gaudioRecordGetSource(void)
Turn on sending results to the GEVENT sub-system.
gBool gaudioPlayWait(gDelay ms)
Wait for any currently playing sounds to complete.
enum ArrayDataFormat_e ArrayDataFormat
Sample data formats.
The Audio play event structure.
gU16 flags
The event flags.
GEventType type
The type of this event (GEVENT_AUDIO_PLAY)
The Audio record event structure.
gU16 flags
The event flags.
GEventType type
The type of this event (GEVENT_AUDIO_RECORD)