The RtAudio Home Page

Home Class/Enum List File List Compound Members C interface

Classes | Typedefs | Enumerations | Functions
rtaudio_c.h File Reference
C-interface

Go to the source code of this file.

## Classes
struct | rtaudio_device_info_t
struct | rtaudio_stream_parameters_t
struct | rtaudio_stream_options_t

## Typedefs
typedef unsigned long | rtaudio_format_t
| RtAudio data format type.
typedef unsigned int | rtaudio_stream_flags_t
| RtAudio stream option flags.
typedef unsigned int | rtaudio_stream_status_t
| RtAudio stream status (over- or underflow) flags.
typedef int(* | rtaudio_cb_t) (void *out, void *in, unsigned int nFrames, double stream_time, rtaudio_stream_status_t status, void *userdata)
| RtAudio callback function prototype.
typedef void(* | rtaudio_error_cb_t) (rtaudio_error_t err, const char *msg)
| RtAudio error callback function prototype.

## Enumerations
enum | rtaudio_error { RTAUDIO_ERROR_NONE = 0 , RTAUDIO_ERROR_WARNING , RTAUDIO_ERROR_UNKNOWN , RTAUDIO_ERROR_NO_DEVICES_FOUND , RTAUDIO_ERROR_INVALID_DEVICE , RTAUDIO_ERROR_DEVICE_DISCONNECT , RTAUDIO_ERROR_MEMORY_ERROR , RTAUDIO_ERROR_INVALID_PARAMETER , RTAUDIO_ERROR_INVALID_USE , RTAUDIO_ERROR_DRIVER_ERROR , RTAUDIO_ERROR_SYSTEM_ERROR , RTAUDIO_ERROR_THREAD_ERROR }
| Error codes for RtAudio. More...
enum | rtaudio_api { RTAUDIO_API_UNSPECIFIED , RTAUDIO_API_MACOSX_CORE , RTAUDIO_API_LINUX_ALSA , RTAUDIO_API_UNIX_JACK , RTAUDIO_API_LINUX_PULSE , RTAUDIO_API_LINUX_OSS , RTAUDIO_API_WINDOWS_ASIO , RTAUDIO_API_WINDOWS_WASAPI , RTAUDIO_API_WINDOWS_DS , RTAUDIO_API_DUMMY , RTAUDIO_API_NUM }
| Audio API specifier. See RtAudio::Api. More...

## Functions
RTAUDIOAPI const char * | rtaudio_version (void)
| Determine the current RtAudio version. See RtAudio::getVersion().
RTAUDIOAPI unsigned int | rtaudio_get_num_compiled_apis (void)
RTAUDIOAPI const rtaudio_api_t * | rtaudio_compiled_api (void)
RTAUDIOAPI const char * | rtaudio_api_name (rtaudio_api_t api)
RTAUDIOAPI const char * | rtaudio_api_display_name (rtaudio_api_t api)
RTAUDIOAPI rtaudio_api_t | rtaudio_compiled_api_by_name (const char *name)
RTAUDIOAPI rtaudio_t | rtaudio_create (rtaudio_api_t api)
| Create an instance of struct rtaudio.
RTAUDIOAPI void | rtaudio_destroy (rtaudio_t audio)
| Free an instance of struct rtaudio.
RTAUDIOAPI rtaudio_api_t | rtaudio_current_api (rtaudio_t audio)
RTAUDIOAPI int | rtaudio_device_count (rtaudio_t audio)
RTAUDIOAPI unsigned int | rtaudio_get_device_id (rtaudio_t audio, int i)
RTAUDIOAPI rtaudio_device_info_t | rtaudio_get_device_info (rtaudio_t audio, unsigned int id)
RTAUDIOAPI unsigned int | rtaudio_get_default_output_device (rtaudio_t audio)
RTAUDIOAPI unsigned int | rtaudio_get_default_input_device (rtaudio_t audio)
RTAUDIOAPI rtaudio_error_t | rtaudio_open_stream (rtaudio_t audio, rtaudio_stream_parameters_t *output_params, rtaudio_stream_parameters_t *input_params, rtaudio_format_t format, unsigned int sample_rate, unsigned int *buffer_frames, rtaudio_cb_t cb, void *userdata, rtaudio_stream_options_t *options, rtaudio_error_cb_t errcb)
RTAUDIOAPI void | rtaudio_close_stream (rtaudio_t audio)
| Closes a stream and frees any associated stream memory. See RtAudio::closeStream().
RTAUDIOAPI rtaudio_error_t | rtaudio_start_stream (rtaudio_t audio)
| Starts a stream. See RtAudio::startStream().
RTAUDIOAPI rtaudio_error_t | rtaudio_stop_stream (rtaudio_t audio)
RTAUDIOAPI rtaudio_error_t | rtaudio_abort_stream (rtaudio_t audio)
RTAUDIOAPI int | rtaudio_is_stream_open (rtaudio_t audio)
| Returns 1 if a stream is open and false if not. See RtAudio::isStreamOpen().
RTAUDIOAPI int | rtaudio_is_stream_running (rtaudio_t audio)
RTAUDIOAPI double | rtaudio_get_stream_time (rtaudio_t audio)
RTAUDIOAPI void | rtaudio_set_stream_time (rtaudio_t audio, double time)
RTAUDIOAPI long | rtaudio_get_stream_latency (rtaudio_t audio)
RTAUDIOAPI unsigned int | rtaudio_get_stream_sample_rate (rtaudio_t audio)
RTAUDIOAPI void | rtaudio_show_warnings (rtaudio_t audio, int show)

| ©2001-2023 Gary P. Scavone, McGill University. All Rights Reserved. Maintained by Gary P. Scavone.