3 * Copyright (C) 2009-2011 Michael 'Mickey' Lauer <mlauer@vanille-media.de>
5 * This library is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU Lesser General Public
7 * License as published by the Free Software Foundation; either
8 * version 2.1 of the License, or (at your option) any later version.
10 * This library is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13 * Lesser General Public License for more details.
15 * You should have received a copy of the GNU Lesser General Public
16 * License along with this library; if not, write to the Free Software
17 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
21 [CCode (lower_case_cprefix = "snd_", cheader_filename = "alsa/asoundlib.h")]
24 public unowned string strerror (int error);
26 [CCode (cname = "snd_aes_iec958_t", destroy_function = "")]
27 public struct AesIec958
29 public uchar[] status;
30 public uchar[] subcode;
32 public uchar[] dig_subframe;
35 [CCode (cprefix = "SND_CTL_", cheader_filename = "alsa/control.h")]
36 public enum CardOpenType
44 [CCode (cprefix = "snd_ctl_card_info_", cname = "snd_ctl_card_info_t", free_function = "snd_ctl_card_info_free")]
47 [CCode (cname = "snd_ctl_card_info_malloc")]
48 public static int alloc (out CardInfo info);
50 public unowned string get_id();
51 public unowned string get_longname();
53 public unowned string get_mixername();
54 public unowned string get_components();
58 [CCode (cprefix = "snd_ctl_", cname = "snd_ctl_t", free_function = "snd_ctl_close")]
61 public static int open (out Card card, string name = "default", CardOpenType t = 0);
63 public int card_info (CardInfo info);
64 public int elem_list (ElemList list);
65 public int elem_info (ElemInfo info);
66 public int elem_read (ElemValue value);
67 public int elem_write (ElemValue value);
69 public int get_dB_range (ElemId eid, out long min, out long max);
70 public int convert_to_dB (ElemId eid, long volume, out long gain);
71 public int convert_from_dB (ElemId eid, long gain, out long value, int xdir);
75 [CCode (cprefix = "snd_ctl_elem_id_", cname = "snd_ctl_elem_id_t", free_function = "snd_ctl_elem_id_free")]
78 [CCode (cname = "snd_ctl_elem_id_malloc")]
79 public static int alloc (out ElemId eid);
81 public unowned string get_name();
82 public uint get_numid();
83 public uint get_index();
84 public uint get_device();
85 public uint get_subdevice();
89 [CCode (cprefix = "snd_ctl_elem_info_", cname = "snd_ctl_elem_info_t", free_function = "snd_ctl_elem_info_free")]
92 [CCode (cname = "snd_ctl_elem_info_malloc")]
93 public static int alloc (out ElemInfo t);
95 public void set_id (ElemId eid);
96 public void set_numid (uint n);
98 public uint get_count ();
99 public ElemType get_type ();
102 [CCode (cprefix = "SND_CTL_ELEM_IFACE_", cname = "snd_ctl_elem_iface_t")]
103 public enum ElemInterface
114 [CCode (cprefix = "SND_CTL_ELEM_TYPE_", cname = "snd_ctl_elem_type_t")]
127 [CCode (cprefix = "snd_ctl_elem_value_", cname = "snd_ctl_elem_value_t", free_function = "snd_ctl_elem_value_free")]
128 public class ElemValue
130 [CCode (cname = "snd_ctl_elem_value_malloc")]
131 public static int alloc (out ElemValue t);
133 public void set_id (ElemId eid);
135 public bool get_boolean (uint idx);
136 public long get_integer (uint idx);
137 public int64 get_integer64 (uint idx);
138 public uint get_enumerated (uint idx);
139 public uchar get_byte (uint idx);
140 public void get_iec958 (AesIec958 val);
142 public void set_boolean (uint idx, bool b);
143 public void set_integer (uint idx, long l);
144 public void set_integer64 (uint idx, int64 i);
145 public void set_enumerated (uint idx, uint val);
146 public void set_byte (uint idx, uchar val);
147 public void set_iec958 (AesIec958 val);
151 [CCode (cprefix = "snd_ctl_elem_list_", cname = "snd_ctl_elem_list_t", free_function = "snd_ctl_elem_list_free")]
152 public class ElemList
154 [CCode (cname = "snd_ctl_elem_list_malloc")]
155 public static int alloc (out ElemList list);
156 public int alloc_space (uint entries);
157 public uint get_count();
158 public uint get_used();
159 public void free_space ();
160 public void set_offset (uint offset);
162 public void get_id (uint n, ElemId eid);
165 [CCode (cname = "snd_spcm_latency_t", cprefix = "SND_SPCM_LATENCY_", has_type_id = false)]
166 public enum PcmSimpleLatency
173 [CCode (cname = "snd_spcm_xrun_type_t", cprefix = "SND_SPCM_XRUN_", has_type_id = false)]
174 public enum PcmSimpleXrunType
180 [CCode (cname = "snd_spcm_duplex_t", cprefix = "SND_SPCM_DUPLEX_", has_type_id = false)]
181 public enum PcmSimpleDuplex {
186 [CCode (cname = "snd_pcm_access_t", cprefix = "SND_PCM_ACCESS_", has_type_id = false)]
187 public enum PcmAccess
197 [CCode (cname = "snd_pcm_class_t", cprefix = "SND_PCM_CLASS_", has_type_id = false)]
207 [CCode (cname = "snd_pcm_format_t", cprefix = "SND_PCM_FORMAT_", has_type_id = false)]
208 public enum PcmFormat
261 [CCode (cname = "gint", cprefix = "SND_PCM_", has_type_id = false)]
272 [CCode (cname = "snd_pcm_start_t", cprefix = "SND_PCM_START_", has_type_id = false)]
280 [CCode (cname = "snd_pcm_state_t", cprefix = "", has_type_id = false)]
295 [CCode (cname = "snd_pcm_stream_t", cprefix = "SND_PCM_STREAM_", has_type_id = false)]
296 public enum PcmStream
303 [CCode (cname = "snd_pcm_subclass_t", cprefix = "SND_PCM_SUBCLASS_", has_type_id = false)]
304 public enum PcmSubclass
311 [CCode (cname = "snd_pcm_subformat_t", cprefix = "SND_PCM_SUBFORMAT_", has_type_id = false)]
312 public enum PcmSubformat
318 [CCode (cname = "snd_pcm_tstamp_t", cprefix = "SND_PCM_TSTAMP_", has_type_id = false)]
319 public enum PcmTimestamp
327 [CCode (cname = "snd_pcm_type_t", cprefix = "SND_PCM_TYPE_", has_type_id = false)]
363 [CCode (cname = "snd_pcm_xrun_t", cprefix = "SND_PCM_XRUN_", has_type_id = false)]
372 [CCode (cname = "snd_pcm_access_mask_t")]
373 public struct PcmAccessMask
378 [CCode (cname = "snd_pcm_format_mask_t")]
379 public struct PcmFormatMask
384 [CCode (cname = "snd_pcm_subformat_mask_t")]
385 public struct PcmSubformatMask
390 [CCode (cname = "snd_pcm_timestamp_t")]
391 public struct PcmSoftwareTimestamp
396 [CCode (cname = "snd_pcm_htimestamp_t")]
397 public struct PcmHardwareTimestamp
402 [CCode (cname = "snd_pcm_info_t", cprefix = "snd_pcm_info_")]
405 public static int alloca( out PcmInfo info );
406 public static int malloc( out PcmInfo info );
408 public void copy( PcmInfo source );
409 public uint get_device();
410 public uint get_subdevice();
411 public PcmStream get_stream();
412 public int get_card();
413 public string get_id();
414 public string get_name();
415 public string get_subdevice_name();
416 public PcmClass get_class();
417 public PcmSubclass get_subclass();
418 public uint get_subdevices_count();
419 public uint get_subdevices_avail();
420 public PcmSyncId get_sync();
421 public void set_device( uint val );
422 public void set_subdevice( uint val );
423 public void set_stream( PcmStream val );
427 [CCode (cname = "snd_pcm_hw_params_t", cprefix = "snd_pcm_hw_params_", free_function = "snd_pcm_hw_params_free")]
428 public class PcmHardwareParams
430 public static int alloca( out PcmHardwareParams params );
431 public static int malloc( out PcmHardwareParams params );
433 public void copy( PcmHardwareParams source );
434 public int get_access( PcmAccess access );
435 public int get_access_mask( PcmAccessMask mask );
436 public int get_format( PcmFormat format );
437 public void get_format_mask( PcmFormatMask mask );
438 public int get_subformat( PcmSubformat subformat );
439 public void get_subformat_mask( PcmSubformatMask mask );
440 public int get_channels( out int val );
441 public int get_channels_min( out int val );
442 public int get_channels_max( out int val );
443 public int get_rate( out int val, out int dir );
444 public int get_rate_min( out int val, out int dir );
445 public int get_rate_max( out int val, out int dir );
446 public int get_period_time( out int val, out int dir );
447 public int get_period_time_min( out int val, out int dir );
448 public int get_period_time_max( out int val, out int dir );
449 public int get_period_size( out PcmUnsignedFrames frames, out int dir );
450 public int get_period_size_min( out PcmUnsignedFrames frames, out int dir );
451 public int get_period_size_max( out PcmUnsignedFrames frames, out int dir );
452 public int get_periods( out int val, out int dir );
453 public int get_periods_min( out int val, out int dir );
454 public int get_periods_max( out int val, out int dir );
455 public int get_buffer_time( out int val, out int dir );
456 public int get_buffer_time_min( out int val, out int dir );
457 public int get_buffer_time_max( out int val, out int dir );
458 public int get_buffer_size( out PcmUnsignedFrames frames );
459 public int get_buffer_size_min( out PcmUnsignedFrames frames );
460 public int get_buffer_size_max( out PcmUnsignedFrames frames );
461 public int get_min_align( out PcmUnsignedFrames frames );
463 public int can_mmap_sample_resolution();
464 public int is_double();
465 public int is_batch();
466 public int is_block_transfer();
467 public int is_monotonic();
468 public int can_overrange();
469 public int can_pause();
470 public int can_resume();
471 public int is_half_duplex();
472 public int is_joint_duplex();
473 public int can_sync_start();
474 public int can_disable_period_wakeup();
475 public int get_rate_numden( out uint rate_num, out uint rate_den );
476 public int get_sbits();
477 public int get_fifo_size();
481 [CCode (cname = "snd_pcm_sw_params_t")]
482 public class PcmSoftwareParams
487 [CCode (cname = "snd_pcm_uframes_t")]
488 [IntegerType (rank = 9)]
489 public struct PcmUnsignedFrames
494 [CCode (cname = "snd_pcm_sframes_t")]
495 [IntegerType (rank = 8)]
496 public struct PcmSignedFrames
501 [CCode (cname = "snd_pcm_channel_area_t", free_function = "")]
502 public struct PcmChannelArea
510 [CCode (cname = "snd_pcm_sync_id_t", free_function = "")]
511 public struct PcmSyncId
514 public ushort id16[8];
519 [CCode (cname = "snd_pcm_t", cprefix = "snd_pcm_", free_function = "")]
520 public class PcmDevice
522 public static int open( out PcmDevice pcm, string name, PcmStream stream, PcmMode mode = 0 );
525 [CCode (cname = "snd_pcm_name")]
526 public string get_name();
527 [CCode (cname = "snd_pcm_type")]
528 public PcmType get_type();
529 [CCode (cname = "snd_pcm_stream")]
530 public PcmStream get_stream();
531 [CCode (cname = "snd_pcm_poll_descriptors_count")]
532 public int get_poll_descriptors_count();
533 [CCode (cname = "snd_pcm_poll_descriptors")]
534 public int set_poll_descriptors( Posix.pollfd[] pfds );
535 [CCode (cname = "snd_pcm_poll_descriptors_revents")]
536 public int set_poll_descriptors_revents( Posix.pollfd[] pfds, ushort[] revents );
537 [CCode (cname = "snd_pcm_nonblock")]
538 public int set_nonblock( bool nonblock );
540 //public int snd_async_add_pcm_handler( snd_async_handler_t **handler, snd_pcm_t *pcm, snd_async_callback_t callback, void *private_data );
541 //public PcmDevice async_handler_get_pcm( snd_async_handler_t *handler );
542 public int info( PcmInfo info );
543 public int sw_params_current( out PcmSoftwareParams params );
544 public int sw_params( PcmSoftwareParams params );
545 public int hw_free();
546 public int prepare();
548 [CCode (cname = "snd_pcm_status")]
549 public int set_status( PcmState status );
553 public int pause( bool enable );
554 public PcmState state();
556 public int delay( PcmSignedFrames delayp );
558 public int htimestamp( PcmUnsignedFrames avail, PcmHardwareTimestamp tstamp );
559 public PcmSignedFrames avail();
560 public PcmSignedFrames avail_update();
561 public int avail_delay( out PcmSignedFrames availp, out PcmSignedFrames delayp );
562 public PcmSignedFrames rewindable();
563 public PcmSignedFrames rewind( PcmUnsignedFrames frames );
564 public PcmSignedFrames forwardable();
565 public PcmSignedFrames forward( PcmUnsignedFrames frames );
566 public PcmSignedFrames writei( [CCode (array_length = false)] uint8[] buffer, PcmUnsignedFrames size );
567 public PcmSignedFrames writen( [CCode (array_length = false)] uint8*[] buffer, PcmUnsignedFrames size );
568 public PcmSignedFrames readi( [CCode (array_length = false)] uint8[] buffer, PcmUnsignedFrames size );
569 public PcmSignedFrames readn( [CCode (array_length = false)] uint8*[] buffer, PcmUnsignedFrames size );
570 public int wait( int timeout );
571 public int link( PcmDevice otherDevice );
575 public int recover( int err, int silent );
576 public int set_params( PcmFormat format, PcmAccess access, uint channels, uint rate, int soft_resample, uint latency );
577 public int get_params( out PcmUnsignedFrames buffer_size, out PcmUnsignedFrames period_size );
580 [CCode (cname = "snd_spcm_init")]
581 public int simple_init( uint rate, uint channels, PcmFormat format, PcmSubformat subformat, PcmSimpleLatency latency, PcmAccess access, PcmSimpleXrunType xrun );
582 [CCode (cname = "snd_spcm_init_duplex")]
583 public static int simple_init_duplex( PcmDevice playback, PcmDevice capture, uint rate, uint channels, PcmFormat format, PcmSubformat subformat, PcmSimpleLatency latency, PcmAccess access, PcmSimpleXrunType xrun, PcmSimpleDuplex duplex );
584 [CCode (cname = "snd_spcm_get_params")]
585 public int simple_get_params( out uint rate, out PcmUnsignedFrames buffer_size, out PcmUnsignedFrames period_size );
588 public int hw_params_current( out PcmHardwareParams params );
589 public int hw_params( PcmHardwareParams params );
590 public int hw_params_any( PcmHardwareParams params );
591 public int hw_params_test_access( PcmHardwareParams params, PcmAccess access );
592 public int hw_params_set_access( PcmHardwareParams params, PcmAccess access );
593 public int hw_params_set_access_first( PcmHardwareParams params, out PcmAccess access );
594 public int hw_params_set_access_last( PcmHardwareParams params, out PcmAccess access );
595 public int hw_params_set_access_mask( PcmHardwareParams params, out PcmAccessMask mask );
596 public int hw_params_test_format( PcmHardwareParams params, PcmFormat format );
597 public int hw_params_set_format( PcmHardwareParams params, PcmFormat format );
598 public int hw_params_set_format_first( PcmHardwareParams params, out PcmFormat format );
599 public int hw_params_set_format_last( PcmHardwareParams params, out PcmFormat format );
600 public int hw_params_set_format_mask( PcmHardwareParams params, out PcmFormatMask mask );
601 public int hw_params_test_subformat( PcmHardwareParams params, PcmSubformat subformat );
602 public int hw_params_set_subformat( PcmHardwareParams params, PcmSubformat subformat );
603 public int hw_params_set_subformat_first( PcmHardwareParams params, out PcmSubformat subformat );
604 public int hw_params_set_subformat_last( PcmHardwareParams params, out PcmSubformat subformat );
605 public int hw_params_set_subformat_mask( PcmHardwareParams params, out PcmSubformatMask mask );
606 public int hw_params_test_channels( PcmHardwareParams params, uint val );
607 public int hw_params_set_channels( PcmHardwareParams params, uint val );
608 public int hw_params_set_channels_min( PcmHardwareParams params, out int val );
609 public int hw_params_set_channels_max( PcmHardwareParams params, out int val );
610 public int hw_params_set_channels_minmax( PcmHardwareParams params, out uint min, out int max );
611 public int hw_params_set_channels_near( PcmHardwareParams params, out int val );
612 public int hw_params_set_channels_first( PcmHardwareParams params, out int val );
613 public int hw_params_set_channels_last( PcmHardwareParams params, out int val );
614 public int hw_params_test_rate( PcmHardwareParams params, uint val, int dir );
615 public int hw_params_set_rate( PcmHardwareParams params, uint val, int dir );
616 public int hw_params_set_rate_min( PcmHardwareParams params, out int val, out int dir );
617 public int hw_params_set_rate_max( PcmHardwareParams params, out int val, out int dir );
618 public int hw_params_set_rate_minmax( PcmHardwareParams params, out uint min, out int mindir, out int max, out int maxdir );
619 public int hw_params_set_rate_near( PcmHardwareParams params, ref int val, int dir );
620 public int hw_params_set_rate_first( PcmHardwareParams params, out int val, out int dir );
621 public int hw_params_set_rate_last( PcmHardwareParams params, out int val, out int dir );
622 public int hw_params_set_rate_resample( PcmHardwareParams params, uint val );
623 public int hw_params_get_rate_resample( PcmHardwareParams params, out int val );
624 public int hw_params_set_export_buffer( PcmHardwareParams params, uint val );
625 public int hw_params_get_export_buffer( PcmHardwareParams params, out int val );
626 public int hw_params_set_period_wakeup( PcmHardwareParams params, uint val );
627 public int hw_params_get_period_wakeup( PcmHardwareParams params, out int val );
628 public int hw_params_test_period_time( PcmHardwareParams params, uint val, int dir );
629 public int hw_params_set_period_time( PcmHardwareParams params, uint val, int dir );
630 public int hw_params_set_period_time_min( PcmHardwareParams params, out int val, out int dir );
631 public int hw_params_set_period_time_max( PcmHardwareParams params, out int val, out int dir );
632 public int hw_params_set_period_time_minmax( PcmHardwareParams params, out uint min, out int mindir, out int max, out int maxdir );
633 public int hw_params_set_period_time_near( PcmHardwareParams params, out int val, out int dir );
634 public int hw_params_set_period_time_first( PcmHardwareParams params, out int val, out int dir );
635 public int hw_params_set_period_time_last( PcmHardwareParams params, out int val, out int dir );
636 public int hw_params_test_period_size( PcmHardwareParams params, PcmUnsignedFrames frames, int dir );
637 public int hw_params_set_period_size( PcmHardwareParams params, PcmUnsignedFrames frames, int dir );
638 public int hw_params_set_period_size_min( PcmHardwareParams params, out PcmUnsignedFrames frames, out int dir );
639 public int hw_params_set_period_size_max( PcmHardwareParams params, out PcmUnsignedFrames frames, out int dir );
640 public int hw_params_set_period_size_minmax( PcmHardwareParams params, out PcmUnsignedFrames min, out int mindir, out PcmUnsignedFrames max, out int maxdir );
641 public int hw_params_set_period_size_near( PcmHardwareParams params, out PcmUnsignedFrames frames, out int dir );
642 public int hw_params_set_period_size_first( PcmHardwareParams params, out PcmUnsignedFrames frames, out int dir );
643 public int hw_params_set_period_size_last( PcmHardwareParams params, out PcmUnsignedFrames frames, out int dir );
644 public int hw_params_set_period_size_integer( PcmHardwareParams params );
645 public int hw_params_test_periods( PcmHardwareParams params, uint val, int dir );
646 public int hw_params_set_periods( PcmHardwareParams params, uint val, int dir );
647 public int hw_params_set_periods_min( PcmHardwareParams params, out int val, out int dir );
648 public int hw_params_set_periods_max( PcmHardwareParams params, out int val, out int dir );
649 public int hw_params_set_periods_minmax( PcmHardwareParams params, out uint min, out int mindir, out int max, out int maxdir );
650 public int hw_params_set_periods_near( PcmHardwareParams params, out int val, out int dir );
651 public int hw_params_set_periods_first( PcmHardwareParams params, out int val, out int dir );
652 public int hw_params_set_periods_last( PcmHardwareParams params, out int val, out int dir );
653 public int hw_params_set_periods_integer( PcmHardwareParams params );
654 public int hw_params_test_buffer_time( PcmHardwareParams params, uint val, int dir );
655 public int hw_params_set_buffer_time( PcmHardwareParams params, uint val, int dir );
656 public int hw_params_set_buffer_time_min( PcmHardwareParams params, out int val, out int dir );
657 public int hw_params_set_buffer_time_max( PcmHardwareParams params, out int val, out int dir );
658 public int hw_params_set_buffer_time_minmax( PcmHardwareParams params, out uint min, out int mindir, out int max, out int maxdir );
659 public int hw_params_set_buffer_time_near( PcmHardwareParams params, out int val, out int dir );
660 public int hw_params_set_buffer_time_first( PcmHardwareParams params, out int val, out int dir );
661 public int hw_params_set_buffer_time_last( PcmHardwareParams params, out int val, out int dir );
662 public int hw_params_test_buffer_size( PcmHardwareParams params, PcmUnsignedFrames frames );
663 public int hw_params_set_buffer_size( PcmHardwareParams params, PcmUnsignedFrames frames );
664 public int hw_params_set_buffer_size_min( PcmHardwareParams params, out PcmUnsignedFrames frames );
665 public int hw_params_set_buffer_size_max( PcmHardwareParams params, out PcmUnsignedFrames frames );
666 public int hw_params_set_buffer_size_minmax( PcmHardwareParams params, out PcmUnsignedFrames min, out PcmUnsignedFrames max );
667 public int hw_params_set_buffer_size_near( PcmHardwareParams params, out PcmUnsignedFrames frames );
668 public int hw_params_set_buffer_size_first( PcmHardwareParams params, out PcmUnsignedFrames frames );
669 public int hw_params_set_buffer_size_last( PcmHardwareParams params, out PcmUnsignedFrames frames );
672 public PcmSignedFrames bytes_to_frames( ssize_t bytes );
673 public ssize_t frames_to_bytes( PcmSignedFrames frames );
674 public long bytes_to_samples( ssize_t bytes );
675 public ssize_t samples_to_bytes( long samples );
678 [CCode (cprefix = "SND_MIXER_SABSTRACT_", cname = "snd_mixer_selem_regopt_abstract")]
679 public enum MixerAbstractionLevel
685 [CCode (cname = "struct snd_mixer_selem_regopt", destroy_function = "", cheader_filename = "alsa/mixer.h")]
686 public struct MixerRegistrationOptions
689 public MixerAbstractionLevel @abstract;
690 public string device;
691 public PcmDevice playback_pcm;
692 public PcmDevice capture_pcm;
696 [CCode (cprefix = "snd_mixer_class_", cname = "snd_mixer_class_t", free_function = "snd_mixer_class_close", cheader_filename = "alsa/mixer.h")]
697 public class MixerClass
702 [CCode (cprefix = "snd_mixer_", cname = "snd_mixer_t", free_function = "snd_mixer_close")]
705 public static int open (out Mixer mixer, int t = 0 /* MixerOpenType t = 0 */ );
706 public int attach (string card = "default");
707 public int detach (string card = "default");
708 public uint get_count ();
711 [CCode (cname = "snd_mixer_selem_register")]
712 public int register (MixerRegistrationOptions? options = null, out MixerClass classp = null );
714 public MixerElement first_elem ();
715 public MixerElement last_elem ();
719 [CCode (cprefix = "snd_mixer_selem_", cname = "snd_mixer_elem_t", free_function = "")]
720 public class MixerElement
722 [CCode (cname = "snd_mixer_elem_next")]
723 public MixerElement next ();
724 [CCode (cname = "snd_mixer_elem_prev")]
725 public MixerElement prev ();
727 public void get_id (SimpleElementId eid);
728 public bool is_active ();
729 public bool is_playback_mono ();
730 public bool has_playback_channel (SimpleChannelId channel);
731 public bool is_capture_mono ();
732 public bool has_capture_channel (SimpleChannelId channel);
733 public int get_capture_group ();
734 public bool has_common_volume ();
735 public bool has_playback_volume ();
736 public bool has_playback_volume_joined ();
737 public bool has_capture_volume ();
738 public bool has_capture_volume_joined ();
739 public bool has_common_switch ();
740 public bool has_playback_switch ();
741 public bool has_playback_switch_joined ();
742 public bool has_capture_switch ();
743 public bool has_capture_switch_joined ();
744 public bool has_capture_switch_exclusive ();
746 public int ask_playback_vol_dB (long val, out long dBval);
747 public int ask_capture_vol_dB (long val, out long dBval);
748 public int ask_playback_dB_vol (long dBval, int dir, out long val);
749 public int ask_capture_dB_vol (long dBval, int dir, out long val);
750 public int get_playback_volume (SimpleChannelId channel, out long val);
751 public int get_capture_volume (SimpleChannelId channel, out long val);
752 public int get_playback_dB (SimpleChannelId channel, out long val);
753 public int get_capture_dB (SimpleChannelId channel, out long val);
754 public int get_playback_switch (SimpleChannelId channel, out int val);
755 public int get_capture_switch (SimpleChannelId channel, out int val);
756 public int set_playback_volume (SimpleChannelId channel, long val);
757 public int set_capture_volume (SimpleChannelId channel, long val);
758 public int set_playback_dB (SimpleChannelId channel, long val, int dir);
759 public int set_capture_dB (SimpleChannelId channel, long val, int dir);
760 public int set_playback_volume_all (long val);
761 public int set_capture_volume_all (long val);
762 public int set_playback_dB_all (long val, int dir);
763 public int set_capture_dB_all (long val, int dir);
764 public int set_playback_switch (SimpleChannelId channel, int val);
765 public int set_capture_switch (SimpleChannelId channel, int val);
766 public int set_playback_switch_all (int val);
767 public int set_capture_switch_all (int val);
768 public int get_playback_volume_range (out long min, out long max);
769 public int get_playback_dB_range (out long min, out long max);
770 public int set_playback_volume_range (long min, long max);
771 public int get_capture_volume_range (out long min, out long max);
772 public int get_capture_dB_range (out long min, out long max);
773 public int set_capture_volume_range (long min, long max);
774 public int is_enumerated ();
775 public int is_enum_playback ();
776 public int is_enum_capture ();
777 public int get_enum_items ();
778 public int get_enum_item_name (uint idx, size_t maxlen, out string str);
779 public int get_enum_item (SimpleChannelId channel, out uint idxp);
780 public int set_enum_item (SimpleChannelId channel, uint idx);
783 [CCode (cprefix = "SND_MIXER_SCHN_", cname = "snd_mixer_selem_channel_id_t")]
784 public enum SimpleChannelId
801 [CCode (cprefix = "snd_mixer_selem_id_", cname = "snd_mixer_selem_id_t", free_function = "")]
802 public class SimpleElementId
804 [CCode (cname = "snd_mixer_selem_id_malloc")]
805 public static int alloc (out SimpleElementId eid);
807 public unowned string get_name();
808 public uint get_index();