xine-lib: xine-lib-1.2.12/include/xine/audio_out.h File Reference

xine-lib 1.2.12

Data Structures | Macros | Typedefs | Functions
audio_out.h File Reference
`#include <xine/attributes.h>`
`#include <xine/os_types.h>`
`#include <xine/xineutils.h>`
`#include <xine/buffer.h>`

Go to the source code of this file.

## Data Structures
struct | ao_driver_s
struct | ao_format_s
struct | audio_buffer_s
struct | xine_audio_port_s
struct | audio_driver_class_s

## Macros
#define | AUDIO_OUT_IFACE_VERSION 9
#define | default_audio_driver_class_dispose (void (*) (audio_driver_class_t *this_gen))free
#define | AO_CAP_NOCAP 0x00000000 /* driver has no capabilities */
#define | AO_CAP_MODE_A52 0x00000001 /* driver supports A/52 output */
#define | AO_CAP_MODE_AC5 0x00000002 /* driver supports AC5 output */
#define | AO_CAP_MODE_MONO 0x00000004 /* driver supports mono output */
#define | AO_CAP_MODE_STEREO 0x00000008 /* driver supports stereo output */
#define | AO_CAP_MODE_4CHANNEL 0x00000010 /* driver supports 4 channels */
#define | AO_CAP_MODE_4_1CHANNEL 0x00000020 /* driver supports 4.1 channels */
#define | AO_CAP_MODE_5CHANNEL 0x00000040 /* driver supports 5 channels */
#define | AO_CAP_MODE_5_1CHANNEL 0x00000080 /* driver supports 5.1 channels */
#define | AO_CAP_MIXER_VOL 0x00000100 /* driver supports mixer control */
#define | AO_CAP_PCM_VOL 0x00000200 /* driver supports pcm control */
#define | AO_CAP_MUTE_VOL 0x00000400 /* driver can mute volume */
#define | AO_CAP_8BITS 0x00000800 /* driver support 8-bit samples */
#define | AO_CAP_16BITS 0x00001000 /* driver support 16-bit samples */
#define | AO_CAP_24BITS 0x00002000 /* driver support 24-bit samples */
#define | AO_CAP_FLOAT32 0x00004000 /* driver support 32-bit samples. i.e. Floats */
#define | AO_CAP_NO_UNPAUSE
#define | AO_PROP_MIXER_VOL 0
#define | AO_PROP_PCM_VOL 1
#define | AO_PROP_MUTE_VOL 2
#define | AO_PROP_COMPRESSOR 3
#define | AO_PROP_DISCARD_BUFFERS 4
#define | AO_PROP_BUFS_IN_FIFO 5 /* read-only */
#define | AO_PROP_AMP 6 /* amplifier */
#define | AO_PROP_EQ_30HZ 7 /* equalizer */
#define | AO_PROP_EQ_60HZ 8 /* equalizer */
#define | AO_PROP_EQ_125HZ 9 /* equalizer */
#define | AO_PROP_EQ_250HZ 10 /* equalizer */
#define | AO_PROP_EQ_500HZ 11 /* equalizer */
#define | AO_PROP_EQ_1000HZ 12 /* equalizer */
#define | AO_PROP_EQ_2000HZ 13 /* equalizer */
#define | AO_PROP_EQ_4000HZ 14 /* equalizer */
#define | AO_PROP_EQ_8000HZ 15 /* equalizer */
#define | AO_PROP_EQ_16000HZ 16 /* equalizer */
#define | AO_PROP_CLOSE_DEVICE 17 /* force closing audio device */
#define | AO_PROP_AMP_MUTE 18 /* amplifier mute */
#define | AO_PROP_NUM_STREAMS 19 /* read-only */
#define | AO_PROP_CLOCK_SPEED 20 /* inform audio_out that speed has changed */
#define | AO_PROP_BUFS_TOTAL 21 /* read-only */
#define | AO_PROP_BUFS_FREE 22 /* read-only */
#define | AO_PROP_DRIVER_DELAY 23 /* read-only */
#define | AO_PROP_PTS_IN_FIFO 24 /* read only */
#define | AO_NUM_PROPERTIES 25
#define | AO_CTRL_PLAY_PAUSE 0
#define | AO_CTRL_PLAY_RESUME 1
#define | AO_CTRL_FLUSH_BUFFERS 2
#define | AO_MAX_GAP 15000

## Typedefs
typedef struct ao_driver_s | ao_driver_t
typedef struct ao_format_s | ao_format_t
typedef struct audio_fifo_s | audio_fifo_t
typedef struct audio_buffer_s | audio_buffer_t
typedef struct audio_driver_class_s | audio_driver_class_t

## Functions
xine_audio_port_t * | _x_ao_new_port (xine_t *xine, ao_driver_t *driver, int grab_only)
| Initialise the audio_out sync routines. More...
int | _x_ao_mode2channels (int mode)
int | _x_ao_channels2mode (int channels)

## Macro Definition Documentation

## ◆ AO_CAP_16BITS

#define AO_CAP_16BITS 0x00001000 /* driver support 16-bit samples */

## ◆ AO_CAP_24BITS

#define AO_CAP_24BITS 0x00002000 /* driver support 24-bit samples */

## ◆ AO_CAP_8BITS

#define AO_CAP_8BITS 0x00000800 /* driver support 8-bit samples */

## ◆ AO_CAP_FLOAT32

#define AO_CAP_FLOAT32 0x00004000 /* driver support 32-bit samples. i.e. Floats */

## ◆ AO_CAP_MIXER_VOL

#define AO_CAP_MIXER_VOL 0x00000100 /* driver supports mixer control */

## ◆ AO_CAP_MODE_4_1CHANNEL

#define AO_CAP_MODE_4_1CHANNEL 0x00000020 /* driver supports 4.1 channels */

## ◆ AO_CAP_MODE_4CHANNEL

#define AO_CAP_MODE_4CHANNEL 0x00000010 /* driver supports 4 channels */

## ◆ AO_CAP_MODE_5_1CHANNEL

#define AO_CAP_MODE_5_1CHANNEL 0x00000080 /* driver supports 5.1 channels */

## ◆ AO_CAP_MODE_5CHANNEL

#define AO_CAP_MODE_5CHANNEL 0x00000040 /* driver supports 5 channels */

## ◆ AO_CAP_MODE_A52

#define AO_CAP_MODE_A52 0x00000001 /* driver supports A/52 output */

## ◆ AO_CAP_MODE_AC5

#define AO_CAP_MODE_AC5 0x00000002 /* driver supports AC5 output */

## ◆ AO_CAP_MODE_MONO

#define AO_CAP_MODE_MONO 0x00000004 /* driver supports mono output */

## ◆ AO_CAP_MODE_STEREO

#define AO_CAP_MODE_STEREO 0x00000008 /* driver supports stereo output */

## ◆ AO_CAP_MUTE_VOL

#define AO_CAP_MUTE_VOL 0x00000400 /* driver can mute volume */

## ◆ AO_CAP_NO_UNPAUSE

#define AO_CAP_NO_UNPAUSE

Value:
0x00008000 /* driver can not resume after pause.
* please resend some frames instead. */

## ◆ AO_CAP_NOCAP

#define AO_CAP_NOCAP 0x00000000 /* driver has no capabilities */

## ◆ AO_CAP_PCM_VOL

#define AO_CAP_PCM_VOL 0x00000200 /* driver supports pcm control */

## ◆ AO_CTRL_FLUSH_BUFFERS

#define AO_CTRL_FLUSH_BUFFERS 2

## ◆ AO_CTRL_PLAY_PAUSE

#define AO_CTRL_PLAY_PAUSE 0

## ◆ AO_CTRL_PLAY_RESUME

#define AO_CTRL_PLAY_RESUME 1

## ◆ AO_MAX_GAP

#define AO_MAX_GAP 15000

## ◆ AO_NUM_PROPERTIES

#define AO_NUM_PROPERTIES 25

## ◆ AO_PROP_AMP

#define AO_PROP_AMP 6 /* amplifier */

## ◆ AO_PROP_AMP_MUTE

#define AO_PROP_AMP_MUTE 18 /* amplifier mute */

## ◆ AO_PROP_BUFS_FREE

#define AO_PROP_BUFS_FREE 22 /* read-only */

## ◆ AO_PROP_BUFS_IN_FIFO

#define AO_PROP_BUFS_IN_FIFO 5 /* read-only */

## ◆ AO_PROP_BUFS_TOTAL

#define AO_PROP_BUFS_TOTAL 21 /* read-only */

## ◆ AO_PROP_CLOCK_SPEED

#define AO_PROP_CLOCK_SPEED 20 /* inform audio_out that speed has changed */

## ◆ AO_PROP_CLOSE_DEVICE

#define AO_PROP_CLOSE_DEVICE 17 /* force closing audio device */

## ◆ AO_PROP_COMPRESSOR

#define AO_PROP_COMPRESSOR 3

## ◆ AO_PROP_DISCARD_BUFFERS

#define AO_PROP_DISCARD_BUFFERS 4

## ◆ AO_PROP_DRIVER_DELAY

#define AO_PROP_DRIVER_DELAY 23 /* read-only */

## ◆ AO_PROP_EQ_1000HZ

#define AO_PROP_EQ_1000HZ 12 /* equalizer */

## ◆ AO_PROP_EQ_125HZ

#define AO_PROP_EQ_125HZ 9 /* equalizer */

## ◆ AO_PROP_EQ_16000HZ

#define AO_PROP_EQ_16000HZ 16 /* equalizer */

## ◆ AO_PROP_EQ_2000HZ

#define AO_PROP_EQ_2000HZ 13 /* equalizer */

## ◆ AO_PROP_EQ_250HZ

#define AO_PROP_EQ_250HZ 10 /* equalizer */

## ◆ AO_PROP_EQ_30HZ

#define AO_PROP_EQ_30HZ 7 /* equalizer */

## ◆ AO_PROP_EQ_4000HZ

#define AO_PROP_EQ_4000HZ 14 /* equalizer */

## ◆ AO_PROP_EQ_500HZ

#define AO_PROP_EQ_500HZ 11 /* equalizer */

## ◆ AO_PROP_EQ_60HZ

#define AO_PROP_EQ_60HZ 8 /* equalizer */

## ◆ AO_PROP_EQ_8000HZ

#define AO_PROP_EQ_8000HZ 15 /* equalizer */

## ◆ AO_PROP_MIXER_VOL

#define AO_PROP_MIXER_VOL 0

## ◆ AO_PROP_MUTE_VOL

#define AO_PROP_MUTE_VOL 2

## ◆ AO_PROP_NUM_STREAMS

#define AO_PROP_NUM_STREAMS 19 /* read-only */

## ◆ AO_PROP_PCM_VOL

#define AO_PROP_PCM_VOL 1

## ◆ AO_PROP_PTS_IN_FIFO

#define AO_PROP_PTS_IN_FIFO 24 /* read only */

## ◆ AUDIO_OUT_IFACE_VERSION

#define AUDIO_OUT_IFACE_VERSION 9

## ◆ default_audio_driver_class_dispose

#define default_audio_driver_class_dispose (void (*) (audio_driver_class_t *this_gen))free

## Typedef Documentation

## ◆ ao_driver_t

typedef struct ao_driver_s ao_driver_t

## ◆ ao_format_t

typedef struct ao_format_s ao_format_t

## ◆ audio_buffer_t

typedef struct audio_buffer_s audio_buffer_t

## ◆ audio_driver_class_t

typedef struct audio_driver_class_s audio_driver_class_t

## ◆ audio_fifo_t

typedef struct audio_fifo_s audio_fifo_t

## Function Documentation

## ◆ _x_ao_channels2mode()

int _x_ao_channels2mode | ( | int | channels | ) |

References AO_CAP_MODE_4CHANNEL, AO_CAP_MODE_5_1CHANNEL, AO_CAP_MODE_5CHANNEL, AO_CAP_MODE_MONO, AO_CAP_MODE_STEREO, and AO_CAP_NOCAP.

Referenced by dvaudio_decode_data(), flac_decode_data(), lpcm_decode_data(), mpc_decode_data(), nsf_decode_data(), qta_init_driver(), speex_decode_data(), vorbis_decode_data(), w32a_init_audio(), and wavpack_decode_data().

## ◆ _x_ao_mode2channels()

int _x_ao_mode2channels | ( | int | mode | ) |

References AO_CAP_MODE_4_1CHANNEL, AO_CAP_MODE_4CHANNEL, AO_CAP_MODE_5_1CHANNEL, AO_CAP_MODE_5CHANNEL, AO_CAP_MODE_MONO, AO_CAP_MODE_STEREO, and mode().

Referenced by ao_open(), ao_pulse_open(), ao_update_resample_factor(), fftgraph_port_open(), fftscope_port_open(), fooviz_port_open(), goom_port_open(), oscope_port_open(), stretch_port_put_buffer(), tdaan_port_open(), upmix_mono_port_open(), upmix_port_open(), and vdr_audio_port_open().

## ◆ _x_ao_new_port()

xine_audio_port_t * _x_ao_new_port | ( | xine_t * | xine,
|  | ao_driver_t * | driver,
|  | int | grab_only
| ) |  |

Initialise the audio_out sync routines.

References _, AO_CAP_MIXER_VOL, AO_CAP_PCM_VOL, ao_close(), ao_control(), ao_exit(), ao_flush(), ao_free_fifo_open(), ao_gap_ring_reset(), ao_get_buffer(), ao_get_capabilities(), ao_get_property(), ao_loop(), ao_open(), ao_out_fifo_open(), AO_PROP_MIXER_VOL, AO_PROP_PCM_VOL, ao_put_buffer(), ao_set_property(), ao_speed_change_cb(), ao_status(), ao_streams_open(), ao_ticket_revoked(), ao_update_av_fine_sync_method(), ao_update_av_sync_method(), ao_update_ptoffs(), ao_update_slow_fast(), AUDIO_BUF_SIZE, xine_s::clock, xine_s::config, EI_RING_SIZE, audio_buffer_s::extra_info, ao_driver_s::get_capabilities, ao_driver_s::get_gap_tolerance, audio_buffer_s::mem, audio_buffer_s::mem_size, audio_buffer_s::next, NULL, NUM_AUDIO_BUFFERS, config_values_s::register_bool, config_values_s::register_enum, config_values_s::register_num, config_values_s::register_range, metronom_clock_s::register_speed_change_callback, ao_driver_s::set_property, metronom_clock_s::speed, ao_driver_s::write, xine_free_aligned(), xine_mallocz_aligned(), XINE_VERBOSITY_DEBUG, XINE_VERBOSITY_LOG, XINE_VERBOSITY_NONE, and xprintf.

Referenced by xine_new_framegrab_audio_port(), and xine_open_audio_driver().