1 <title>DVB Audio Device</title>
2 <para>The DVB audio device controls the MPEG2 audio decoder of the DVB hardware. It
3 can be accessed through <emphasis role="tt">/dev/dvb/adapter0/audio0</emphasis>. Data types and and
4 ioctl definitions can be accessed by including <emphasis role="tt">linux/dvb/audio.h</emphasis> in your
7 <para>Please note that some DVB cards don’t have their own MPEG decoder, which results in
8 the omission of the audio and video device.
11 These ioctls were also used by V4L2 to control MPEG decoders implemented in V4L2. The use
12 of these ioctls for that purpose has been made obsolete and proper V4L2 ioctls or controls
13 have been created to replace that functionality.</para>
15 <section id="audio_data_types">
16 <title>Audio Data Types</title>
17 <para>This section describes the structures, data types and defines used when talking to the
21 <section id="audio-stream-source-t">
22 <title>audio_stream_source_t</title>
23 <para>The audio stream source is set through the AUDIO_SELECT_SOURCE call and can take
24 the following values, depending on whether we are replaying from an internal (demux) or
25 external (user write) source.
31 } audio_stream_source_t;
33 <para>AUDIO_SOURCE_DEMUX selects the demultiplexer (fed either by the frontend or the
34 DVR device) as the source of the video stream. If AUDIO_SOURCE_MEMORY
35 is selected the stream comes from the application through the <emphasis role="tt">write()</emphasis> system
40 <section id="audio-play-state-t">
41 <title>audio_play_state_t</title>
42 <para>The following values can be returned by the AUDIO_GET_STATUS call representing the
43 state of audio playback.
54 <section id="audio-channel-select-t">
55 <title>audio_channel_select_t</title>
56 <para>The audio channel selected via AUDIO_CHANNEL_SELECT is determined by the
66 } audio_channel_select_t;
70 <section id="audio-status">
71 <title>struct audio_status</title>
72 <para>The AUDIO_GET_STATUS call returns the following structure informing about various
73 states of the playback operation.
76 typedef struct audio_status {
77 boolean AV_sync_state;
79 audio_play_state_t play_state;
80 audio_stream_source_t stream_source;
81 audio_channel_select_t channel_select;
83 audio_mixer_t mixer_state;
88 <section id="audio-mixer">
89 <title>struct audio_mixer</title>
90 <para>The following structure is used by the AUDIO_SET_MIXER call to set the audio
94 typedef struct audio_mixer {
95 unsigned int volume_left;
96 unsigned int volume_right;
101 <section id="audio_encodings">
102 <title>audio encodings</title>
103 <para>A call to AUDIO_GET_CAPABILITIES returns an unsigned integer with the following
104 bits set according to the hardwares capabilities.
107 #define AUDIO_CAP_DTS 1
108 #define AUDIO_CAP_LPCM 2
109 #define AUDIO_CAP_MP1 4
110 #define AUDIO_CAP_MP2 8
111 #define AUDIO_CAP_MP3 16
112 #define AUDIO_CAP_AAC 32
113 #define AUDIO_CAP_OGG 64
114 #define AUDIO_CAP_SDDS 128
115 #define AUDIO_CAP_AC3 256
119 <section id="audio-karaoke">
120 <title>struct audio_karaoke</title>
121 <para>The ioctl AUDIO_SET_KARAOKE uses the following format:
125 struct audio_karaoke {
131 <para>If Vocal1 or Vocal2 are non-zero, they get mixed into left and right t at 70% each. If both,
132 Vocal1 and Vocal2 are non-zero, Vocal1 gets mixed into the left channel and Vocal2 into the
133 right channel at 100% each. Ff Melody is non-zero, the melody channel gets mixed into left
138 <section id="audio-attributes-t">
139 <title>audio attributes</title>
140 <para>The following attributes can be set by a call to AUDIO_SET_ATTRIBUTES:
143 typedef uint16_t audio_attributes_t;
144 /⋆ bits: descr. ⋆/
145 /⋆ 15-13 audio coding mode (0=ac3, 2=mpeg1, 3=mpeg2ext, 4=LPCM, 6=DTS, ⋆/
146 /⋆ 12 multichannel extension ⋆/
147 /⋆ 11-10 audio type (0=not spec, 1=language included) ⋆/
148 /⋆ 9- 8 audio application mode (0=not spec, 1=karaoke, 2=surround) ⋆/
149 /⋆ 7- 6 Quantization / DRC (mpeg audio: 1=DRC exists)(lpcm: 0=16bit, ⋆/
150 /⋆ 5- 4 Sample frequency fs (0=48kHz, 1=96kHz) ⋆/
151 /⋆ 2- 0 number of audio channels (n+1 channels) ⋆/
154 <section id="audio_function_calls">
155 <title>Audio Function Calls</title>
158 <section id="audio_fopen">
159 <title>open()</title>
162 <informaltable><tgroup cols="1"><tbody><row><entry
164 <para>This system call opens a named audio device (e.g. /dev/dvb/adapter0/audio0)
165 for subsequent use. When an open() call has succeeded, the device will be ready
166 for use. The significance of blocking or non-blocking mode is described in the
167 documentation for functions where there is a difference. It does not affect the
168 semantics of the open() call itself. A device opened in blocking mode can later
169 be put into non-blocking mode (and vice versa) using the F_SETFL command
170 of the fcntl system call. This is a standard system call, documented in the Linux
171 manual page for fcntl. Only one user can open the Audio Device in O_RDWR
172 mode. All other attempts to open the device in this mode will fail, and an error
173 code will be returned. If the Audio Device is opened in O_RDONLY mode, the
174 only ioctl call that can be used is AUDIO_GET_STATUS. All other call will
175 return with an error code.</para>
177 </row></tbody></tgroup></informaltable>
180 <informaltable><tgroup cols="1"><tbody><row><entry
182 <para>int open(const char ⋆deviceName, int flags);</para>
184 </row></tbody></tgroup></informaltable>
187 <informaltable><tgroup cols="2"><tbody><row><entry
193 <para>Name of specific audio device.</para>
197 <para>int flags</para>
200 <para>A bit-wise OR of the following flags:</para>
206 <para>O_RDONLY read-only access</para>
212 <para>O_RDWR read/write access</para>
218 <para>O_NONBLOCK open in non-blocking mode</para>
224 <para>(blocking mode is the default)</para>
226 </row></tbody></tgroup></informaltable>
227 <para>RETURN VALUE</para>
228 <informaltable><tgroup cols="2"><tbody><row><entry
233 <para>Device driver not loaded/available.</para>
240 <para>Device or resource busy.</para>
247 <para>Invalid argument.</para>
249 </row></tbody></tgroup></informaltable>
252 <section id="audio_fclose">
253 <title>close()</title>
256 <informaltable><tgroup cols="1"><tbody><row><entry
258 <para>This system call closes a previously opened audio device.</para>
260 </row></tbody></tgroup></informaltable>
263 <informaltable><tgroup cols="1"><tbody><row><entry
265 <para>int close(int fd);</para>
267 </row></tbody></tgroup></informaltable>
270 <informaltable><tgroup cols="2"><tbody><row><entry
275 <para>File descriptor returned by a previous call to open().</para>
277 </row></tbody></tgroup></informaltable>
278 <para>RETURN VALUE</para>
279 <informaltable><tgroup cols="2"><tbody><row><entry
284 <para>fd is not a valid open file descriptor.</para>
286 </row></tbody></tgroup></informaltable>
289 <section id="audio_fwrite">
290 <title>write()</title>
293 <informaltable><tgroup cols="1"><tbody><row><entry
295 <para>This system call can only be used if AUDIO_SOURCE_MEMORY is selected
296 in the ioctl call AUDIO_SELECT_SOURCE. The data provided shall be in
297 PES format. If O_NONBLOCK is not specified the function will block until
298 buffer space is available. The amount of data to be transferred is implied by
301 </row></tbody></tgroup></informaltable>
304 <informaltable><tgroup cols="1"><tbody><row><entry
306 <para>size_t write(int fd, const void ⋆buf, size_t count);</para>
308 </row></tbody></tgroup></informaltable>
311 <informaltable><tgroup cols="2"><tbody><row><entry
316 <para>File descriptor returned by a previous call to open().</para>
320 <para>void *buf</para>
323 <para>Pointer to the buffer containing the PES data.</para>
327 <para>size_t count</para>
330 <para>Size of buf.</para>
332 </row></tbody></tgroup></informaltable>
333 <para>RETURN VALUE</para>
334 <informaltable><tgroup cols="2"><tbody><row><entry
339 <para>Mode AUDIO_SOURCE_MEMORY not selected.</para>
346 <para>Attempted to write more data than the internal buffer can
354 <para>fd is not a valid open file descriptor.</para>
356 </row></tbody></tgroup></informaltable>
358 </section><section id="AUDIO_STOP"
359 role="subsection"><title>AUDIO_STOP</title>
362 <informaltable><tgroup cols="1"><tbody><row><entry
364 <para>This ioctl call asks the Audio Device to stop playing the current stream.</para>
366 </row></tbody></tgroup></informaltable>
369 <informaltable><tgroup cols="1"><tbody><row><entry
371 <para>int ioctl(int fd, int request = AUDIO_STOP);</para>
373 </row></tbody></tgroup></informaltable>
376 <informaltable><tgroup cols="2"><tbody><row><entry
381 <para>File descriptor returned by a previous call to open().</para>
385 <para>int request</para>
388 <para>Equals AUDIO_STOP for this command.</para>
390 </row></tbody></tgroup></informaltable>
393 </section><section id="AUDIO_PLAY"
394 role="subsection"><title>AUDIO_PLAY</title>
397 <informaltable><tgroup cols="1"><tbody><row><entry
399 <para>This ioctl call asks the Audio Device to start playing an audio stream from the
400 selected source.</para>
402 </row></tbody></tgroup></informaltable>
405 <informaltable><tgroup cols="1"><tbody><row><entry
407 <para>int ioctl(int fd, int request = AUDIO_PLAY);</para>
409 </row></tbody></tgroup></informaltable>
412 <informaltable><tgroup cols="2"><tbody><row><entry
417 <para>File descriptor returned by a previous call to open().</para>
421 <para>int request</para>
424 <para>Equals AUDIO_PLAY for this command.</para>
426 </row></tbody></tgroup></informaltable>
429 </section><section id="AUDIO_PAUSE"
430 role="subsection"><title>AUDIO_PAUSE</title>
433 <informaltable><tgroup cols="1"><tbody><row><entry
435 <para>This ioctl call suspends the audio stream being played. Decoding and playing
436 are paused. It is then possible to restart again decoding and playing process of
437 the audio stream using AUDIO_CONTINUE command.</para>
441 <para>If AUDIO_SOURCE_MEMORY is selected in the ioctl call
442 AUDIO_SELECT_SOURCE, the DVB-subsystem will not decode (consume)
443 any more data until the ioctl call AUDIO_CONTINUE or AUDIO_PLAY is
446 </row></tbody></tgroup></informaltable>
449 <informaltable><tgroup cols="1"><tbody><row><entry
451 <para>int ioctl(int fd, int request = AUDIO_PAUSE);</para>
453 </row></tbody></tgroup></informaltable>
456 <informaltable><tgroup cols="2"><tbody><row><entry
461 <para>File descriptor returned by a previous call to open().</para>
465 <para>int request</para>
468 <para>Equals AUDIO_PAUSE for this command.</para>
470 </row></tbody></tgroup></informaltable>
473 </section><section id="AUDIO_CONTINUE"
474 role="subsection"><title>AUDIO_CONTINUE</title>
477 <informaltable><tgroup cols="1"><tbody><row><entry
479 <para>This ioctl restarts the decoding and playing process previously paused
480 with AUDIO_PAUSE command.</para>
484 <para>It only works if the stream were previously stopped with AUDIO_PAUSE</para>
486 </row></tbody></tgroup></informaltable>
489 <informaltable><tgroup cols="1"><tbody><row><entry
491 <para>int ioctl(int fd, int request = AUDIO_CONTINUE);</para>
493 </row></tbody></tgroup></informaltable>
496 <informaltable><tgroup cols="2"><tbody><row><entry
501 <para>File descriptor returned by a previous call to open().</para>
505 <para>int request</para>
508 <para>Equals AUDIO_CONTINUE for this command.</para>
510 </row></tbody></tgroup></informaltable>
513 </section><section id="AUDIO_SELECT_SOURCE"
514 role="subsection"><title>AUDIO_SELECT_SOURCE</title>
517 <informaltable><tgroup cols="1"><tbody><row><entry
519 <para>This ioctl call informs the audio device which source shall be used
520 for the input data. The possible sources are demux or memory. If
521 AUDIO_SOURCE_MEMORY is selected, the data is fed to the Audio Device
522 through the write command.</para>
524 </row></tbody></tgroup></informaltable>
527 <informaltable><tgroup cols="1"><tbody><row><entry
529 <para>int ioctl(int fd, int request = AUDIO_SELECT_SOURCE,
530 audio_stream_source_t source);</para>
532 </row></tbody></tgroup></informaltable>
535 <informaltable><tgroup cols="2"><tbody><row><entry
540 <para>File descriptor returned by a previous call to open().</para>
544 <para>int request</para>
547 <para>Equals AUDIO_SELECT_SOURCE for this command.</para>
551 <para>audio_stream_source_t
555 <para>Indicates the source that shall be used for the Audio
558 </row></tbody></tgroup></informaltable>
561 </section><section id="AUDIO_SET_MUTE"
562 role="subsection"><title>AUDIO_SET_MUTE</title>
565 <para>This ioctl is for DVB devices only. To control a V4L2 decoder use the V4L2
566 &VIDIOC-DECODER-CMD; with the <constant>V4L2_DEC_CMD_START_MUTE_AUDIO</constant> flag instead.</para>
567 <informaltable><tgroup cols="1"><tbody><row><entry
569 <para>This ioctl call asks the audio device to mute the stream that is currently being
572 </row></tbody></tgroup></informaltable>
575 <informaltable><tgroup cols="1"><tbody><row><entry
577 <para>int ioctl(int fd, int request = AUDIO_SET_MUTE,
578 boolean state);</para>
580 </row></tbody></tgroup></informaltable>
583 <informaltable><tgroup cols="2"><tbody><row><entry
588 <para>File descriptor returned by a previous call to open().</para>
592 <para>int request</para>
595 <para>Equals AUDIO_SET_MUTE for this command.</para>
599 <para>boolean state</para>
602 <para>Indicates if audio device shall mute or not.</para>
608 <para>TRUE Audio Mute</para>
614 <para>FALSE Audio Un-mute</para>
616 </row></tbody></tgroup></informaltable>
619 </section><section id="AUDIO_SET_AV_SYNC"
620 role="subsection"><title>AUDIO_SET_AV_SYNC</title>
623 <informaltable><tgroup cols="1"><tbody><row><entry
625 <para>This ioctl call asks the Audio Device to turn ON or OFF A/V synchronization.</para>
627 </row></tbody></tgroup></informaltable>
630 <informaltable><tgroup cols="1"><tbody><row><entry
632 <para>int ioctl(int fd, int request = AUDIO_SET_AV_SYNC,
633 boolean state);</para>
635 </row></tbody></tgroup></informaltable>
638 <informaltable><tgroup cols="2"><tbody><row><entry
643 <para>File descriptor returned by a previous call to open().</para>
647 <para>int request</para>
650 <para>Equals AUDIO_AV_SYNC for this command.</para>
654 <para>boolean state</para>
657 <para>Tells the DVB subsystem if A/V synchronization shall be
664 <para>TRUE AV-sync ON</para>
670 <para>FALSE AV-sync OFF</para>
672 </row></tbody></tgroup></informaltable>
675 </section><section id="AUDIO_SET_BYPASS_MODE"
676 role="subsection"><title>AUDIO_SET_BYPASS_MODE</title>
679 <informaltable><tgroup cols="1"><tbody><row><entry
681 <para>This ioctl call asks the Audio Device to bypass the Audio decoder and forward
682 the stream without decoding. This mode shall be used if streams that can’t be
683 handled by the DVB system shall be decoded. Dolby DigitalTM streams are
684 automatically forwarded by the DVB subsystem if the hardware can handle it.</para>
686 </row></tbody></tgroup></informaltable>
689 <informaltable><tgroup cols="1"><tbody><row><entry
691 <para>int ioctl(int fd, int request =
692 AUDIO_SET_BYPASS_MODE, boolean mode);</para>
694 </row></tbody></tgroup></informaltable>
697 <informaltable><tgroup cols="2"><tbody><row><entry
702 <para>File descriptor returned by a previous call to open().</para>
706 <para>int request</para>
709 <para>Equals AUDIO_SET_BYPASS_MODE for this
714 <para>boolean mode</para>
717 <para>Enables or disables the decoding of the current Audio
718 stream in the DVB subsystem.</para>
724 <para>TRUE Bypass is disabled</para>
730 <para>FALSE Bypass is enabled</para>
732 </row></tbody></tgroup></informaltable>
735 </section><section id="AUDIO_CHANNEL_SELECT"
736 role="subsection"><title>AUDIO_CHANNEL_SELECT</title>
739 <para>This ioctl is for DVB devices only. To control a V4L2 decoder use the V4L2
740 <constant>V4L2_CID_MPEG_AUDIO_DEC_PLAYBACK</constant> control instead.</para>
741 <informaltable><tgroup cols="1"><tbody><row><entry
743 <para>This ioctl call asks the Audio Device to select the requested channel if possible.</para>
745 </row></tbody></tgroup></informaltable>
748 <informaltable><tgroup cols="1"><tbody><row><entry
750 <para>int ioctl(int fd, int request =
751 AUDIO_CHANNEL_SELECT, audio_channel_select_t);</para>
753 </row></tbody></tgroup></informaltable>
756 <informaltable><tgroup cols="2"><tbody><row><entry
761 <para>File descriptor returned by a previous call to open().</para>
765 <para>int request</para>
768 <para>Equals AUDIO_CHANNEL_SELECT for this
773 <para>audio_channel_select_t
777 <para>Select the output format of the audio (mono left/right,
780 </row></tbody></tgroup></informaltable>
783 </section><section id="AUDIO_BILINGUAL_CHANNEL_SELECT"
784 role="subsection"><title>AUDIO_BILINGUAL_CHANNEL_SELECT</title>
787 <para>This ioctl is obsolete. Do not use in new drivers. It has been replaced by
788 the V4L2 <constant>V4L2_CID_MPEG_AUDIO_DEC_MULTILINGUAL_PLAYBACK</constant> control
789 for MPEG decoders controlled through V4L2.</para>
790 <informaltable><tgroup cols="1"><tbody><row><entry
792 <para>This ioctl call asks the Audio Device to select the requested channel for bilingual streams if possible.</para>
794 </row></tbody></tgroup></informaltable>
797 <informaltable><tgroup cols="1"><tbody><row><entry
799 <para>int ioctl(int fd, int request =
800 AUDIO_BILINGUAL_CHANNEL_SELECT, audio_channel_select_t);</para>
802 </row></tbody></tgroup></informaltable>
805 <informaltable><tgroup cols="2"><tbody><row><entry
810 <para>File descriptor returned by a previous call to open().</para>
814 <para>int request</para>
817 <para>Equals AUDIO_BILINGUAL_CHANNEL_SELECT for this
822 <para>audio_channel_select_t
826 <para>Select the output format of the audio (mono left/right,
830 </tbody></tgroup></informaltable>
833 </section><section id="AUDIO_GET_PTS"
834 role="subsection"><title>AUDIO_GET_PTS</title>
837 <para>This ioctl is obsolete. Do not use in new drivers. If you need this functionality,
838 then please contact the linux-media mailing list (&v4l-ml;).</para>
839 <informaltable><tgroup cols="1"><tbody><row><entry
841 <para>This ioctl call asks the Audio Device to return the current PTS timestamp.</para>
843 </row></tbody></tgroup></informaltable>
846 <informaltable><tgroup cols="1"><tbody><row><entry
848 <para>int ioctl(int fd, int request =
849 AUDIO_GET_PTS, __u64 *pts);</para>
851 </row></tbody></tgroup></informaltable>
854 <informaltable><tgroup cols="2"><tbody><row><entry
859 <para>File descriptor returned by a previous call to open().</para>
863 <para>int request</para>
866 <para>Equals AUDIO_GET_PTS for this
875 <para>Returns the 33-bit timestamp as defined in ITU T-REC-H.222.0 / ISO/IEC 13818-1.
878 The PTS should belong to the currently played
879 frame if possible, but may also be a value close to it
880 like the PTS of the last decoded frame or the last PTS
881 extracted by the PES parser.</para>
883 </row></tbody></tgroup></informaltable>
886 </section><section id="AUDIO_GET_STATUS"
887 role="subsection"><title>AUDIO_GET_STATUS</title>
890 <informaltable><tgroup cols="1"><tbody><row><entry
892 <para>This ioctl call asks the Audio Device to return the current state of the Audio
895 </row></tbody></tgroup></informaltable>
898 <informaltable><tgroup cols="1"><tbody><row><entry
900 <para>int ioctl(int fd, int request = AUDIO_GET_STATUS,
901 struct audio_status ⋆status);</para>
903 </row></tbody></tgroup></informaltable>
906 <informaltable><tgroup cols="2"><tbody><row><entry
911 <para>File descriptor returned by a previous call to open().</para>
915 <para>int request</para>
918 <para>Equals AUDIO_GET_STATUS for this command.</para>
922 <para>struct audio_status
926 <para>Returns the current state of Audio Device.</para>
928 </row></tbody></tgroup></informaltable>
931 </section><section id="AUDIO_GET_CAPABILITIES"
932 role="subsection"><title>AUDIO_GET_CAPABILITIES</title>
935 <informaltable><tgroup cols="1"><tbody><row><entry
937 <para>This ioctl call asks the Audio Device to tell us about the decoding capabilities
938 of the audio hardware.</para>
940 </row></tbody></tgroup></informaltable>
943 <informaltable><tgroup cols="1"><tbody><row><entry
945 <para>int ioctl(int fd, int request =
946 AUDIO_GET_CAPABILITIES, unsigned int ⋆cap);</para>
948 </row></tbody></tgroup></informaltable>
951 <informaltable><tgroup cols="2"><tbody><row><entry
956 <para>File descriptor returned by a previous call to open().</para>
960 <para>int request</para>
963 <para>Equals AUDIO_GET_CAPABILITIES for this
968 <para>unsigned int *cap</para>
971 <para>Returns a bit array of supported sound formats.</para>
973 </row></tbody></tgroup></informaltable>
976 </section><section id="AUDIO_CLEAR_BUFFER"
977 role="subsection"><title>AUDIO_CLEAR_BUFFER</title>
980 <informaltable><tgroup cols="1"><tbody><row><entry
982 <para>This ioctl call asks the Audio Device to clear all software and hardware buffers
983 of the audio decoder device.</para>
985 </row></tbody></tgroup></informaltable>
988 <informaltable><tgroup cols="1"><tbody><row><entry
990 <para>int ioctl(int fd, int request = AUDIO_CLEAR_BUFFER);</para>
992 </row></tbody></tgroup></informaltable>
995 <informaltable><tgroup cols="2"><tbody><row><entry
1000 <para>File descriptor returned by a previous call to open().</para>
1004 <para>int request</para>
1007 <para>Equals AUDIO_CLEAR_BUFFER for this command.</para>
1009 </row></tbody></tgroup></informaltable>
1012 </section><section id="AUDIO_SET_ID"
1013 role="subsection"><title>AUDIO_SET_ID</title>
1016 <informaltable><tgroup cols="1"><tbody><row><entry
1018 <para>This ioctl selects which sub-stream is to be decoded if a program or system
1019 stream is sent to the video device. If no audio stream type is set the id has to be
1020 in [0xC0,0xDF] for MPEG sound, in [0x80,0x87] for AC3 and in [0xA0,0xA7]
1021 for LPCM. More specifications may follow for other stream types. If the stream
1022 type is set the id just specifies the substream id of the audio stream and only
1023 the first 5 bits are recognized.</para>
1025 </row></tbody></tgroup></informaltable>
1028 <informaltable><tgroup cols="1"><tbody><row><entry
1030 <para>int ioctl(int fd, int request = AUDIO_SET_ID, int
1033 </row></tbody></tgroup></informaltable>
1036 <informaltable><tgroup cols="2"><tbody><row><entry
1041 <para>File descriptor returned by a previous call to open().</para>
1045 <para>int request</para>
1048 <para>Equals AUDIO_SET_ID for this command.</para>
1055 <para>audio sub-stream id</para>
1057 </row></tbody></tgroup></informaltable>
1060 </section><section id="AUDIO_SET_MIXER"
1061 role="subsection"><title>AUDIO_SET_MIXER</title>
1064 <informaltable><tgroup cols="1"><tbody><row><entry
1066 <para>This ioctl lets you adjust the mixer settings of the audio decoder.</para>
1068 </row></tbody></tgroup></informaltable>
1071 <informaltable><tgroup cols="1"><tbody><row><entry
1073 <para>int ioctl(int fd, int request = AUDIO_SET_MIXER,
1074 audio_mixer_t ⋆mix);</para>
1076 </row></tbody></tgroup></informaltable>
1079 <informaltable><tgroup cols="2"><tbody><row><entry
1084 <para>File descriptor returned by a previous call to open().</para>
1088 <para>int request</para>
1091 <para>Equals AUDIO_SET_ID for this command.</para>
1095 <para>audio_mixer_t *mix</para>
1098 <para>mixer settings.</para>
1100 </row></tbody></tgroup></informaltable>
1103 </section><section id="AUDIO_SET_STREAMTYPE"
1104 role="subsection"><title>AUDIO_SET_STREAMTYPE</title>
1107 <informaltable><tgroup cols="1"><tbody><row><entry
1109 <para>This ioctl tells the driver which kind of audio stream to expect. This is useful
1110 if the stream offers several audio sub-streams like LPCM and AC3.</para>
1112 </row></tbody></tgroup></informaltable>
1115 <informaltable><tgroup cols="1"><tbody><row><entry
1117 <para>int ioctl(fd, int request = AUDIO_SET_STREAMTYPE,
1120 </row></tbody></tgroup></informaltable>
1123 <informaltable><tgroup cols="2"><tbody><row><entry
1128 <para>File descriptor returned by a previous call to open().</para>
1132 <para>int request</para>
1135 <para>Equals AUDIO_SET_STREAMTYPE for this
1140 <para>int type</para>
1143 <para>stream type</para>
1145 </row></tbody></tgroup></informaltable>
1147 <informaltable><tgroup cols="2"><tbody><row><entry
1152 <para>type is not a valid or supported stream type.</para>
1154 </row></tbody></tgroup></informaltable>
1156 </section><section id="AUDIO_SET_EXT_ID"
1157 role="subsection"><title>AUDIO_SET_EXT_ID</title>
1160 <informaltable><tgroup cols="1"><tbody><row><entry
1162 <para>This ioctl can be used to set the extension id for MPEG streams in DVD
1163 playback. Only the first 3 bits are recognized.</para>
1165 </row></tbody></tgroup></informaltable>
1168 <informaltable><tgroup cols="1"><tbody><row><entry
1170 <para>int ioctl(fd, int request = AUDIO_SET_EXT_ID, int
1173 </row></tbody></tgroup></informaltable>
1176 <informaltable><tgroup cols="2"><tbody><row><entry
1181 <para>File descriptor returned by a previous call to open().</para>
1185 <para>int request</para>
1188 <para>Equals AUDIO_SET_EXT_ID for this command.</para>
1195 <para>audio sub_stream_id</para>
1197 </row></tbody></tgroup></informaltable>
1199 <informaltable><tgroup cols="2"><tbody><row><entry
1204 <para>id is not a valid id.</para>
1206 </row></tbody></tgroup></informaltable>
1208 </section><section id="AUDIO_SET_ATTRIBUTES"
1209 role="subsection"><title>AUDIO_SET_ATTRIBUTES</title>
1212 <informaltable><tgroup cols="1"><tbody><row><entry
1214 <para>This ioctl is intended for DVD playback and allows you to set certain
1215 information about the audio stream.</para>
1217 </row></tbody></tgroup></informaltable>
1220 <informaltable><tgroup cols="1"><tbody><row><entry
1222 <para>int ioctl(fd, int request = AUDIO_SET_ATTRIBUTES,
1223 audio_attributes_t attr );</para>
1225 </row></tbody></tgroup></informaltable>
1228 <informaltable><tgroup cols="2"><tbody><row><entry
1233 <para>File descriptor returned by a previous call to open().</para>
1237 <para>int request</para>
1240 <para>Equals AUDIO_SET_ATTRIBUTES for this command.</para>
1244 <para>audio_attributes_t
1248 <para>audio attributes according to section ??</para>
1250 </row></tbody></tgroup></informaltable>
1252 <informaltable><tgroup cols="2"><tbody><row><entry
1257 <para>attr is not a valid or supported attribute setting.</para>
1259 </row></tbody></tgroup></informaltable>
1261 </section><section id="AUDIO_SET_KARAOKE"
1262 role="subsection"><title>AUDIO_SET_KARAOKE</title>
1265 <informaltable><tgroup cols="1"><tbody><row><entry
1267 <para>This ioctl allows one to set the mixer settings for a karaoke DVD.</para>
1269 </row></tbody></tgroup></informaltable>
1272 <informaltable><tgroup cols="1"><tbody><row><entry
1274 <para>int ioctl(fd, int request = AUDIO_SET_KARAOKE,
1275 audio_karaoke_t ⋆karaoke);</para>
1277 </row></tbody></tgroup></informaltable>
1280 <informaltable><tgroup cols="2"><tbody><row><entry
1285 <para>File descriptor returned by a previous call to open().</para>
1289 <para>int request</para>
1292 <para>Equals AUDIO_SET_KARAOKE for this
1297 <para>audio_karaoke_t
1301 <para>karaoke settings according to section ??.</para>
1303 </row></tbody></tgroup></informaltable>
1305 <informaltable><tgroup cols="2"><tbody><row><entry
1310 <para>karaoke is not a valid or supported karaoke setting.</para>
1312 </row></tbody></tgroup></informaltable>