RetroArch
Classes | Macros | Typedefs | Functions | Variables
alsa_qsa.c File Reference
#include <sys/asoundlib.h>
#include <retro_math.h>
#include "../audio_driver.h"
Include dependency graph for alsa_qsa.c:

Classes

struct  alsa
 

Macros

#define ALSA_PCM_NEW_HW_PARAMS_API
 
#define ALSA_PCM_NEW_SW_PARAMS_API
 
#define MAX_FRAG_SIZE   3072
 
#define DEFAULT_RATE   48000
 
#define CHANNELS   2
 

Typedefs

typedef struct alsa alsa_t
 
typedef long snd_pcm_sframes_t
 

Functions

static voidalsa_qsa_init (const char *device, unsigned rate, unsigned latency, unsigned block_frames, unsigned *new_rate)
 
static int check_pcm_status (void *data, int channel_type)
 
static ssize_t alsa_qsa_write (void *data, const void *buf, size_t size)
 
static bool alsa_qsa_stop (void *data)
 
static bool alsa_qsa_alive (void *data)
 
static bool alsa_qsa_start (void *data, bool is_shutdown)
 
static void alsa_qsa_set_nonblock_state (void *data, bool state)
 
static bool alsa_qsa_use_float (void *data)
 
static void alsa_qsa_free (void *data)
 
static size_t alsa_qsa_write_avail (void *data)
 
static size_t alsa_qsa_buffer_size (void *data)
 

Variables

audio_driver_t audio_alsa
 

Macro Definition Documentation

◆ ALSA_PCM_NEW_HW_PARAMS_API

#define ALSA_PCM_NEW_HW_PARAMS_API

◆ ALSA_PCM_NEW_SW_PARAMS_API

#define ALSA_PCM_NEW_SW_PARAMS_API

◆ CHANNELS

#define CHANNELS   2

◆ DEFAULT_RATE

#define DEFAULT_RATE   48000

◆ MAX_FRAG_SIZE

#define MAX_FRAG_SIZE   3072

Typedef Documentation

◆ alsa_t

typedef struct alsa alsa_t

◆ snd_pcm_sframes_t

typedef long snd_pcm_sframes_t

Function Documentation

◆ alsa_qsa_alive()

static bool alsa_qsa_alive ( void data)
static

◆ alsa_qsa_buffer_size()

static size_t alsa_qsa_buffer_size ( void data)
static

◆ alsa_qsa_free()

static void alsa_qsa_free ( void data)
static
Here is the call graph for this function:

◆ alsa_qsa_init()

static void* alsa_qsa_init ( const char *  device,
unsigned  rate,
unsigned  latency,
unsigned  block_frames,
unsigned *  new_rate 
)
static
Here is the call graph for this function:

◆ alsa_qsa_set_nonblock_state()

static void alsa_qsa_set_nonblock_state ( void data,
bool  state 
)
static
Here is the call graph for this function:

◆ alsa_qsa_start()

static bool alsa_qsa_start ( void data,
bool  is_shutdown 
)
static
Here is the call graph for this function:

◆ alsa_qsa_stop()

static bool alsa_qsa_stop ( void data)
static

◆ alsa_qsa_use_float()

static bool alsa_qsa_use_float ( void data)
static

◆ alsa_qsa_write()

static ssize_t alsa_qsa_write ( void data,
const void buf,
size_t  size 
)
static
Here is the call graph for this function:

◆ alsa_qsa_write_avail()

static size_t alsa_qsa_write_avail ( void data)
static

◆ check_pcm_status()

static int check_pcm_status ( void data,
int  channel_type 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ audio_alsa

audio_driver_t audio_alsa
Initial value:
= {
"alsa",
}
static size_t alsa_qsa_buffer_size(void *data)
Definition: alsa_qsa.c:364
static bool alsa_qsa_stop(void *data)
Definition: alsa_qsa.c:270
static bool alsa_qsa_use_float(void *data)
Definition: alsa_qsa.c:332
static void * alsa_qsa_init(const char *device, unsigned rate, unsigned latency, unsigned block_frames, unsigned *new_rate)
Definition: alsa_qsa.c:48
static size_t alsa_qsa_write_avail(void *data)
Definition: alsa_qsa.c:355
#define NULL
Pointer to 0.
Definition: gctypes.h:65
static ssize_t alsa_qsa_write(void *data, const void *buf, size_t size)
Definition: alsa_qsa.c:223
static void alsa_qsa_set_nonblock_state(void *data, bool state)
Definition: alsa_qsa.c:315
static bool alsa_qsa_alive(void *data)
Definition: alsa_qsa.c:286
static bool alsa_qsa_start(void *data, bool is_shutdown)
Definition: alsa_qsa.c:294
static void alsa_qsa_free(void *data)
Definition: alsa_qsa.c:338