Main Page   Modules   Data Structures   File List   Data Fields   Globals   Related Pages   Examples  

pcm.h

00001 
00029 #ifndef __ALSA_PCM_H
00030 #define __ALSA_PCM_H
00031 
00032 #ifdef __cplusplus
00033 extern "C" {
00034 #endif
00035 
00043 #define SND_PCM_DLSYM_VERSION           _dlsym_pcm_001
00044 
00046 typedef struct _snd_pcm_info snd_pcm_info_t;
00048 typedef struct _snd_pcm_hw_params snd_pcm_hw_params_t;
00050 typedef struct _snd_pcm_sw_params snd_pcm_sw_params_t;
00052  typedef struct _snd_pcm_status snd_pcm_status_t;
00054 typedef struct _snd_pcm_access_mask snd_pcm_access_mask_t;
00056 typedef struct _snd_pcm_format_mask snd_pcm_format_mask_t;
00058 typedef struct _snd_pcm_subformat_mask snd_pcm_subformat_mask_t;
00059 
00061 typedef enum _snd_pcm_class {
00064         SND_PCM_CLASS_GENERIC = 0,
00066         SND_PCM_CLASS_MULTI,
00068         SND_PCM_CLASS_MODEM,
00070         SND_PCM_CLASS_DIGITIZER,
00071         SND_PCM_CLASS_LAST = SND_PCM_CLASS_DIGITIZER
00072 } snd_pcm_class_t;
00073 
00075 typedef enum _snd_pcm_subclass {
00077         SND_PCM_SUBCLASS_GENERIC_MIX = 0,
00079         SND_PCM_SUBCLASS_MULTI_MIX,
00080         SND_PCM_SUBCLASS_LAST = SND_PCM_SUBCLASS_MULTI_MIX
00081 } snd_pcm_subclass_t;
00082 
00084 typedef enum _snd_pcm_stream {
00086         SND_PCM_STREAM_PLAYBACK = 0,
00088         SND_PCM_STREAM_CAPTURE,
00089         SND_PCM_STREAM_LAST = SND_PCM_STREAM_CAPTURE
00090 } snd_pcm_stream_t;
00091 
00093 typedef enum _snd_pcm_access {
00095         SND_PCM_ACCESS_MMAP_INTERLEAVED = 0,
00097         SND_PCM_ACCESS_MMAP_NONINTERLEAVED,
00099         SND_PCM_ACCESS_MMAP_COMPLEX,
00101         SND_PCM_ACCESS_RW_INTERLEAVED,
00103         SND_PCM_ACCESS_RW_NONINTERLEAVED,
00104         SND_PCM_ACCESS_LAST = SND_PCM_ACCESS_RW_NONINTERLEAVED
00105 } snd_pcm_access_t;
00106 
00108 typedef enum _snd_pcm_format {
00110         SND_PCM_FORMAT_UNKNOWN = -1,
00112         SND_PCM_FORMAT_S8 = 0,
00114         SND_PCM_FORMAT_U8,
00116         SND_PCM_FORMAT_S16_LE,
00118         SND_PCM_FORMAT_S16_BE,
00120         SND_PCM_FORMAT_U16_LE,
00122         SND_PCM_FORMAT_U16_BE,
00124         SND_PCM_FORMAT_S24_LE,
00126         SND_PCM_FORMAT_S24_BE,
00128         SND_PCM_FORMAT_U24_LE,
00130         SND_PCM_FORMAT_U24_BE,
00132         SND_PCM_FORMAT_S32_LE,
00134         SND_PCM_FORMAT_S32_BE,
00136         SND_PCM_FORMAT_U32_LE,
00138         SND_PCM_FORMAT_U32_BE,
00140         SND_PCM_FORMAT_FLOAT_LE,
00142         SND_PCM_FORMAT_FLOAT_BE,
00144         SND_PCM_FORMAT_FLOAT64_LE,
00146         SND_PCM_FORMAT_FLOAT64_BE,
00148         SND_PCM_FORMAT_IEC958_SUBFRAME_LE,
00150         SND_PCM_FORMAT_IEC958_SUBFRAME_BE,
00152         SND_PCM_FORMAT_MU_LAW,
00154         SND_PCM_FORMAT_A_LAW,
00156         SND_PCM_FORMAT_IMA_ADPCM,
00158         SND_PCM_FORMAT_MPEG,
00160         SND_PCM_FORMAT_GSM,
00162         SND_PCM_FORMAT_SPECIAL = 31,
00164         SND_PCM_FORMAT_S24_3LE = 32,
00166         SND_PCM_FORMAT_S24_3BE,
00168         SND_PCM_FORMAT_U24_3LE,
00170         SND_PCM_FORMAT_U24_3BE,
00172         SND_PCM_FORMAT_S20_3LE,
00174         SND_PCM_FORMAT_S20_3BE,
00176         SND_PCM_FORMAT_U20_3LE,
00178         SND_PCM_FORMAT_U20_3BE,
00180         SND_PCM_FORMAT_S18_3LE,
00182         SND_PCM_FORMAT_S18_3BE,
00184         SND_PCM_FORMAT_U18_3LE,
00186         SND_PCM_FORMAT_U18_3BE,
00187         SND_PCM_FORMAT_LAST = SND_PCM_FORMAT_U18_3BE,
00188 
00189 #if __BYTE_ORDER == __LITTLE_ENDIAN
00190 
00191         SND_PCM_FORMAT_S16 = SND_PCM_FORMAT_S16_LE,
00193         SND_PCM_FORMAT_U16 = SND_PCM_FORMAT_U16_LE,
00195         SND_PCM_FORMAT_S24 = SND_PCM_FORMAT_S24_LE,
00197         SND_PCM_FORMAT_U24 = SND_PCM_FORMAT_U24_LE,
00199         SND_PCM_FORMAT_S32 = SND_PCM_FORMAT_S32_LE,
00201         SND_PCM_FORMAT_U32 = SND_PCM_FORMAT_U32_LE,
00203         SND_PCM_FORMAT_FLOAT = SND_PCM_FORMAT_FLOAT_LE,
00205         SND_PCM_FORMAT_FLOAT64 = SND_PCM_FORMAT_FLOAT64_LE,
00207         SND_PCM_FORMAT_IEC958_SUBFRAME = SND_PCM_FORMAT_IEC958_SUBFRAME_LE
00208 #elif __BYTE_ORDER == __BIG_ENDIAN
00209 
00210         SND_PCM_FORMAT_S16 = SND_PCM_FORMAT_S16_BE,
00212         SND_PCM_FORMAT_U16 = SND_PCM_FORMAT_U16_BE,
00214         SND_PCM_FORMAT_S24 = SND_PCM_FORMAT_S24_BE,
00216         SND_PCM_FORMAT_U24 = SND_PCM_FORMAT_U24_BE,
00218         SND_PCM_FORMAT_S32 = SND_PCM_FORMAT_S32_BE,
00220         SND_PCM_FORMAT_U32 = SND_PCM_FORMAT_U32_BE,
00222         SND_PCM_FORMAT_FLOAT = SND_PCM_FORMAT_FLOAT_BE,
00224         SND_PCM_FORMAT_FLOAT64 = SND_PCM_FORMAT_FLOAT64_BE,
00226         SND_PCM_FORMAT_IEC958_SUBFRAME = SND_PCM_FORMAT_IEC958_SUBFRAME_BE
00227 #else
00228 #error "Unknown endian"
00229 #endif
00230 } snd_pcm_format_t;
00231 
00233 typedef enum _snd_pcm_subformat {
00235         SND_PCM_SUBFORMAT_STD = 0,
00236         SND_PCM_SUBFORMAT_LAST = SND_PCM_SUBFORMAT_STD
00237 } snd_pcm_subformat_t;
00238 
00240 typedef enum _snd_pcm_state {
00242         SND_PCM_STATE_OPEN = 0,
00244         SND_PCM_STATE_SETUP,
00246         SND_PCM_STATE_PREPARED,
00248         SND_PCM_STATE_RUNNING,
00250         SND_PCM_STATE_XRUN,
00252         SND_PCM_STATE_DRAINING,
00254         SND_PCM_STATE_PAUSED,
00256         SND_PCM_STATE_SUSPENDED,
00257         SND_PCM_STATE_LAST = SND_PCM_STATE_SUSPENDED
00258 } snd_pcm_state_t;
00259 
00261 typedef enum _snd_pcm_start {
00263         SND_PCM_START_DATA = 0,
00265         SND_PCM_START_EXPLICIT,
00266         SND_PCM_START_LAST = SND_PCM_START_EXPLICIT
00267 } snd_pcm_start_t;
00268 
00270 typedef enum _snd_pcm_xrun {
00272         SND_PCM_XRUN_NONE = 0,
00274         SND_PCM_XRUN_STOP,
00275         SND_PCM_XRUN_LAST = SND_PCM_XRUN_STOP
00276 } snd_pcm_xrun_t;
00277 
00279 typedef enum _snd_pcm_tstamp {
00281         SND_PCM_TSTAMP_NONE = 0,
00283         SND_PCM_TSTAMP_MMAP,
00284         SND_PCM_TSTAMP_LAST = SND_PCM_TSTAMP_MMAP
00285 } snd_pcm_tstamp_t;
00286 
00288 typedef unsigned long snd_pcm_uframes_t;
00290 typedef long snd_pcm_sframes_t;
00292 typedef struct timeval snd_timestamp_t;
00293 
00295 #define SND_PCM_NONBLOCK                0x0001
00296 
00297 #define SND_PCM_ASYNC                   0x0002
00298 
00300 typedef struct _snd_pcm snd_pcm_t;
00301 
00303 enum _snd_pcm_type {
00305         SND_PCM_TYPE_HW = 0,
00307         SND_PCM_TYPE_HOOKS,
00310         SND_PCM_TYPE_MULTI,
00312         SND_PCM_TYPE_FILE,
00314         SND_PCM_TYPE_NULL,
00316         SND_PCM_TYPE_SHM,
00318         SND_PCM_TYPE_INET,
00320         SND_PCM_TYPE_COPY,
00322         SND_PCM_TYPE_LINEAR,
00324         SND_PCM_TYPE_ALAW,
00326         SND_PCM_TYPE_MULAW,
00328         SND_PCM_TYPE_ADPCM,
00330         SND_PCM_TYPE_RATE,
00332         SND_PCM_TYPE_ROUTE,
00334         SND_PCM_TYPE_PLUG,
00336         SND_PCM_TYPE_SHARE,
00338         SND_PCM_TYPE_METER,
00340         SND_PCM_TYPE_MIX,
00342         SND_PCM_TYPE_DROUTE,
00344         SND_PCM_TYPE_LBSERVER,
00346         SND_PCM_TYPE_LINEAR_FLOAT,
00348         SND_PCM_TYPE_LADSPA
00349 };
00350 
00352 typedef enum _snd_pcm_type snd_pcm_type_t;
00353 
00355 typedef struct _snd_pcm_channel_area {
00357         void *addr;
00359         unsigned int first;
00361         unsigned int step;
00362 } snd_pcm_channel_area_t;
00363 
00365 typedef union _snd_pcm_sync_id {
00367         unsigned char id[16];
00369         unsigned short id16[8];
00371         unsigned int id32[4];
00372 } snd_pcm_sync_id_t;
00373 
00375 typedef struct _snd_pcm_scope snd_pcm_scope_t;
00376 
00377 int snd_pcm_open(snd_pcm_t **pcm, const char *name, 
00378                  snd_pcm_stream_t stream, int mode);
00379 int snd_pcm_open_lconf(snd_pcm_t **pcm, const char *name, 
00380                        snd_pcm_stream_t stream, int mode,
00381                        snd_config_t *lconf);
00382 
00383 int snd_pcm_close(snd_pcm_t *pcm);
00384 const char *snd_pcm_name(snd_pcm_t *pcm);
00385 snd_pcm_type_t snd_pcm_type(snd_pcm_t *pcm);
00386 snd_pcm_stream_t snd_pcm_stream(snd_pcm_t *pcm);
00387 int snd_pcm_poll_descriptors_count(snd_pcm_t *pcm);
00388 int snd_pcm_poll_descriptors(snd_pcm_t *pcm, struct pollfd *pfds, unsigned int space);
00389 int snd_pcm_poll_descriptors_revents(snd_pcm_t *pcm, struct pollfd *pfds, unsigned int nfds, unsigned short *revents);
00390 int snd_pcm_nonblock(snd_pcm_t *pcm, int nonblock);
00391 int snd_async_add_pcm_handler(snd_async_handler_t **handler, snd_pcm_t *pcm, 
00392                               snd_async_callback_t callback, void *private_data);
00393 snd_pcm_t *snd_async_handler_get_pcm(snd_async_handler_t *handler);
00394 int snd_pcm_info(snd_pcm_t *pcm, snd_pcm_info_t *info);
00395 int snd_pcm_hw_params_current(snd_pcm_t *pcm, snd_pcm_hw_params_t *params);
00396 int snd_pcm_hw_params(snd_pcm_t *pcm, snd_pcm_hw_params_t *params);
00397 int snd_pcm_hw_free(snd_pcm_t *pcm);
00398 int snd_pcm_sw_params_current(snd_pcm_t *pcm, snd_pcm_sw_params_t *params);
00399 int snd_pcm_sw_params(snd_pcm_t *pcm, snd_pcm_sw_params_t *params);
00400 int snd_pcm_prepare(snd_pcm_t *pcm);
00401 int snd_pcm_reset(snd_pcm_t *pcm);
00402 int snd_pcm_status(snd_pcm_t *pcm, snd_pcm_status_t *status);
00403 int snd_pcm_start(snd_pcm_t *pcm);
00404 int snd_pcm_drop(snd_pcm_t *pcm);
00405 int snd_pcm_drain(snd_pcm_t *pcm);
00406 int snd_pcm_pause(snd_pcm_t *pcm, int enable);
00407 snd_pcm_state_t snd_pcm_state(snd_pcm_t *pcm);
00408 int snd_pcm_hwsync(snd_pcm_t *pcm);
00409 int snd_pcm_delay(snd_pcm_t *pcm, snd_pcm_sframes_t *delayp);
00410 int snd_pcm_resume(snd_pcm_t *pcm);
00411 snd_pcm_sframes_t snd_pcm_avail_update(snd_pcm_t *pcm);
00412 snd_pcm_sframes_t snd_pcm_rewind(snd_pcm_t *pcm, snd_pcm_uframes_t frames);
00413 snd_pcm_sframes_t snd_pcm_writei(snd_pcm_t *pcm, const void *buffer, snd_pcm_uframes_t size);
00414 snd_pcm_sframes_t snd_pcm_readi(snd_pcm_t *pcm, void *buffer, snd_pcm_uframes_t size);
00415 snd_pcm_sframes_t snd_pcm_writen(snd_pcm_t *pcm, void **bufs, snd_pcm_uframes_t size);
00416 snd_pcm_sframes_t snd_pcm_readn(snd_pcm_t *pcm, void **bufs, snd_pcm_uframes_t size);
00417 int snd_pcm_wait(snd_pcm_t *pcm, int timeout);
00418 
00419 int snd_pcm_link(snd_pcm_t *pcm1, snd_pcm_t *pcm2);
00420 int snd_pcm_unlink(snd_pcm_t *pcm);
00421 
00431 size_t snd_pcm_info_sizeof(void);
00436 #define snd_pcm_info_alloca(ptr) do { assert(ptr); *ptr = (snd_pcm_info_t *) alloca(snd_pcm_info_sizeof()); memset(*ptr, 0, snd_pcm_info_sizeof()); } while (0)
00437 int snd_pcm_info_malloc(snd_pcm_info_t **ptr);
00438 void snd_pcm_info_free(snd_pcm_info_t *obj);
00439 void snd_pcm_info_copy(snd_pcm_info_t *dst, const snd_pcm_info_t *src);
00440 unsigned int snd_pcm_info_get_device(const snd_pcm_info_t *obj);
00441 unsigned int snd_pcm_info_get_subdevice(const snd_pcm_info_t *obj);
00442 snd_pcm_stream_t snd_pcm_info_get_stream(const snd_pcm_info_t *obj);
00443 int snd_pcm_info_get_card(const snd_pcm_info_t *obj);
00444 const char *snd_pcm_info_get_id(const snd_pcm_info_t *obj);
00445 const char *snd_pcm_info_get_name(const snd_pcm_info_t *obj);
00446 const char *snd_pcm_info_get_subdevice_name(const snd_pcm_info_t *obj);
00447 snd_pcm_class_t snd_pcm_info_get_class(const snd_pcm_info_t *obj);
00448 snd_pcm_subclass_t snd_pcm_info_get_subclass(const snd_pcm_info_t *obj);
00449 unsigned int snd_pcm_info_get_subdevices_count(const snd_pcm_info_t *obj);
00450 unsigned int snd_pcm_info_get_subdevices_avail(const snd_pcm_info_t *obj);
00451 snd_pcm_sync_id_t snd_pcm_info_get_sync(const snd_pcm_info_t *obj);
00452 void snd_pcm_info_set_device(snd_pcm_info_t *obj, unsigned int val);
00453 void snd_pcm_info_set_subdevice(snd_pcm_info_t *obj, unsigned int val);
00454 void snd_pcm_info_set_stream(snd_pcm_info_t *obj, snd_pcm_stream_t val);
00455 
00465 int snd_pcm_hw_params_any(snd_pcm_t *pcm, snd_pcm_hw_params_t *params);
00466 
00467 int snd_pcm_hw_params_can_mmap_sample_resolution(const snd_pcm_hw_params_t *params);
00468 int snd_pcm_hw_params_is_double(const snd_pcm_hw_params_t *params);
00469 int snd_pcm_hw_params_is_batch(const snd_pcm_hw_params_t *params);
00470 int snd_pcm_hw_params_is_block_transfer(const snd_pcm_hw_params_t *params);
00471 int snd_pcm_hw_params_can_overrange(const snd_pcm_hw_params_t *params);
00472 int snd_pcm_hw_params_can_pause(const snd_pcm_hw_params_t *params);
00473 int snd_pcm_hw_params_can_resume(const snd_pcm_hw_params_t *params);
00474 int snd_pcm_hw_params_is_half_duplex(const snd_pcm_hw_params_t *params);
00475 int snd_pcm_hw_params_is_joint_duplex(const snd_pcm_hw_params_t *params);
00476 int snd_pcm_hw_params_can_sync_start(const snd_pcm_hw_params_t *params);
00477 int snd_pcm_hw_params_get_rate_numden(const snd_pcm_hw_params_t *params,
00478                                       unsigned int *rate_num,
00479                                       unsigned int *rate_den);
00480 int snd_pcm_hw_params_get_sbits(const snd_pcm_hw_params_t *params);
00481 int snd_pcm_hw_params_get_fifo_size(const snd_pcm_hw_params_t *params);
00482 
00483 #if 0
00484 typedef struct _snd_pcm_hw_strategy snd_pcm_hw_strategy_t;
00485 
00486 /* choices need to be sorted on ascending badness */
00487 typedef struct _snd_pcm_hw_strategy_simple_choices_list {
00488         unsigned int value;
00489         unsigned int badness;
00490 } snd_pcm_hw_strategy_simple_choices_list_t;
00491 
00492 int snd_pcm_hw_params_strategy(snd_pcm_t *pcm, snd_pcm_hw_params_t *params,
00493                                const snd_pcm_hw_strategy_t *strategy,
00494                                unsigned int badness_min,
00495                                unsigned int badness_max);
00496 
00497 void snd_pcm_hw_strategy_free(snd_pcm_hw_strategy_t *strategy);
00498 int snd_pcm_hw_strategy_simple(snd_pcm_hw_strategy_t **strategyp,
00499                                unsigned int badness_min,
00500                                unsigned int badness_max);
00501 int snd_pcm_hw_params_try_explain_failure(snd_pcm_t *pcm,
00502                                           snd_pcm_hw_params_t *fail,
00503                                           snd_pcm_hw_params_t *success,
00504                                           unsigned int depth,
00505                                           snd_output_t *out);
00506 
00507 #endif
00508 
00509 size_t snd_pcm_hw_params_sizeof(void);
00514 #define snd_pcm_hw_params_alloca(ptr) do { assert(ptr); *ptr = (snd_pcm_hw_params_t *) alloca(snd_pcm_hw_params_sizeof()); memset(*ptr, 0, snd_pcm_hw_params_sizeof()); } while (0)
00515 int snd_pcm_hw_params_malloc(snd_pcm_hw_params_t **ptr);
00516 void snd_pcm_hw_params_free(snd_pcm_hw_params_t *obj);
00517 void snd_pcm_hw_params_copy(snd_pcm_hw_params_t *dst, const snd_pcm_hw_params_t *src);
00518 
00519 #ifndef ALSA_LIBRARY_BUILD
00520 #ifdef ALSA_PCM_NEW_HW_PARAMS_API
00521 
00522 int snd_pcm_hw_params_get_access(const snd_pcm_hw_params_t *params, snd_pcm_access_t *access) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_access")));
00523 int snd_pcm_hw_params_test_access(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_access_t access);
00524 int snd_pcm_hw_params_set_access(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_access_t access);
00525 int snd_pcm_hw_params_set_access_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_access_t *access) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_access_last")));
00526 int snd_pcm_hw_params_set_access_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_access_t *access) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_access_last")));
00527 int snd_pcm_hw_params_set_access_mask(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_access_mask_t *mask);
00528 int snd_pcm_hw_params_get_access_mask(snd_pcm_hw_params_t *params, snd_pcm_access_mask_t *mask);
00529 
00530 int snd_pcm_hw_params_get_format(const snd_pcm_hw_params_t *params, snd_pcm_format_t *val) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_format")));
00531 int snd_pcm_hw_params_test_format(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_format_t val);
00532 int snd_pcm_hw_params_set_format(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_format_t val);
00533 int snd_pcm_hw_params_set_format_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_format_t *format) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_format_first")));
00534 int snd_pcm_hw_params_set_format_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_format_t *format) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_format_last")));
00535 int snd_pcm_hw_params_set_format_mask(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_format_mask_t *mask);
00536 void snd_pcm_hw_params_get_format_mask(snd_pcm_hw_params_t *params, snd_pcm_format_mask_t *mask);
00537 
00538 int snd_pcm_hw_params_get_subformat(const snd_pcm_hw_params_t *params, snd_pcm_subformat_t *subformat) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_subformat")));
00539 int snd_pcm_hw_params_test_subformat(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_subformat_t subformat);
00540 int snd_pcm_hw_params_set_subformat(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_subformat_t subformat);
00541 int snd_pcm_hw_params_set_subformat_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_subformat_t *subformat) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_subformat_first")));
00542 int snd_pcm_hw_params_set_subformat_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_subformat_t *subformat) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_subformat_last")));
00543 int snd_pcm_hw_params_set_subformat_mask(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_subformat_mask_t *mask);
00544 void snd_pcm_hw_params_get_subformat_mask(snd_pcm_hw_params_t *params, snd_pcm_subformat_mask_t *mask);
00545 
00546 int snd_pcm_hw_params_get_channels(const snd_pcm_hw_params_t *params, unsigned int *val) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_channels")));
00547 int snd_pcm_hw_params_get_channels_min(const snd_pcm_hw_params_t *params, unsigned int *val) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_channels_min")));
00548 int snd_pcm_hw_params_get_channels_max(const snd_pcm_hw_params_t *params, unsigned int *val) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_channels_max")));
00549 int snd_pcm_hw_params_test_channels(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val);
00550 int snd_pcm_hw_params_set_channels(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val);
00551 int snd_pcm_hw_params_set_channels_min(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val);
00552 int snd_pcm_hw_params_set_channels_max(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val);
00553 int snd_pcm_hw_params_set_channels_minmax(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *min, unsigned int *max);
00554 int snd_pcm_hw_params_set_channels_near(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_channels_near")));
00555 int snd_pcm_hw_params_set_channels_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_channels_first")));
00556 int snd_pcm_hw_params_set_channels_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_channels_last")));
00557 
00558 int snd_pcm_hw_params_get_rate(const snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_rate")));
00559 int snd_pcm_hw_params_get_rate_min(const snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_rate_min")));
00560 int snd_pcm_hw_params_get_rate_max(const snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_rate_max")));
00561 int snd_pcm_hw_params_test_rate(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00562 int snd_pcm_hw_params_set_rate(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00563 int snd_pcm_hw_params_set_rate_min(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00564 int snd_pcm_hw_params_set_rate_max(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00565 int snd_pcm_hw_params_set_rate_minmax(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *min, int *mindir, unsigned int *max, int *maxdir);
00566 int snd_pcm_hw_params_set_rate_near(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_rate_near")));
00567 int snd_pcm_hw_params_set_rate_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_rate_first")));
00568 int snd_pcm_hw_params_set_rate_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_rate_last")));
00569 
00570 int snd_pcm_hw_params_get_period_time(const snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_period_time")));
00571 int snd_pcm_hw_params_get_period_time_min(const snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_period_time_min")));
00572 int snd_pcm_hw_params_get_period_time_max(const snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_period_time_max")));
00573 int snd_pcm_hw_params_test_period_time(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00574 int snd_pcm_hw_params_set_period_time(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00575 int snd_pcm_hw_params_set_period_time_min(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00576 int snd_pcm_hw_params_set_period_time_max(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00577 int snd_pcm_hw_params_set_period_time_minmax(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *min, int *mindir, unsigned int *max, int *maxdir);
00578 int snd_pcm_hw_params_set_period_time_near(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_period_time_near")));
00579 int snd_pcm_hw_params_set_period_time_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_period_time_first")));
00580 int snd_pcm_hw_params_set_period_time_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_period_time_last")));
00581 
00582 int snd_pcm_hw_params_get_period_size(const snd_pcm_hw_params_t *params, snd_pcm_uframes_t *frames, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_period_size")));
00583 int snd_pcm_hw_params_get_period_size_min(const snd_pcm_hw_params_t *params, snd_pcm_uframes_t *frames, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_period_size_min")));
00584 int snd_pcm_hw_params_get_period_size_max(const snd_pcm_hw_params_t *params, snd_pcm_uframes_t *frames, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_period_size_max"))); 
00585 int snd_pcm_hw_params_test_period_size(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t val, int dir);
00586 int snd_pcm_hw_params_set_period_size(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t val, int dir);
00587 int snd_pcm_hw_params_set_period_size_min(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val, int *dir);
00588 int snd_pcm_hw_params_set_period_size_max(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val, int *dir);
00589 int snd_pcm_hw_params_set_period_size_minmax(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *min, int *mindir, snd_pcm_uframes_t *max, int *maxdir);
00590 int snd_pcm_hw_params_set_period_size_near(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_period_size_near")));
00591 int snd_pcm_hw_params_set_period_size_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_period_size_first")));
00592 int snd_pcm_hw_params_set_period_size_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_period_size_last")));
00593 int snd_pcm_hw_params_set_period_size_integer(snd_pcm_t *pcm, snd_pcm_hw_params_t *params);
00594 
00595 int snd_pcm_hw_params_get_periods(const snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_periods")));
00596 int snd_pcm_hw_params_get_periods_min(const snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_periods_min")));
00597 int snd_pcm_hw_params_get_periods_max(const snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_periods_max")));
00598 int snd_pcm_hw_params_test_periods(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00599 int snd_pcm_hw_params_set_periods(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00600 int snd_pcm_hw_params_set_periods_min(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00601 int snd_pcm_hw_params_set_periods_max(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00602 int snd_pcm_hw_params_set_periods_minmax(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *min, int *mindir, unsigned int *max, int *maxdir);
00603 int snd_pcm_hw_params_set_periods_near(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir)  __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_periods_near")));
00604 int snd_pcm_hw_params_set_periods_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir)  __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_periods_first")));
00605 int snd_pcm_hw_params_set_periods_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir)  __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_periods_last")));
00606 int snd_pcm_hw_params_set_periods_integer(snd_pcm_t *pcm, snd_pcm_hw_params_t *params);
00607 
00608 int snd_pcm_hw_params_get_buffer_time(const snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_buffer_time")));
00609 int snd_pcm_hw_params_get_buffer_time_min(const snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_buffer_time_min")));
00610 int snd_pcm_hw_params_get_buffer_time_max(const snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_buffer_time_max")));
00611 int snd_pcm_hw_params_test_buffer_time(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00612 int snd_pcm_hw_params_set_buffer_time(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00613 int snd_pcm_hw_params_set_buffer_time_min(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00614 int snd_pcm_hw_params_set_buffer_time_max(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00615 int snd_pcm_hw_params_set_buffer_time_minmax(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *min, int *mindir, unsigned int *max, int *maxdir);
00616 int snd_pcm_hw_params_set_buffer_time_near(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_buffer_time_near")));
00617 int snd_pcm_hw_params_set_buffer_time_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_buffer_time_first")));
00618 int snd_pcm_hw_params_set_buffer_time_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_buffer_time_last")));
00619 
00620 int snd_pcm_hw_params_get_buffer_size(const snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_buffer_size")));
00621 int snd_pcm_hw_params_get_buffer_size_min(const snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_buffer_size_min")));
00622 int snd_pcm_hw_params_get_buffer_size_max(const snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_buffer_size_max")));
00623 int snd_pcm_hw_params_test_buffer_size(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t val);
00624 int snd_pcm_hw_params_set_buffer_size(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t val);
00625 int snd_pcm_hw_params_set_buffer_size_min(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val);
00626 int snd_pcm_hw_params_set_buffer_size_max(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val);
00627 int snd_pcm_hw_params_set_buffer_size_minmax(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *min, snd_pcm_uframes_t *max);
00628 int snd_pcm_hw_params_set_buffer_size_near(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_buffer_size_near")));
00629 int snd_pcm_hw_params_set_buffer_size_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_buffer_size_first")));
00630 int snd_pcm_hw_params_set_buffer_size_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_buffer_size_last")));
00631 
00632 int snd_pcm_hw_params_get_tick_time(const snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_tick_time")));
00633 int snd_pcm_hw_params_get_tick_time_min(const snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_tick_time_min")));
00634 int snd_pcm_hw_params_get_tick_time_max(const snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_get_tick_time_max")));
00635 int snd_pcm_hw_params_test_tick_time(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00636 int snd_pcm_hw_params_set_tick_time(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00637 int snd_pcm_hw_params_set_tick_time_min(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00638 int snd_pcm_hw_params_set_tick_time_max(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00639 int snd_pcm_hw_params_set_tick_time_minmax(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *min, int *mindir, unsigned int *max, int *maxdir);
00640 int snd_pcm_hw_params_set_tick_time_near(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_tick_time_near")));
00641 int snd_pcm_hw_params_set_tick_time_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_tick_time_first")));
00642 int snd_pcm_hw_params_set_tick_time_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir) __attribute__ ((weak, alias ("__snd_pcm_hw_params_set_tick_time_last")));
00643 
00644 #else
00645 
00646 int snd_pcm_hw_params_get_access(const snd_pcm_hw_params_t *params);
00647 int snd_pcm_hw_params_test_access(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_access_t val);
00648 int snd_pcm_hw_params_set_access(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_access_t val);
00649 snd_pcm_access_t snd_pcm_hw_params_set_access_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params);
00650 snd_pcm_access_t snd_pcm_hw_params_set_access_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params);
00651 int snd_pcm_hw_params_set_access_mask(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_access_mask_t *mask);
00652 void snd_pcm_hw_params_get_access_mask(snd_pcm_hw_params_t *params, snd_pcm_access_mask_t *mask);
00653 
00654 int snd_pcm_hw_params_get_format(const snd_pcm_hw_params_t *params);
00655 int snd_pcm_hw_params_test_format(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_format_t val);
00656 int snd_pcm_hw_params_set_format(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_format_t val);
00657 snd_pcm_format_t snd_pcm_hw_params_set_format_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params);
00658 snd_pcm_format_t snd_pcm_hw_params_set_format_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params);
00659 int snd_pcm_hw_params_set_format_mask(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_format_mask_t *mask);
00660 void snd_pcm_hw_params_get_format_mask(snd_pcm_hw_params_t *params, snd_pcm_format_mask_t *mask);
00661 
00662 int snd_pcm_hw_params_test_subformat(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_subformat_t val);
00663 int snd_pcm_hw_params_get_subformat(const snd_pcm_hw_params_t *params);
00664 int snd_pcm_hw_params_set_subformat(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_subformat_t val);
00665 snd_pcm_subformat_t snd_pcm_hw_params_set_subformat_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params);
00666 snd_pcm_subformat_t snd_pcm_hw_params_set_subformat_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params);
00667 int snd_pcm_hw_params_set_subformat_mask(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_subformat_mask_t *mask);
00668 void snd_pcm_hw_params_get_subformat_mask(snd_pcm_hw_params_t *params, snd_pcm_subformat_mask_t *mask);
00669 
00670 int snd_pcm_hw_params_get_channels(const snd_pcm_hw_params_t *params);
00671 unsigned int snd_pcm_hw_params_get_channels_min(const snd_pcm_hw_params_t *params);
00672 unsigned int snd_pcm_hw_params_get_channels_max(const snd_pcm_hw_params_t *params);
00673 int snd_pcm_hw_params_test_channels(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val);
00674 int snd_pcm_hw_params_set_channels(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val);
00675 int snd_pcm_hw_params_set_channels_min(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val);
00676 int snd_pcm_hw_params_set_channels_max(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val);
00677 int snd_pcm_hw_params_set_channels_minmax(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *min, unsigned int *max);
00678 unsigned int snd_pcm_hw_params_set_channels_near(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val);
00679 unsigned int snd_pcm_hw_params_set_channels_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params);
00680 unsigned int snd_pcm_hw_params_set_channels_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params);
00681 
00682 int snd_pcm_hw_params_get_rate(const snd_pcm_hw_params_t *params, int *dir);
00683 unsigned int snd_pcm_hw_params_get_rate_min(const snd_pcm_hw_params_t *params, int *dir);
00684 unsigned int snd_pcm_hw_params_get_rate_max(const snd_pcm_hw_params_t *params, int *dir);
00685 int snd_pcm_hw_params_test_rate(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00686 int snd_pcm_hw_params_set_rate(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00687 int snd_pcm_hw_params_set_rate_min(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00688 int snd_pcm_hw_params_set_rate_max(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00689 int snd_pcm_hw_params_set_rate_minmax(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *min, int *mindir, unsigned int *max, int *maxdir);
00690 unsigned int snd_pcm_hw_params_set_rate_near(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int *dir);
00691 unsigned int snd_pcm_hw_params_set_rate_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, int *dir);
00692 unsigned int snd_pcm_hw_params_set_rate_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, int *dir);
00693 
00694 int snd_pcm_hw_params_get_period_time(const snd_pcm_hw_params_t *params, int *dir);
00695 unsigned int snd_pcm_hw_params_get_period_time_min(const snd_pcm_hw_params_t *params, int *dir);
00696 unsigned int snd_pcm_hw_params_get_period_time_max(const snd_pcm_hw_params_t *params, int *dir);
00697 int snd_pcm_hw_params_test_period_time(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00698 int snd_pcm_hw_params_set_period_time(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00699 int snd_pcm_hw_params_set_period_time_min(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00700 int snd_pcm_hw_params_set_period_time_max(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00701 int snd_pcm_hw_params_set_period_time_minmax(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *min, int *mindir, unsigned int *max, int *maxdir);
00702 unsigned int snd_pcm_hw_params_set_period_time_near(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int *dir);
00703 unsigned int snd_pcm_hw_params_set_period_time_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, int *dir);
00704 unsigned int snd_pcm_hw_params_set_period_time_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, int *dir);
00705 
00706 snd_pcm_sframes_t snd_pcm_hw_params_get_period_size(const snd_pcm_hw_params_t *params, int *dir);
00707 snd_pcm_uframes_t snd_pcm_hw_params_get_period_size_min(const snd_pcm_hw_params_t *params, int *dir);
00708 snd_pcm_uframes_t snd_pcm_hw_params_get_period_size_max(const snd_pcm_hw_params_t *params, int *dir);
00709 int snd_pcm_hw_params_test_period_size(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t val, int dir);
00710 int snd_pcm_hw_params_set_period_size(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t val, int dir);
00711 int snd_pcm_hw_params_set_period_size_min(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val, int *dir);
00712 int snd_pcm_hw_params_set_period_size_max(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val, int *dir);
00713 int snd_pcm_hw_params_set_period_size_minmax(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *min, int *mindir, snd_pcm_uframes_t *max, int *maxdir);
00714 snd_pcm_uframes_t snd_pcm_hw_params_set_period_size_near(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t val, int *dir);
00715 snd_pcm_uframes_t snd_pcm_hw_params_set_period_size_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, int *dir);
00716 snd_pcm_uframes_t snd_pcm_hw_params_set_period_size_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, int *dir);
00717 int snd_pcm_hw_params_set_period_size_integer(snd_pcm_t *pcm, snd_pcm_hw_params_t *params);
00718 
00719 int snd_pcm_hw_params_get_periods(const snd_pcm_hw_params_t *params, int *dir);
00720 unsigned int snd_pcm_hw_params_get_periods_min(const snd_pcm_hw_params_t *params, int *dir);
00721 unsigned int snd_pcm_hw_params_get_periods_max(const snd_pcm_hw_params_t *params, int *dir);
00722 int snd_pcm_hw_params_test_periods(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00723 int snd_pcm_hw_params_set_periods(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00724 int snd_pcm_hw_params_set_periods_min(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00725 int snd_pcm_hw_params_set_periods_max(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00726 int snd_pcm_hw_params_set_periods_minmax(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *min, int *mindir, unsigned int *max, int *maxdir);
00727 unsigned int snd_pcm_hw_params_set_periods_near(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int *dir);
00728 unsigned int snd_pcm_hw_params_set_periods_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, int *dir);
00729 unsigned int snd_pcm_hw_params_set_periods_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, int *dir);
00730 int snd_pcm_hw_params_set_periods_integer(snd_pcm_t *pcm, snd_pcm_hw_params_t *params);
00731 
00732 int snd_pcm_hw_params_get_buffer_time(const snd_pcm_hw_params_t *params, int *dir);
00733 unsigned int snd_pcm_hw_params_get_buffer_time_min(const snd_pcm_hw_params_t *params, int *dir);
00734 unsigned int snd_pcm_hw_params_get_buffer_time_max(const snd_pcm_hw_params_t *params, int *dir);
00735 int snd_pcm_hw_params_test_buffer_time(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00736 int snd_pcm_hw_params_set_buffer_time(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00737 int snd_pcm_hw_params_set_buffer_time_min(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00738 int snd_pcm_hw_params_set_buffer_time_max(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00739 int snd_pcm_hw_params_set_buffer_time_minmax(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *min, int *mindir, unsigned int *max, int *maxdir);
00740 unsigned int snd_pcm_hw_params_set_buffer_time_near(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int *dir);
00741 unsigned int snd_pcm_hw_params_set_buffer_time_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, int *dir);
00742 unsigned int snd_pcm_hw_params_set_buffer_time_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, int *dir);
00743 
00744 snd_pcm_sframes_t snd_pcm_hw_params_get_buffer_size(const snd_pcm_hw_params_t *params);
00745 snd_pcm_uframes_t snd_pcm_hw_params_get_buffer_size_min(const snd_pcm_hw_params_t *params);
00746 snd_pcm_uframes_t snd_pcm_hw_params_get_buffer_size_max(const snd_pcm_hw_params_t *params);
00747 int snd_pcm_hw_params_test_buffer_size(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t val);
00748 int snd_pcm_hw_params_set_buffer_size(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t val);
00749 int snd_pcm_hw_params_set_buffer_size_min(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val);
00750 int snd_pcm_hw_params_set_buffer_size_max(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val);
00751 int snd_pcm_hw_params_set_buffer_size_minmax(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t *min, snd_pcm_uframes_t *max);
00752 snd_pcm_uframes_t snd_pcm_hw_params_set_buffer_size_near(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, snd_pcm_uframes_t val);
00753 snd_pcm_uframes_t snd_pcm_hw_params_set_buffer_size_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params);
00754 snd_pcm_uframes_t snd_pcm_hw_params_set_buffer_size_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params);
00755 
00756 int snd_pcm_hw_params_get_tick_time(const snd_pcm_hw_params_t *params, int *dir);
00757 unsigned int snd_pcm_hw_params_get_tick_time_min(const snd_pcm_hw_params_t *params, int *dir);
00758 unsigned int snd_pcm_hw_params_get_tick_time_max(const snd_pcm_hw_params_t *params, int *dir);
00759 int snd_pcm_hw_params_test_tick_time(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00760 int snd_pcm_hw_params_set_tick_time(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int dir);
00761 int snd_pcm_hw_params_set_tick_time_min(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00762 int snd_pcm_hw_params_set_tick_time_max(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *val, int *dir);
00763 int snd_pcm_hw_params_set_tick_time_minmax(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int *min, int *mindir, unsigned int *max, int *maxdir);
00764 unsigned int snd_pcm_hw_params_set_tick_time_near(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, unsigned int val, int *dir);
00765 unsigned int snd_pcm_hw_params_set_tick_time_first(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, int *dir);
00766 unsigned int snd_pcm_hw_params_set_tick_time_last(snd_pcm_t *pcm, snd_pcm_hw_params_t *params, int *dir);
00767 
00768 #endif /* ALSA_PCM_NEW_HW_PARAMS_API */
00769 #endif /* ALSA_LIBRARY_BUILD */
00770 
00771 int snd_pcm_hw_params_get_min_align(const snd_pcm_hw_params_t *params, snd_pcm_uframes_t *val);
00772 
00782 size_t snd_pcm_sw_params_sizeof(void);
00787 #define snd_pcm_sw_params_alloca(ptr) do { assert(ptr); *ptr = (snd_pcm_sw_params_t *) alloca(snd_pcm_sw_params_sizeof()); memset(*ptr, 0, snd_pcm_sw_params_sizeof()); } while (0)
00788 int snd_pcm_sw_params_malloc(snd_pcm_sw_params_t **ptr);
00789 void snd_pcm_sw_params_free(snd_pcm_sw_params_t *obj);
00790 void snd_pcm_sw_params_copy(snd_pcm_sw_params_t *dst, const snd_pcm_sw_params_t *src);
00791 
00792 #ifndef ALSA_LIBRARY_BUILD
00793 #ifdef ALSA_PCM_NEW_SW_PARAMS_API
00794 
00795 int snd_pcm_sw_params_set_tstamp_mode(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_tstamp_t val);
00796 int snd_pcm_sw_params_get_tstamp_mode(const snd_pcm_sw_params_t *params, snd_pcm_tstamp_t *val) __attribute__ ((weak, alias ("__snd_pcm_sw_params_get_tstamp_mode")));
00797 int snd_pcm_sw_params_set_sleep_min(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, unsigned int val);
00798 int snd_pcm_sw_params_get_sleep_min(const snd_pcm_sw_params_t *params, unsigned int *val)  __attribute__ ((weak, alias ("__snd_pcm_sw_params_get_sleep_min")));
00799 int snd_pcm_sw_params_set_avail_min(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_uframes_t val);
00800 int snd_pcm_sw_params_get_avail_min(const snd_pcm_sw_params_t *params, snd_pcm_uframes_t *val)  __attribute__ ((weak, alias ("__snd_pcm_sw_params_get_avail_min")));
00801 int snd_pcm_sw_params_set_xfer_align(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_uframes_t val);
00802 int snd_pcm_sw_params_get_xfer_align(const snd_pcm_sw_params_t *params, snd_pcm_uframes_t *val) __attribute__ ((weak, alias ("__snd_pcm_sw_params_get_xfer_align")));;
00803 int snd_pcm_sw_params_set_start_threshold(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_uframes_t val);
00804 int snd_pcm_sw_params_get_start_threshold(const snd_pcm_sw_params_t *paramsm, snd_pcm_uframes_t *val) __attribute__ ((weak, alias ("__snd_pcm_sw_params_get_start_threshold")));;
00805 int snd_pcm_sw_params_set_stop_threshold(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_uframes_t val);
00806 int snd_pcm_sw_params_get_stop_threshold(const snd_pcm_sw_params_t *params, snd_pcm_uframes_t *val) __attribute__ ((weak, alias ("__snd_pcm_sw_params_get_stop_threshold")));;
00807 int snd_pcm_sw_params_set_silence_threshold(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_uframes_t val);
00808 int snd_pcm_sw_params_get_silence_threshold(const snd_pcm_sw_params_t *params, snd_pcm_uframes_t *val) __attribute__ ((weak, alias ("__snd_pcm_sw_params_get_silence_threshold")));;
00809 int snd_pcm_sw_params_set_silence_size(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_uframes_t val);
00810 int snd_pcm_sw_params_get_silence_size(const snd_pcm_sw_params_t *params, snd_pcm_uframes_t *val) __attribute__ ((weak, alias ("__snd_pcm_sw_params_get_silence_size")));;
00811 
00812 #else
00813 
00814 int snd_pcm_sw_params_set_tstamp_mode(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_tstamp_t val);
00815 snd_pcm_tstamp_t snd_pcm_sw_params_get_tstamp_mode(const snd_pcm_sw_params_t *params);
00816 int snd_pcm_sw_params_set_sleep_min(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, unsigned int val);
00817 unsigned int snd_pcm_sw_params_get_sleep_min(const snd_pcm_sw_params_t *params);
00818 int snd_pcm_sw_params_set_avail_min(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_uframes_t val);
00819 snd_pcm_uframes_t snd_pcm_sw_params_get_avail_min(const snd_pcm_sw_params_t *params);
00820 int snd_pcm_sw_params_set_xfer_align(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_uframes_t val);
00821 snd_pcm_uframes_t snd_pcm_sw_params_get_xfer_align(const snd_pcm_sw_params_t *params);
00822 int snd_pcm_sw_params_set_start_threshold(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_uframes_t val);
00823 snd_pcm_uframes_t snd_pcm_sw_params_get_start_threshold(const snd_pcm_sw_params_t *params);
00824 int snd_pcm_sw_params_set_stop_threshold(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_uframes_t val);
00825 snd_pcm_uframes_t snd_pcm_sw_params_get_stop_threshold(const snd_pcm_sw_params_t *params);
00826 int snd_pcm_sw_params_set_silence_threshold(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_uframes_t val);
00827 snd_pcm_uframes_t snd_pcm_sw_params_get_silence_threshold(const snd_pcm_sw_params_t *params);
00828 int snd_pcm_sw_params_set_silence_size(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_uframes_t val);
00829 snd_pcm_uframes_t snd_pcm_sw_params_get_silence_size(const snd_pcm_sw_params_t *params);
00830 
00831 #endif /* ALSA_PCM_NEW_SW_PARAMS_API */
00832 #endif /* ALSA_LIBRARY_BUILD */
00833 
00843 size_t snd_pcm_access_mask_sizeof(void);
00848 #define snd_pcm_access_mask_alloca(ptr) do { assert(ptr); *ptr = (snd_pcm_access_mask_t *) alloca(snd_pcm_access_mask_sizeof()); memset(*ptr, 0, snd_pcm_access_mask_sizeof()); } while (0)
00849 int snd_pcm_access_mask_malloc(snd_pcm_access_mask_t **ptr);
00850 void snd_pcm_access_mask_free(snd_pcm_access_mask_t *obj);
00851 void snd_pcm_access_mask_copy(snd_pcm_access_mask_t *dst, const snd_pcm_access_mask_t *src);
00852 void snd_pcm_access_mask_none(snd_pcm_access_mask_t *mask);
00853 void snd_pcm_access_mask_any(snd_pcm_access_mask_t *mask);
00854 int snd_pcm_access_mask_test(const snd_pcm_access_mask_t *mask, snd_pcm_access_t val);
00855 int snd_pcm_access_mask_empty(const snd_pcm_access_mask_t *mask);
00856 void snd_pcm_access_mask_set(snd_pcm_access_mask_t *mask, snd_pcm_access_t val);
00857 void snd_pcm_access_mask_reset(snd_pcm_access_mask_t *mask, snd_pcm_access_t val);
00858 
00868 size_t snd_pcm_format_mask_sizeof(void);
00873 #define snd_pcm_format_mask_alloca(ptr) do { assert(ptr); *ptr = (snd_pcm_format_mask_t *) alloca(snd_pcm_format_mask_sizeof()); memset(*ptr, 0, snd_pcm_format_mask_sizeof()); } while (0)
00874 int snd_pcm_format_mask_malloc(snd_pcm_format_mask_t **ptr);
00875 void snd_pcm_format_mask_free(snd_pcm_format_mask_t *obj);
00876 void snd_pcm_format_mask_copy(snd_pcm_format_mask_t *dst, const snd_pcm_format_mask_t *src);
00877 void snd_pcm_format_mask_none(snd_pcm_format_mask_t *mask);
00878 void snd_pcm_format_mask_any(snd_pcm_format_mask_t *mask);
00879 int snd_pcm_format_mask_test(const snd_pcm_format_mask_t *mask, snd_pcm_format_t val);
00880 int snd_pcm_format_mask_empty(const snd_pcm_format_mask_t *mask);
00881 void snd_pcm_format_mask_set(snd_pcm_format_mask_t *mask, snd_pcm_format_t val);
00882 void snd_pcm_format_mask_reset(snd_pcm_format_mask_t *mask, snd_pcm_format_t val);
00883 
00893 size_t snd_pcm_subformat_mask_sizeof(void);
00898 #define snd_pcm_subformat_mask_alloca(ptr) do { assert(ptr); *ptr = (snd_pcm_subformat_mask_t *) alloca(snd_pcm_subformat_mask_sizeof()); memset(*ptr, 0, snd_pcm_subformat_mask_sizeof()); } while (0)
00899 int snd_pcm_subformat_mask_malloc(snd_pcm_subformat_mask_t **ptr);
00900 void snd_pcm_subformat_mask_free(snd_pcm_subformat_mask_t *obj);
00901 void snd_pcm_subformat_mask_copy(snd_pcm_subformat_mask_t *dst, const snd_pcm_subformat_mask_t *src);
00902 void snd_pcm_subformat_mask_none(snd_pcm_subformat_mask_t *mask);
00903 void snd_pcm_subformat_mask_any(snd_pcm_subformat_mask_t *mask);
00904 int snd_pcm_subformat_mask_test(const snd_pcm_subformat_mask_t *mask, snd_pcm_subformat_t val);
00905 int snd_pcm_subformat_mask_empty(const snd_pcm_subformat_mask_t *mask);
00906 void snd_pcm_subformat_mask_set(snd_pcm_subformat_mask_t *mask, snd_pcm_subformat_t val);
00907 void snd_pcm_subformat_mask_reset(snd_pcm_subformat_mask_t *mask, snd_pcm_subformat_t val);
00908 
00918 size_t snd_pcm_status_sizeof(void);
00923 #define snd_pcm_status_alloca(ptr) do { assert(ptr); *ptr = (snd_pcm_status_t *) alloca(snd_pcm_status_sizeof()); memset(*ptr, 0, snd_pcm_status_sizeof()); } while (0)
00924 int snd_pcm_status_malloc(snd_pcm_status_t **ptr);
00925 void snd_pcm_status_free(snd_pcm_status_t *obj);
00926 void snd_pcm_status_copy(snd_pcm_status_t *dst, const snd_pcm_status_t *src);
00927 snd_pcm_state_t snd_pcm_status_get_state(const snd_pcm_status_t *obj);
00928 void snd_pcm_status_get_trigger_tstamp(const snd_pcm_status_t *obj, snd_timestamp_t *ptr);
00929 void snd_pcm_status_get_tstamp(const snd_pcm_status_t *obj, snd_timestamp_t *ptr);
00930 snd_pcm_sframes_t snd_pcm_status_get_delay(const snd_pcm_status_t *obj);
00931 snd_pcm_uframes_t snd_pcm_status_get_avail(const snd_pcm_status_t *obj);
00932 snd_pcm_uframes_t snd_pcm_status_get_avail_max(const snd_pcm_status_t *obj);
00933 snd_pcm_uframes_t snd_pcm_status_get_overrange(const snd_pcm_status_t *obj);
00934 
00944 const char *snd_pcm_stream_name(const snd_pcm_stream_t stream);
00945 const char *snd_pcm_access_name(const snd_pcm_access_t _access);
00946 const char *snd_pcm_format_name(const snd_pcm_format_t format);
00947 const char *snd_pcm_format_description(const snd_pcm_format_t format);
00948 const char *snd_pcm_subformat_name(const snd_pcm_subformat_t subformat);
00949 const char *snd_pcm_subformat_description(const snd_pcm_subformat_t subformat);
00950 snd_pcm_format_t snd_pcm_format_value(const char* name);
00951 const char *snd_pcm_tstamp_mode_name(const snd_pcm_tstamp_t mode);
00952 const char *snd_pcm_state_name(const snd_pcm_state_t state);
00953 
00963 int snd_pcm_dump(snd_pcm_t *pcm, snd_output_t *out);
00964 int snd_pcm_dump_hw_setup(snd_pcm_t *pcm, snd_output_t *out);
00965 int snd_pcm_dump_sw_setup(snd_pcm_t *pcm, snd_output_t *out);
00966 int snd_pcm_dump_setup(snd_pcm_t *pcm, snd_output_t *out);
00967 int snd_pcm_hw_params_dump(snd_pcm_hw_params_t *params, snd_output_t *out);
00968 int snd_pcm_sw_params_dump(snd_pcm_sw_params_t *params, snd_output_t *out);
00969 int snd_pcm_status_dump(snd_pcm_status_t *status, snd_output_t *out);
00970 
00980 int snd_pcm_mmap_begin(snd_pcm_t *pcm,
00981                        const snd_pcm_channel_area_t **areas,
00982                        snd_pcm_uframes_t *offset,
00983                        snd_pcm_uframes_t *frames);
00984 snd_pcm_sframes_t snd_pcm_mmap_commit(snd_pcm_t *pcm,
00985                                       snd_pcm_uframes_t offset,
00986                                       snd_pcm_uframes_t frames);
00987 snd_pcm_sframes_t snd_pcm_mmap_writei(snd_pcm_t *pcm, const void *buffer, snd_pcm_uframes_t size);
00988 snd_pcm_sframes_t snd_pcm_mmap_readi(snd_pcm_t *pcm, void *buffer, snd_pcm_uframes_t size);
00989 snd_pcm_sframes_t snd_pcm_mmap_writen(snd_pcm_t *pcm, void **bufs, snd_pcm_uframes_t size);
00990 snd_pcm_sframes_t snd_pcm_mmap_readn(snd_pcm_t *pcm, void **bufs, snd_pcm_uframes_t size);                                                                
00991 
01001 int snd_pcm_format_signed(snd_pcm_format_t format);
01002 int snd_pcm_format_unsigned(snd_pcm_format_t format);
01003 int snd_pcm_format_linear(snd_pcm_format_t format);
01004 int snd_pcm_format_float(snd_pcm_format_t format);
01005 int snd_pcm_format_little_endian(snd_pcm_format_t format);
01006 int snd_pcm_format_big_endian(snd_pcm_format_t format);
01007 int snd_pcm_format_cpu_endian(snd_pcm_format_t format);
01008 int snd_pcm_format_width(snd_pcm_format_t format);                      /* in bits */
01009 int snd_pcm_format_physical_width(snd_pcm_format_t format);             /* in bits */
01010 snd_pcm_format_t snd_pcm_build_linear_format(int width, int pwidth, int unsignd, int big_endian);
01011 ssize_t snd_pcm_format_size(snd_pcm_format_t format, size_t samples);
01012 u_int8_t snd_pcm_format_silence(snd_pcm_format_t format);
01013 u_int16_t snd_pcm_format_silence_16(snd_pcm_format_t format);
01014 u_int32_t snd_pcm_format_silence_32(snd_pcm_format_t format);
01015 u_int64_t snd_pcm_format_silence_64(snd_pcm_format_t format);
01016 int snd_pcm_format_set_silence(snd_pcm_format_t format, void *buf, unsigned int samples);
01017 
01018 snd_pcm_sframes_t snd_pcm_bytes_to_frames(snd_pcm_t *pcm, ssize_t bytes);
01019 ssize_t snd_pcm_frames_to_bytes(snd_pcm_t *pcm, snd_pcm_sframes_t frames);
01020 long snd_pcm_bytes_to_samples(snd_pcm_t *pcm, ssize_t bytes);
01021 ssize_t snd_pcm_samples_to_bytes(snd_pcm_t *pcm, long samples);
01022 
01023 int snd_pcm_area_silence(const snd_pcm_channel_area_t *dst_channel, snd_pcm_uframes_t dst_offset,
01024                          unsigned int samples, snd_pcm_format_t format);
01025 int snd_pcm_areas_silence(const snd_pcm_channel_area_t *dst_channels, snd_pcm_uframes_t dst_offset,
01026                           unsigned int channels, snd_pcm_uframes_t frames, snd_pcm_format_t format);
01027 int snd_pcm_area_copy(const snd_pcm_channel_area_t *dst_channel, snd_pcm_uframes_t dst_offset,
01028                       const snd_pcm_channel_area_t *src_channel, snd_pcm_uframes_t src_offset,
01029                       unsigned int samples, snd_pcm_format_t format);
01030 int snd_pcm_areas_copy(const snd_pcm_channel_area_t *dst_channels, snd_pcm_uframes_t dst_offset,
01031                        const snd_pcm_channel_area_t *src_channels, snd_pcm_uframes_t src_offset,
01032                        unsigned int channels, snd_pcm_uframes_t frames, snd_pcm_format_t format);
01033 
01044 typedef enum _snd_pcm_hook_type {
01045         SND_PCM_HOOK_TYPE_HW_PARAMS = 0,
01046         SND_PCM_HOOK_TYPE_HW_FREE,
01047         SND_PCM_HOOK_TYPE_CLOSE,
01048         SND_PCM_HOOK_TYPE_LAST = SND_PCM_HOOK_TYPE_CLOSE
01049 } snd_pcm_hook_type_t;
01050 
01052 typedef struct _snd_pcm_hook snd_pcm_hook_t;
01054 typedef int (*snd_pcm_hook_func_t)(snd_pcm_hook_t *hook);
01055 snd_pcm_t *snd_pcm_hook_get_pcm(snd_pcm_hook_t *hook);
01056 void *snd_pcm_hook_get_private(snd_pcm_hook_t *hook);
01057 void snd_pcm_hook_set_private(snd_pcm_hook_t *hook, void *private_data);
01058 int snd_pcm_hook_add(snd_pcm_hook_t **hookp, snd_pcm_t *pcm,
01059                      snd_pcm_hook_type_t type,
01060                      snd_pcm_hook_func_t func, void *private_data);
01061 int snd_pcm_hook_remove(snd_pcm_hook_t *hook);
01062 
01073 typedef struct _snd_pcm_scope_ops {
01077         int (*enable)(snd_pcm_scope_t *scope);
01081         void (*disable)(snd_pcm_scope_t *scope);
01085         void (*start)(snd_pcm_scope_t *scope);
01089         void (*stop)(snd_pcm_scope_t *scope);
01093         void (*update)(snd_pcm_scope_t *scope);
01097         void (*reset)(snd_pcm_scope_t *scope);
01101         void (*close)(snd_pcm_scope_t *scope);
01102 } snd_pcm_scope_ops_t;
01103 
01104 snd_pcm_uframes_t snd_pcm_meter_get_bufsize(snd_pcm_t *pcm);
01105 unsigned int snd_pcm_meter_get_channels(snd_pcm_t *pcm);
01106 unsigned int snd_pcm_meter_get_rate(snd_pcm_t *pcm);
01107 snd_pcm_uframes_t snd_pcm_meter_get_now(snd_pcm_t *pcm);
01108 snd_pcm_uframes_t snd_pcm_meter_get_boundary(snd_pcm_t *pcm);
01109 int snd_pcm_meter_add_scope(snd_pcm_t *pcm, snd_pcm_scope_t *scope);
01110 snd_pcm_scope_t *snd_pcm_meter_search_scope(snd_pcm_t *pcm, const char *name);
01111 int snd_pcm_scope_malloc(snd_pcm_scope_t **ptr);
01112 void snd_pcm_scope_set_ops(snd_pcm_scope_t *scope, snd_pcm_scope_ops_t *val);
01113 void snd_pcm_scope_set_name(snd_pcm_scope_t *scope, const char *val);
01114 const char *snd_pcm_scope_get_name(snd_pcm_scope_t *scope);
01115 void *snd_pcm_scope_get_callback_private(snd_pcm_scope_t *scope);
01116 void snd_pcm_scope_set_callback_private(snd_pcm_scope_t *scope, void *val);
01117 int snd_pcm_scope_s16_open(snd_pcm_t *pcm, const char *name,
01118                            snd_pcm_scope_t **scopep);
01119 int16_t *snd_pcm_scope_s16_get_channel_buffer(snd_pcm_scope_t *scope,
01120                                               unsigned int channel);
01121 
01131 /* Deprecated functions, for compatibility */
01132 const char *snd_pcm_start_mode_name(snd_pcm_start_t mode);
01133 const char *snd_pcm_xrun_mode_name(snd_pcm_xrun_t mode);
01134 int snd_pcm_sw_params_set_start_mode(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_start_t val);
01135 snd_pcm_start_t snd_pcm_sw_params_get_start_mode(const snd_pcm_sw_params_t *params);
01136 int snd_pcm_sw_params_set_xrun_mode(snd_pcm_t *pcm, snd_pcm_sw_params_t *params, snd_pcm_xrun_t val);
01137 snd_pcm_xrun_t snd_pcm_sw_params_get_xrun_mode(const snd_pcm_sw_params_t *params);
01138 
01141 #ifdef __cplusplus
01142 }
01143 #endif
01144 
01145 #endif /* __ALSA_PCM_H */

Generated on Thu Feb 20 16:45:42 2003 for ALSA project - the C library reference by doxygen1.2.18