RetroArch
Classes | Macros | Typedefs | Functions | Variables
alsathread.c File Reference
#include <stdlib.h>
#include <lists/string_list.h>
#include <alsa/asoundlib.h>
#include <rthreads/rthreads.h>
#include <queues/fifo_queue.h>
#include <string/stdstring.h>
#include "../audio_driver.h"
#include "../../verbosity.h"
Include dependency graph for alsathread.c:

Classes

struct  alsa_thread
 

Macros

#define TRY_ALSA(x)
 

Typedefs

typedef struct alsa_thread alsa_thread_t
 

Functions

static void alsa_worker_thread (void *data)
 
static bool alsa_thread_use_float (void *data)
 
static bool alsathread_find_float_format (snd_pcm_t *pcm, snd_pcm_hw_params_t *params)
 
static void alsa_thread_free (void *data)
 
static voidalsa_thread_init (const char *device, unsigned rate, unsigned latency, unsigned block_frames, unsigned *new_rate)
 
static ssize_t alsa_thread_write (void *data, const void *buf, size_t size)
 
static bool alsa_thread_alive (void *data)
 
static bool alsa_thread_stop (void *data)
 
static void alsa_thread_set_nonblock_state (void *data, bool state)
 
static bool alsa_thread_start (void *data, bool is_shutdown)
 
static size_t alsa_thread_write_avail (void *data)
 
static size_t alsa_thread_buffer_size (void *data)
 
static voidalsa_device_list_new (void *data)
 
static void alsa_device_list_free (void *data, void *array_list_data)
 

Variables

audio_driver_t audio_alsathread
 

Macro Definition Documentation

◆ TRY_ALSA

#define TRY_ALSA (   x)
Value:
if (x < 0) \
goto error;
static l_noret error(LoadState *S, const char *why)
Definition: lundump.c:39
GLint GLint GLint GLint GLint x
Definition: glext.h:6295

Typedef Documentation

◆ alsa_thread_t

typedef struct alsa_thread alsa_thread_t

Function Documentation

◆ alsa_device_list_free()

static void alsa_device_list_free ( void data,
void array_list_data 
)
static
Here is the call graph for this function:

◆ alsa_device_list_new()

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

◆ alsa_thread_alive()

static bool alsa_thread_alive ( void data)
static

◆ alsa_thread_buffer_size()

static size_t alsa_thread_buffer_size ( void data)
static

◆ alsa_thread_free()

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

◆ alsa_thread_init()

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

◆ alsa_thread_set_nonblock_state()

static void alsa_thread_set_nonblock_state ( void data,
bool  state 
)
static

◆ alsa_thread_start()

static bool alsa_thread_start ( void data,
bool  is_shutdown 
)
static

◆ alsa_thread_stop()

static bool alsa_thread_stop ( void data)
static

◆ alsa_thread_use_float()

static bool alsa_thread_use_float ( void data)
static

◆ alsa_thread_write()

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

◆ alsa_thread_write_avail()

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

◆ alsa_worker_thread()

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

◆ alsathread_find_float_format()

static bool alsathread_find_float_format ( snd_pcm_t *  pcm,
snd_pcm_hw_params_t *  params 
)
static
Here is the call graph for this function:
Here is the caller graph for this function:

Variable Documentation

◆ audio_alsathread

audio_driver_t audio_alsathread
Initial value:
= {
"alsathread",
}
static ssize_t alsa_thread_write(void *data, const void *buf, size_t size)
Definition: alsathread.c:246
static bool alsa_thread_use_float(void *data)
Definition: alsathread.c:108
static bool alsa_thread_alive(void *data)
Definition: alsathread.c:297
static void alsa_device_list_free(void *data, void *array_list_data)
Definition: alsathread.c:396
static size_t alsa_thread_write_avail(void *data)
Definition: alsathread.c:329
static void alsa_thread_free(void *data)
Definition: alsathread.c:126
static void alsa_thread_set_nonblock_state(void *data, bool state)
Definition: alsathread.c:314
static bool alsa_thread_stop(void *data)
Definition: alsathread.c:305
static size_t alsa_thread_buffer_size(void *data)
Definition: alsathread.c:342
static void * alsa_thread_init(const char *device, unsigned rate, unsigned latency, unsigned block_frames, unsigned *new_rate)
Definition: alsathread.c:156
static bool alsa_thread_start(void *data, bool is_shutdown)
Definition: alsathread.c:320
static void * alsa_device_list_new(void *data)
Definition: alsathread.c:348