RetroArch
Macros | Typedefs | Enumerations | Functions
audio_mixer.h File Reference
#include <stdint.h>
#include <stddef.h>
#include <stdlib.h>
#include <boolean.h>
#include <retro_common_api.h>
Include dependency graph for audio_mixer.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define AUDIO_MIXER_SOUND_FINISHED   0
 
#define AUDIO_MIXER_SOUND_STOPPED   1
 
#define AUDIO_MIXER_SOUND_REPEATED   2
 

Typedefs

typedef struct audio_mixer_sound audio_mixer_sound_t
 
typedef struct audio_mixer_voice audio_mixer_voice_t
 
typedef void(* audio_mixer_stop_cb_t) (audio_mixer_sound_t *sound, unsigned reason)
 

Enumerations

enum  audio_mixer_type {
  AUDIO_MIXER_TYPE_NONE = 0, AUDIO_MIXER_TYPE_WAV, AUDIO_MIXER_TYPE_OGG, AUDIO_MIXER_TYPE_MOD,
  AUDIO_MIXER_TYPE_FLAC, AUDIO_MIXER_TYPE_MP3
}
 

Functions

void audio_mixer_init (unsigned rate)
 
void audio_mixer_done (void)
 
audio_mixer_sound_taudio_mixer_load_wav (void *buffer, int32_t size)
 
audio_mixer_sound_taudio_mixer_load_ogg (void *buffer, int32_t size)
 
audio_mixer_sound_taudio_mixer_load_mod (void *buffer, int32_t size)
 
audio_mixer_sound_taudio_mixer_load_flac (void *buffer, int32_t size)
 
audio_mixer_sound_taudio_mixer_load_mp3 (void *buffer, int32_t size)
 
void audio_mixer_destroy (audio_mixer_sound_t *sound)
 
audio_mixer_voice_taudio_mixer_play (audio_mixer_sound_t *sound, bool repeat, float volume, audio_mixer_stop_cb_t stop_cb)
 
void audio_mixer_stop (audio_mixer_voice_t *voice)
 
float audio_mixer_voice_get_volume (audio_mixer_voice_t *voice)
 
void audio_mixer_voice_set_volume (audio_mixer_voice_t *voice, float val)
 
void audio_mixer_mix (float *buffer, size_t num_frames, float volume_override, bool override)
 

Macro Definition Documentation

◆ AUDIO_MIXER_SOUND_FINISHED

#define AUDIO_MIXER_SOUND_FINISHED   0

◆ AUDIO_MIXER_SOUND_REPEATED

#define AUDIO_MIXER_SOUND_REPEATED   2

◆ AUDIO_MIXER_SOUND_STOPPED

#define AUDIO_MIXER_SOUND_STOPPED   1

Typedef Documentation

◆ audio_mixer_sound_t

◆ audio_mixer_stop_cb_t

typedef void(* audio_mixer_stop_cb_t) (audio_mixer_sound_t *sound, unsigned reason)

◆ audio_mixer_voice_t

Enumeration Type Documentation

◆ audio_mixer_type

Enumerator
AUDIO_MIXER_TYPE_NONE 
AUDIO_MIXER_TYPE_WAV 
AUDIO_MIXER_TYPE_OGG 
AUDIO_MIXER_TYPE_MOD 
AUDIO_MIXER_TYPE_FLAC 
AUDIO_MIXER_TYPE_MP3 

Function Documentation

◆ audio_mixer_destroy()

void audio_mixer_destroy ( audio_mixer_sound_t sound)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ audio_mixer_done()

void audio_mixer_done ( void  )
Here is the call graph for this function:
Here is the caller graph for this function:

◆ audio_mixer_init()

void audio_mixer_init ( unsigned  rate)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ audio_mixer_load_flac()

audio_mixer_sound_t* audio_mixer_load_flac ( void buffer,
int32_t  size 
)
Here is the caller graph for this function:

◆ audio_mixer_load_mod()

audio_mixer_sound_t* audio_mixer_load_mod ( void buffer,
int32_t  size 
)
Here is the caller graph for this function:

◆ audio_mixer_load_mp3()

audio_mixer_sound_t* audio_mixer_load_mp3 ( void buffer,
int32_t  size 
)
Here is the caller graph for this function:

◆ audio_mixer_load_ogg()

audio_mixer_sound_t* audio_mixer_load_ogg ( void buffer,
int32_t  size 
)
Here is the caller graph for this function:

◆ audio_mixer_load_wav()

audio_mixer_sound_t* audio_mixer_load_wav ( void buffer,
int32_t  size 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ audio_mixer_mix()

void audio_mixer_mix ( float *  buffer,
size_t  num_frames,
float  volume_override,
bool  override 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ audio_mixer_play()

audio_mixer_voice_t* audio_mixer_play ( audio_mixer_sound_t sound,
bool  repeat,
float  volume,
audio_mixer_stop_cb_t  stop_cb 
)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ audio_mixer_stop()

void audio_mixer_stop ( audio_mixer_voice_t voice)
Here is the call graph for this function:
Here is the caller graph for this function:

◆ audio_mixer_voice_get_volume()

float audio_mixer_voice_get_volume ( audio_mixer_voice_t voice)

◆ audio_mixer_voice_set_volume()

void audio_mixer_voice_set_volume ( audio_mixer_voice_t voice,
float  val 
)
Here is the caller graph for this function: