xine-lib 1.2.11
|
#include <stdarg.h>
#include <errno.h>
#include <string.h>
#include <math.h>
#include <windows.h>
#include <dsound.h>
#include <xine/xine_internal.h>
#include <xine/audio_out.h>
Data Structures | |
struct | dx2_class_t |
struct | dx2_driver_t |
Macros | |
#define | LOG_MODULE "audio_directx2_out" |
#define | LOG_VERBOSE |
#define | AO_OUT_DIRECTX2_IFACE_VERSION 9 |
#define | GAP_TOLERANCE (AO_MAX_GAP/3) |
#define | BUFFER_MS 1000 |
#define | BUFFER_MIN_MS 200 |
#define | FACTOR 60.0 |
#define | STATUS_START 0 |
#define | STATUS_WAIT 1 |
#define | STATUS_RUNNING 2 |
#define | PRIdword "lu" |
#define | PRIsizet "u" |
#define | IID_IDirectSoundNotify xine_IID_IDirectSoundNotify |
Functions | |
static void | XINE_FORMAT_PRINTF (1, 2) |
static char * | dsound_strerror (HRESULT err) |
static LPDIRECTSOUND | dsound_create () |
static void | dsound_destroy (LPDIRECTSOUND ds) |
static void | dsound_fill_wfx (WAVEFORMATEX *wfx, uint32_t bits, uint32_t rate, int channels, size_t frame_size) |
static void | dsound_fill_desc (DSBUFFERDESC *desc, DWORD flags, DWORD buffer_size, WAVEFORMATEX *wfx) |
static void | audio_thread_exit (dx2_driver_t *this) |
static void | audio_error (dx2_driver_t *this, HRESULT err, char *msg) |
static int | audio_create_buffers (dx2_driver_t *this) |
static void | audio_destroy_buffers (dx2_driver_t *this) |
static int | audio_play (dx2_driver_t *this) |
static int | audio_stop (dx2_driver_t *this) |
static int | audio_tell (dx2_driver_t *this, size_t *pos) |
static int | audio_seek (dx2_driver_t *this, size_t pos) |
static int | audio_flush (dx2_driver_t *this) |
static int | audio_set_volume (dx2_driver_t *this, int volume) |
static int | audio_fill (dx2_driver_t *this, char *data, size_t size) |
static int | mode2channels (uint32_t mode) |
static int | test_capability (LPDIRECTSOUNDBUFFER buffer, uint32_t bits, uint32_t rate, int mode) |
static int | test_capabilities (dx2_driver_t *this) |
static size_t | buffer_free_size (dx2_driver_t *this) |
static size_t | buffer_occupied_size (dx2_driver_t *this) |
static void * | buffer_service (void *data) |
static uint32_t | ao_dx2_get_capabilities (ao_driver_t *this_gen) |
static int | ao_dx2_get_property (ao_driver_t *this_gen, int property) |
static int | ao_dx2_set_property (ao_driver_t *this_gen, int property, int value) |
static int | ao_dx2_open (ao_driver_t *this_gen, uint32_t bits, uint32_t rate, int mode) |
static int | ao_dx2_num_channels (ao_driver_t *this_gen) |
static int | ao_dx2_bytes_per_frame (ao_driver_t *this_gen) |
static int | ao_dx2_delay (ao_driver_t *this_gen) |
static int | ao_dx2_write (ao_driver_t *this_gen, int16_t *audio_data, uint32_t num_samples) |
static void | ao_dx2_close (ao_driver_t *this_gen) |
static void | ao_dx2_exit (ao_driver_t *this_gen) |
static int | ao_dx2_get_gap_tolerance (ao_driver_t *this_gen) |
static int | ao_dx2_control (ao_driver_t *this_gen, int cmd,...) |
static ao_driver_t * | open_plugin (audio_driver_class_t *class_gen, const void *data) |
static void * | init_class (xine_t *xine, const void *data) |
Variables | |
static const GUID | xine_IID_IDirectSoundNotify |
static const ao_info_t | ao_info_directx2 |
const plugin_info_t xine_plugin_info[] | EXPORTED |
#define AO_OUT_DIRECTX2_IFACE_VERSION 9 |
#define BUFFER_MIN_MS 200 |
#define BUFFER_MS 1000 |
#define FACTOR 60.0 |
#define GAP_TOLERANCE (AO_MAX_GAP/3) |
#define IID_IDirectSoundNotify xine_IID_IDirectSoundNotify |
#define LOG_MODULE "audio_directx2_out" |
#define LOG_VERBOSE |
#define PRIdword "lu" |
#define PRIsizet "u" |
#define STATUS_RUNNING 2 |
#define STATUS_START 0 |
#define STATUS_WAIT 1 |
|
static |
References lprintf.
Referenced by open_plugin().
|
static |
References _, audio_destroy_buffers(), audio_thread_exit(), buffer_service(), LOG_MODULE, lprintf, NULL, xine_log(), and XINE_LOG_MSG.
Referenced by open_plugin().
|
static |
References _, AO_CTRL_FLUSH_BUFFERS, AO_CTRL_PLAY_PAUSE, AO_CTRL_PLAY_RESUME, audio_flush(), audio_play(), audio_stop(), LOG_MODULE, lprintf, STATUS_WAIT, xine_log(), and XINE_LOG_MSG.
Referenced by open_plugin().
|
static |
References audio_tell(), buffer_occupied_size(), lprintf, PRIdword, and STATUS_RUNNING.
Referenced by open_plugin().
|
static |
References _, dsound_destroy(), LOG_MODULE, lprintf, xine_log(), and XINE_LOG_MSG.
Referenced by open_plugin().
|
static |
Referenced by open_plugin().
|
static |
References GAP_TOLERANCE.
Referenced by open_plugin().
|
static |
References AO_PROP_MIXER_VOL, AO_PROP_MUTE_VOL, and AO_PROP_PCM_VOL.
Referenced by open_plugin().
|
static |
References lprintf.
Referenced by open_plugin().
|
static |
References _, audio_create_buffers(), audio_destroy_buffers(), audio_set_volume(), bits, buffer_service(), LOG_MODULE, lprintf, mode(), mode2channels(), NULL, STATUS_START, xine_log(), and XINE_LOG_MSG.
Referenced by open_plugin().
|
static |
References AO_PROP_MIXER_VOL, AO_PROP_MUTE_VOL, AO_PROP_PCM_VOL, audio_set_volume(), and lprintf.
Referenced by open_plugin().
|
static |
References audio_fill(), audio_thread_exit(), buffer_free_size(), BUFFER_MIN_MS, BUFFER_MS, buffer_occupied_size(), lprintf, STATUS_WAIT, and xine_usec_sleep().
Referenced by open_plugin().
|
static |
References _, audio_error(), bits, BUFFER_MS, dsound_fill_desc(), dsound_fill_wfx(), lprintf, and NULL.
Referenced by ao_dx2_open().
|
static |
Referenced by ao_dx2_close(), and ao_dx2_open().
|
static |
References audio_thread_exit(), dsound_strerror(), LOG_MODULE, STATUS_START, xine_log(), and XINE_LOG_MSG.
Referenced by audio_create_buffers(), audio_fill(), audio_play(), audio_seek(), audio_set_volume(), audio_stop(), and audio_tell().
|
static |
References _, _x_assert, audio_error(), LOG_MODULE, lprintf, NULL, xine_fast_memcpy, xine_log(), and XINE_LOG_MSG.
Referenced by ao_dx2_write().
|
static |
References audio_seek(), and STATUS_WAIT.
Referenced by ao_dx2_control(), and buffer_service().
|
static |
References _, and audio_error().
Referenced by ao_dx2_control(), and buffer_service().
|
static |
References _, and audio_error().
Referenced by audio_flush(), and buffer_service().
|
static |
References _, audio_error(), FACTOR, and lprintf.
Referenced by ao_dx2_open(), and ao_dx2_set_property().
|
static |
References _, and audio_error().
Referenced by ao_dx2_control(), and buffer_service().
|
static |
References _, audio_error(), and NULL.
Referenced by ao_dx2_delay(), buffer_free_size(), and buffer_occupied_size().
|
static |
Referenced by ao_dx2_close(), ao_dx2_write(), and audio_error().
|
static |
References audio_tell().
Referenced by ao_dx2_write(), and buffer_service().
|
static |
References audio_tell().
Referenced by ao_dx2_delay(), ao_dx2_write(), and buffer_service().
|
static |
References _, audio_flush(), audio_play(), audio_seek(), audio_stop(), buffer_free_size(), BUFFER_MIN_MS, buffer_occupied_size(), LOG_MODULE, lprintf, NULL, STATUS_RUNNING, STATUS_WAIT, xine_log(), XINE_LOG_MSG, and xine_usec_sleep().
Referenced by ao_dx2_close(), and ao_dx2_open().
|
static |
Referenced by open_plugin().
|
static |
Referenced by ao_dx2_exit().
|
static |
Referenced by audio_create_buffers(), and test_capabilities().
|
static |
References bits.
Referenced by audio_create_buffers(), and test_capability().
|
static |
References _.
Referenced by audio_error().
|
static |
References default_audio_driver_class_dispose, lprintf, N_, NULL, and open_plugin().
|
static |
References 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_dx2_open(), and test_capability().
|
static |
References _, ao_dx2_bytes_per_frame(), ao_dx2_close(), ao_dx2_control(), ao_dx2_delay(), ao_dx2_exit(), ao_dx2_get_capabilities(), ao_dx2_get_gap_tolerance(), ao_dx2_get_property(), ao_dx2_num_channels(), ao_dx2_open(), ao_dx2_set_property(), ao_dx2_write(), dsound_create(), LOG_MODULE, lprintf, NULL, test_capabilities(), xine_log(), and XINE_LOG_MSG.
Referenced by init_class().
|
static |
References _, AO_CAP_16BITS, AO_CAP_24BITS, AO_CAP_8BITS, AO_CAP_FLOAT32, AO_CAP_MODE_4CHANNEL, AO_CAP_MODE_5_1CHANNEL, AO_CAP_MODE_5CHANNEL, AO_CAP_MODE_MONO, AO_CAP_MODE_STEREO, bits, dsound_fill_desc(), lprintf, mode(), NULL, and test_capability().
Referenced by open_plugin().
|
static |
References bits, dsound_fill_wfx(), lprintf, mode(), and mode2channels().
Referenced by test_capabilities().
|
static |
References _.
|
static |
const plugin_info_t xine_plugin_info [] EXPORTED |
|
static |