1 <title>DVB Video Device</title>
2 <para>The DVB video device controls the MPEG2 video decoder of the DVB hardware. It
3 can be accessed through <emphasis role="tt">/dev/dvb/adapter0/video0</emphasis>. Data types and and
4 ioctl definitions can be accessed by including <emphasis role="tt">linux/dvb/video.h</emphasis> in your
7 <para>Note that the DVB video device only controls decoding of the MPEG video stream, not
8 its presentation on the TV or computer screen. On PCs this is typically handled by an
9 associated video4linux device, e.g. <emphasis role="tt">/dev/video</emphasis>, which allows scaling and defining output
12 <para>Some DVB cards don’t have their own MPEG decoder, which results in the omission of
13 the audio and video device as well as the video4linux device.
15 <para>The ioctls that deal with SPUs (sub picture units) and navigation packets are only
16 supported on some MPEG decoders made for DVD playback.
18 <section id="video_types">
19 <title>Video Data Types</title>
21 <section id="video_format_t">
22 <title>video_format_t</title>
23 <para>The <emphasis role="tt">video_format_t</emphasis> data type defined by
31 <para>is used in the VIDEO_SET_FORMAT function (??) to tell the driver which aspect ratio
32 the output hardware (e.g. TV) has. It is also used in the data structures video_status
33 (??) returned by VIDEO_GET_STATUS (??) and video_event (??) returned by
34 VIDEO_GET_EVENT (??) which report about the display format of the current video
39 <section id="video_display_format_t">
40 <title>video_display_format_t</title>
41 <para>In case the display format of the video stream and of the display hardware differ the
42 application has to specify how to handle the cropping of the picture. This can be done using
43 the VIDEO_SET_DISPLAY_FORMAT call (??) which accepts
50 } video_display_format_t;
56 <section id="video_stream_source">
57 <title>video stream source</title>
58 <para>The video stream source is set through the VIDEO_SELECT_SOURCE call and can take
59 the following values, depending on whether we are replaying from an internal (demuxer) or
60 external (user write) source.
66 } video_stream_source_t;
68 <para>VIDEO_SOURCE_DEMUX selects the demultiplexer (fed either by the frontend or the
69 DVR device) as the source of the video stream. If VIDEO_SOURCE_MEMORY
70 is selected the stream comes from the application through the <emphasis role="tt">write()</emphasis> system
75 <section id="video_play_state">
76 <title>video play state</title>
77 <para>The following values can be returned by the VIDEO_GET_STATUS call representing the
78 state of video playback.
89 <section id="video_event">
90 <title>struct video_event</title>
91 <para>The following is the structure of a video event as it is returned by the VIDEO_GET_EVENT
99 video_format_t video_format;
105 <section id="video_status">
106 <title>struct video_status</title>
107 <para>The VIDEO_GET_STATUS call returns the following structure informing about various
108 states of the playback operation.
111 struct video_status {
113 video_play_state_t play_state;
114 video_stream_source_t stream_source;
115 video_format_t video_format;
116 video_displayformat_t display_format;
119 <para>If video_blank is set video will be blanked out if the channel is changed or if playback is
120 stopped. Otherwise, the last picture will be displayed. play_state indicates if the video is
121 currently frozen, stopped, or being played back. The stream_source corresponds to the seleted
122 source for the video stream. It can come either from the demultiplexer or from memory.
123 The video_format indicates the aspect ratio (one of 4:3 or 16:9) of the currently
124 played video stream. Finally, display_format corresponds to the selected cropping
125 mode in case the source video format is not the same as the format of the output
130 <section id="video_still_picture">
131 <title>struct video_still_picture</title>
132 <para>An I-frame displayed via the VIDEO_STILLPICTURE call is passed on within the
136 /⋆ pointer to and size of a single iframe in memory ⋆/
137 struct video_still_picture {
144 <section id="video_caps">
145 <title>video capabilities</title>
146 <para>A call to VIDEO_GET_CAPABILITIES returns an unsigned integer with the following
147 bits set according to the hardwares capabilities.
150 /⋆ bit definitions for capabilities: ⋆/
151 /⋆ can the hardware decode MPEG1 and/or MPEG2? ⋆/
152 #define VIDEO_CAP_MPEG1 1
153 #define VIDEO_CAP_MPEG2 2
154 /⋆ can you send a system and/or program stream to video device?
155 (you still have to open the video and the audio device but only
156 send the stream to the video device) ⋆/
157 #define VIDEO_CAP_SYS 4
158 #define VIDEO_CAP_PROG 8
159 /⋆ can the driver also handle SPU, NAVI and CSS encoded data?
160 (CSS API is not present yet) ⋆/
161 #define VIDEO_CAP_SPU 16
162 #define VIDEO_CAP_NAVI 32
163 #define VIDEO_CAP_CSS 64
167 <section id="video_system">
168 <title>video system</title>
169 <para>A call to VIDEO_SET_SYSTEM sets the desired video system for TV output. The
170 following system types can be set:
186 <section id="video_highlight">
187 <title>struct video_highlight</title>
188 <para>Calling the ioctl VIDEO_SET_HIGHLIGHTS posts the SPU highlight information. The
189 call expects the following format for that information:
193 struct video_highlight {
194 boolean active; /⋆ 1=show highlight, 0=hide highlight ⋆/
195 uint8_t contrast1; /⋆ 7- 4 Pattern pixel contrast ⋆/
196 /⋆ 3- 0 Background pixel contrast ⋆/
197 uint8_t contrast2; /⋆ 7- 4 Emphasis pixel-2 contrast ⋆/
198 /⋆ 3- 0 Emphasis pixel-1 contrast ⋆/
199 uint8_t color1; /⋆ 7- 4 Pattern pixel color ⋆/
200 /⋆ 3- 0 Background pixel color ⋆/
201 uint8_t color2; /⋆ 7- 4 Emphasis pixel-2 color ⋆/
202 /⋆ 3- 0 Emphasis pixel-1 color ⋆/
203 uint32_t ypos; /⋆ 23-22 auto action mode ⋆/
204 /⋆ 21-12 start y ⋆/
205 /⋆ 9- 0 end y ⋆/
206 uint32_t xpos; /⋆ 23-22 button color number ⋆/
207 /⋆ 21-12 start x ⋆/
208 /⋆ 9- 0 end x ⋆/
213 <section id="video_spu">
214 <title>video SPU</title>
215 <para>Calling VIDEO_SET_SPU deactivates or activates SPU decoding, according to the
227 <section id="video_spu_palette">
228 <title>video SPU palette</title>
229 <para>The following structure is used to set the SPU palette by calling VIDEO_SPU_PALETTE:
233 struct video_spu_palette{
235 uint8_t ⋆palette;
236 } video_spu_palette_t;
240 <section id="video_navi_pack">
241 <title>video NAVI pack</title>
242 <para>In order to get the navigational data the following structure has to be passed to the ioctl
247 struct video_navi_pack{
248 int length; /⋆ 0 ... 1024 ⋆/
255 <section id="video_attributes">
256 <title>video attributes</title>
257 <para>The following attributes can be set by a call to VIDEO_SET_ATTRIBUTES:
260 typedef uint16_t video_attributes_t;
261 /⋆ bits: descr. ⋆/
262 /⋆ 15-14 Video compression mode (0=MPEG-1, 1=MPEG-2) ⋆/
263 /⋆ 13-12 TV system (0=525/60, 1=625/50) ⋆/
264 /⋆ 11-10 Aspect ratio (0=4:3, 3=16:9) ⋆/
265 /⋆ 9- 8 permitted display mode on 4:3 monitor (0=both, 1=only pan-sca ⋆/
266 /⋆ 7 line 21-1 data present in GOP (1=yes, 0=no) ⋆/
267 /⋆ 6 line 21-2 data present in GOP (1=yes, 0=no) ⋆/
268 /⋆ 5- 3 source resolution (0=720x480/576, 1=704x480/576, 2=352x480/57 ⋆/
269 /⋆ 2 source letterboxed (1=yes, 0=no) ⋆/
270 /⋆ 0 film/camera mode (0=camera, 1=film (625/50 only)) ⋆/
275 <section id="video_function_calls">
276 <title>Video Function Calls</title>
279 <section id="video_fopen">
280 <title>open()</title>
283 <informaltable><tgroup cols="1"><tbody><row><entry
285 <para>This system call opens a named video device (e.g. /dev/dvb/adapter0/video0)
286 for subsequent use.</para>
287 <para>When an open() call has succeeded, the device will be ready for use.
288 The significance of blocking or non-blocking mode is described in the
289 documentation for functions where there is a difference. It does not affect the
290 semantics of the open() call itself. A device opened in blocking mode can later
291 be put into non-blocking mode (and vice versa) using the F_SETFL command
292 of the fcntl system call. This is a standard system call, documented in the Linux
293 manual page for fcntl. Only one user can open the Video Device in O_RDWR
294 mode. All other attempts to open the device in this mode will fail, and an
295 error-code will be returned. If the Video Device is opened in O_RDONLY
296 mode, the only ioctl call that can be used is VIDEO_GET_STATUS. All other
297 call will return an error code.</para>
299 </row></tbody></tgroup></informaltable>
303 <informaltable><tgroup cols="1"><tbody><row><entry
305 <para>int open(const char ⋆deviceName, int flags);</para>
307 </row></tbody></tgroup></informaltable>
310 <informaltable><tgroup cols="2"><tbody><row><entry
316 <para>Name of specific video device.</para>
320 <para>int flags</para>
323 <para>A bit-wise OR of the following flags:</para>
329 <para>O_RDONLY read-only access</para>
335 <para>O_RDWR read/write access</para>
341 <para>O_NONBLOCK open in non-blocking mode</para>
347 <para>(blocking mode is the default)</para>
349 </row></tbody></tgroup></informaltable>
352 <informaltable><tgroup cols="2"><tbody><row><entry
357 <para>Device driver not loaded/available.</para>
361 <para>EINTERNAL</para>
364 <para>Internal error.</para>
371 <para>Device or resource busy.</para>
378 <para>Invalid argument.</para>
380 </row></tbody></tgroup></informaltable>
383 <section id="video_fclose">
384 <title>close()</title>
387 <informaltable><tgroup cols="1"><tbody><row><entry
389 <para>This system call closes a previously opened video device.</para>
391 </row></tbody></tgroup></informaltable>
394 <informaltable><tgroup cols="1"><tbody><row><entry
396 <para>int close(int fd);</para>
398 </row></tbody></tgroup></informaltable>
401 <informaltable><tgroup cols="2"><tbody><row><entry
406 <para>File descriptor returned by a previous call to open().</para>
408 </row></tbody></tgroup></informaltable>
411 <informaltable><tgroup cols="2"><tbody><row><entry
416 <para>fd is not a valid open file descriptor.</para>
418 </row></tbody></tgroup></informaltable>
421 <section id="video_fwrite">
422 <title>write()</title>
425 <informaltable><tgroup cols="1"><tbody><row><entry
427 <para>This system call can only be used if VIDEO_SOURCE_MEMORY is selected
428 in the ioctl call VIDEO_SELECT_SOURCE. The data provided shall be in
429 PES format, unless the capability allows other formats. If O_NONBLOCK is
430 not specified the function will block until buffer space is available. The amount
431 of data to be transferred is implied by count.</para>
433 </row></tbody></tgroup></informaltable>
436 <informaltable><tgroup cols="1"><tbody><row><entry
438 <para>size_t write(int fd, const void ⋆buf, size_t count);</para>
440 </row></tbody></tgroup></informaltable>
443 <informaltable><tgroup cols="2"><tbody><row><entry
448 <para>File descriptor returned by a previous call to open().</para>
452 <para>void *buf</para>
455 <para>Pointer to the buffer containing the PES data.</para>
459 <para>size_t count</para>
462 <para>Size of buf.</para>
464 </row></tbody></tgroup></informaltable>
467 <informaltable><tgroup cols="2"><tbody><row><entry
472 <para>Mode VIDEO_SOURCE_MEMORY not selected.</para>
479 <para>Attempted to write more data than the internal buffer can
487 <para>fd is not a valid open file descriptor.</para>
489 </row></tbody></tgroup></informaltable>
492 role="subsection"><title>VIDEO_STOP</title>
495 <informaltable><tgroup cols="1"><tbody><row><entry
497 <para>This ioctl call asks the Video Device to stop playing the current stream.
498 Depending on the input parameter, the screen can be blanked out or displaying
499 the last decoded frame.</para>
501 </row></tbody></tgroup></informaltable>
504 <informaltable><tgroup cols="1"><tbody><row><entry
506 <para>int ioctl(fd, int request = VIDEO_STOP, boolean
509 </row></tbody></tgroup></informaltable>
512 <informaltable><tgroup cols="2"><tbody><row><entry
517 <para>File descriptor returned by a previous call to open().</para>
521 <para>int request</para>
524 <para>Equals VIDEO_STOP for this command.</para>
528 <para>Boolean mode</para>
531 <para>Indicates how the screen shall be handled.</para>
537 <para>TRUE: Blank screen when stop.</para>
543 <para>FALSE: Show last decoded frame.</para>
545 </row></tbody></tgroup></informaltable>
548 <informaltable><tgroup cols="2"><tbody><row><entry
553 <para>fd is not a valid open file descriptor</para>
557 <para>EINTERNAL</para>
560 <para>Internal error, possibly in the communication with the
561 DVB subsystem.</para>
563 </row></tbody></tgroup></informaltable>
566 role="subsection"><title>VIDEO_PLAY</title>
569 <informaltable><tgroup cols="1"><tbody><row><entry
571 <para>This ioctl call asks the Video Device to start playing a video stream from the
572 selected source.</para>
574 </row></tbody></tgroup></informaltable>
577 <informaltable><tgroup cols="1"><tbody><row><entry
579 <para>int ioctl(fd, int request = VIDEO_PLAY);</para>
581 </row></tbody></tgroup></informaltable>
584 <informaltable><tgroup cols="2"><tbody><row><entry
589 <para>File descriptor returned by a previous call to open().</para>
593 <para>int request</para>
596 <para>Equals VIDEO_PLAY for this command.</para>
598 </row></tbody></tgroup></informaltable>
601 <informaltable><tgroup cols="2"><tbody><row><entry
606 <para>fd is not a valid open file descriptor</para>
610 <para>EINTERNAL</para>
613 <para>Internal error, possibly in the communication with the
614 DVB subsystem.</para>
616 </row></tbody></tgroup></informaltable>
619 role="subsection"><title>VIDEO_FREEZE</title>
622 <informaltable><tgroup cols="1"><tbody><row><entry
624 <para>This ioctl call suspends the live video stream being played. Decoding
625 and playing are frozen. It is then possible to restart the decoding
626 and playing process of the video stream using the VIDEO_CONTINUE
627 command. If VIDEO_SOURCE_MEMORY is selected in the ioctl call
628 VIDEO_SELECT_SOURCE, the DVB subsystem will not decode any more
629 data until the ioctl call VIDEO_CONTINUE or VIDEO_PLAY is performed.</para>
631 </row></tbody></tgroup></informaltable>
634 <informaltable><tgroup cols="1"><tbody><row><entry
636 <para>int ioctl(fd, int request = VIDEO_FREEZE);</para>
638 </row></tbody></tgroup></informaltable>
641 <informaltable><tgroup cols="2"><tbody><row><entry
646 <para>File descriptor returned by a previous call to open().</para>
650 <para>int request</para>
653 <para>Equals VIDEO_FREEZE for this command.</para>
655 </row></tbody></tgroup></informaltable>
658 <informaltable><tgroup cols="2"><tbody><row><entry
663 <para>fd is not a valid open file descriptor</para>
667 <para>EINTERNAL</para>
670 <para>Internal error, possibly in the communication with the
671 DVB subsystem.</para>
673 </row></tbody></tgroup></informaltable>
676 role="subsection"><title>VIDEO_CONTINUE</title>
679 <informaltable><tgroup cols="1"><tbody><row><entry
681 <para>This ioctl call restarts decoding and playing processes of the video stream
682 which was played before a call to VIDEO_FREEZE was made.</para>
684 </row></tbody></tgroup></informaltable>
687 <informaltable><tgroup cols="1"><tbody><row><entry
689 <para>int ioctl(fd, int request = VIDEO_CONTINUE);</para>
691 </row></tbody></tgroup></informaltable>
694 <informaltable><tgroup cols="2"><tbody><row><entry
699 <para>File descriptor returned by a previous call to open().</para>
703 <para>int request</para>
706 <para>Equals VIDEO_CONTINUE for this command.</para>
708 </row></tbody></tgroup></informaltable>
711 <informaltable><tgroup cols="2"><tbody><row><entry
716 <para>fd is not a valid open file descriptor</para>
720 <para>EINTERNAL</para>
723 <para>Internal error, possibly in the communication with the
724 DVB subsystem.</para>
726 </row></tbody></tgroup></informaltable>
729 role="subsection"><title>VIDEO_SELECT_SOURCE</title>
732 <informaltable><tgroup cols="1"><tbody><row><entry
734 <para>This ioctl call informs the video device which source shall be used for the input
735 data. The possible sources are demux or memory. If memory is selected, the
736 data is fed to the video device through the write command.</para>
738 </row></tbody></tgroup></informaltable>
741 <informaltable><tgroup cols="1"><tbody><row><entry
743 <para>int ioctl(fd, int request = VIDEO_SELECT_SOURCE,
744 video_stream_source_t source);</para>
746 </row></tbody></tgroup></informaltable>
749 <informaltable><tgroup cols="2"><tbody><row><entry
754 <para>File descriptor returned by a previous call to open().</para>
758 <para>int request</para>
761 <para>Equals VIDEO_SELECT_SOURCE for this command.</para>
765 <para>video_stream_source_t
769 <para>Indicates which source shall be used for the Video stream.</para>
771 </row></tbody></tgroup></informaltable>
774 <informaltable><tgroup cols="2"><tbody><row><entry
779 <para>fd is not a valid open file descriptor</para>
783 <para>EINTERNAL</para>
786 <para>Internal error, possibly in the communication with the
787 DVB subsystem.</para>
789 </row></tbody></tgroup></informaltable>
792 role="subsection"><title>VIDEO_SET_BLANK</title>
795 <informaltable><tgroup cols="1"><tbody><row><entry
797 <para>This ioctl call asks the Video Device to blank out the picture.</para>
799 </row></tbody></tgroup></informaltable>
802 <informaltable><tgroup cols="1"><tbody><row><entry
804 <para>int ioctl(fd, int request = VIDEO_SET_BLANK, boolean
807 </row></tbody></tgroup></informaltable>
810 <informaltable><tgroup cols="2"><tbody><row><entry
815 <para>File descriptor returned by a previous call to open().</para>
819 <para>int request</para>
822 <para>Equals VIDEO_SET_BLANK for this command.</para>
826 <para>boolean mode</para>
829 <para>TRUE: Blank screen when stop.</para>
835 <para>FALSE: Show last decoded frame.</para>
837 </row></tbody></tgroup></informaltable>
840 <informaltable><tgroup cols="2"><tbody><row><entry
845 <para>fd is not a valid open file descriptor</para>
849 <para>EINTERNAL</para>
852 <para>Internal error, possibly in the communication with the
853 DVB subsystem.</para>
860 <para>Illegal input parameter</para>
862 </row></tbody></tgroup></informaltable>
865 role="subsection"><title>VIDEO_GET_STATUS</title>
868 <informaltable><tgroup cols="1"><tbody><row><entry
870 <para>This ioctl call asks the Video Device to return the current status of the device.</para>
872 </row></tbody></tgroup></informaltable>
875 <informaltable><tgroup cols="1"><tbody><row><entry
877 <para> int ioctl(fd, int request = VIDEO_GET_STATUS, struct
878 video_status ⋆status);</para>
880 </row></tbody></tgroup></informaltable>
883 <informaltable><tgroup cols="2"><tbody><row><entry
888 <para>File descriptor returned by a previous call to open().</para>
892 <para>int request</para>
895 <para>Equals VIDEO_GET_STATUS for this command.</para>
899 <para>struct video_status
903 <para>Returns the current status of the Video Device.</para>
905 </row></tbody></tgroup></informaltable>
908 <informaltable><tgroup cols="2"><tbody><row><entry
913 <para>fd is not a valid open file descriptor</para>
917 <para>EINTERNAL</para>
920 <para>Internal error, possibly in the communication with the
921 DVB subsystem.</para>
928 <para>status points to invalid address</para>
930 </row></tbody></tgroup></informaltable>
933 role="subsection"><title>VIDEO_GET_EVENT</title>
936 <informaltable><tgroup cols="1"><tbody><row><entry
938 <para>This ioctl call returns an event of type video_event if available. If an event is
939 not available, the behavior depends on whether the device is in blocking or
940 non-blocking mode. In the latter case, the call fails immediately with errno
941 set to EWOULDBLOCK. In the former case, the call blocks until an event
942 becomes available. The standard Linux poll() and/or select() system calls can
943 be used with the device file descriptor to watch for new events. For select(),
944 the file descriptor should be included in the exceptfds argument, and for
945 poll(), POLLPRI should be specified as the wake-up condition. Read-only
946 permissions are sufficient for this ioctl call.</para>
948 </row></tbody></tgroup></informaltable>
951 <informaltable><tgroup cols="1"><tbody><row><entry
953 <para> int ioctl(fd, int request = VIDEO_GET_EVENT, struct
954 video_event ⋆ev);</para>
956 </row></tbody></tgroup></informaltable>
959 <informaltable><tgroup cols="2"><tbody><row><entry
964 <para>File descriptor returned by a previous call to open().</para>
968 <para>int request</para>
971 <para>Equals VIDEO_GET_EVENT for this command.</para>
975 <para>struct video_event
979 <para>Points to the location where the event, if any, is to be
982 </row></tbody></tgroup></informaltable>
985 <informaltable><tgroup cols="2"><tbody><row><entry
990 <para>fd is not a valid open file descriptor</para>
997 <para>ev points to invalid address</para>
1001 <para>EWOULDBLOCK</para>
1004 <para>There is no event pending, and the device is in
1005 non-blocking mode.</para>
1009 <para>EOVERFLOW</para>
1017 <para>Overflow in event queue - one or more events were lost.</para>
1019 </row></tbody></tgroup></informaltable>
1022 role="subsection"><title>VIDEO_SET_DISPLAY_FORMAT</title>
1025 <informaltable><tgroup cols="1"><tbody><row><entry
1027 <para>This ioctl call asks the Video Device to select the video format to be applied
1028 by the MPEG chip on the video.</para>
1030 </row></tbody></tgroup></informaltable>
1033 <informaltable><tgroup cols="1"><tbody><row><entry
1035 <para> int ioctl(fd, int request =
1036 VIDEO_SET_DISPLAY_FORMAT, video_display_format_t
1039 </row></tbody></tgroup></informaltable>
1042 <informaltable><tgroup cols="2"><tbody><row><entry
1047 <para>File descriptor returned by a previous call to open().</para>
1051 <para>int request</para>
1054 <para>Equals VIDEO_SET_DISPLAY_FORMAT for this
1059 <para>video_display_format_t
1063 <para>Selects the video format to be used.</para>
1065 </row></tbody></tgroup></informaltable>
1068 <informaltable><tgroup cols="2"><tbody><row><entry
1073 <para>fd is not a valid open file descriptor</para>
1077 <para>EINTERNAL</para>
1080 <para>Internal error.</para>
1087 <para>Illegal parameter format.</para>
1089 </row></tbody></tgroup></informaltable>
1092 role="subsection"><title>VIDEO_STILLPICTURE</title>
1095 <informaltable><tgroup cols="1"><tbody><row><entry
1097 <para>This ioctl call asks the Video Device to display a still picture (I-frame). The
1098 input data shall contain an I-frame. If the pointer is NULL, then the current
1099 displayed still picture is blanked.</para>
1101 </row></tbody></tgroup></informaltable>
1104 <informaltable><tgroup cols="1"><tbody><row><entry
1106 <para>int ioctl(fd, int request = VIDEO_STILLPICTURE,
1107 struct video_still_picture ⋆sp);</para>
1109 </row></tbody></tgroup></informaltable>
1112 <informaltable><tgroup cols="2"><tbody><row><entry
1117 <para>File descriptor returned by a previous call to open().</para>
1121 <para>int request</para>
1124 <para>Equals VIDEO_STILLPICTURE for this command.</para>
1133 <para>Pointer to a location where an I-frame and size is stored.</para>
1135 </row></tbody></tgroup></informaltable>
1138 <informaltable><tgroup cols="2"><tbody><row><entry
1143 <para>fd is not a valid open file descriptor</para>
1147 <para>EINTERNAL</para>
1150 <para>Internal error.</para>
1157 <para>sp points to an invalid iframe.</para>
1159 </row></tbody></tgroup></informaltable>
1162 role="subsection"><title>VIDEO_FAST_FORWARD</title>
1165 <informaltable><tgroup cols="1"><tbody><row><entry
1167 <para>This ioctl call asks the Video Device to skip decoding of N number of I-frames.
1168 This call can only be used if VIDEO_SOURCE_MEMORY is selected.</para>
1170 </row></tbody></tgroup></informaltable>
1173 <informaltable><tgroup cols="1"><tbody><row><entry
1175 <para>int ioctl(fd, int request = VIDEO_FAST_FORWARD, int
1178 </row></tbody></tgroup></informaltable>
1181 <informaltable><tgroup cols="2"><tbody><row><entry
1186 <para>File descriptor returned by a previous call to open().</para>
1190 <para>int request</para>
1193 <para>Equals VIDEO_FAST_FORWARD for this command.</para>
1197 <para>int nFrames</para>
1200 <para>The number of frames to skip.</para>
1202 </row></tbody></tgroup></informaltable>
1205 <informaltable><tgroup cols="2"><tbody><row><entry
1210 <para>fd is not a valid open file descriptor</para>
1214 <para>EINTERNAL</para>
1217 <para>Internal error.</para>
1224 <para>Mode VIDEO_SOURCE_MEMORY not selected.</para>
1231 <para>Illegal parameter format.</para>
1233 </row></tbody></tgroup></informaltable>
1236 role="subsection"><title>VIDEO_SLOWMOTION</title>
1239 <informaltable><tgroup cols="1"><tbody><row><entry
1241 <para>This ioctl call asks the video device to repeat decoding frames N number of
1242 times. This call can only be used if VIDEO_SOURCE_MEMORY is selected.</para>
1244 </row></tbody></tgroup></informaltable>
1247 <informaltable><tgroup cols="1"><tbody><row><entry
1249 <para>int ioctl(fd, int request = VIDEO_SLOWMOTION, int
1252 </row></tbody></tgroup></informaltable>
1255 <informaltable><tgroup cols="2"><tbody><row><entry
1260 <para>File descriptor returned by a previous call to open().</para>
1264 <para>int request</para>
1267 <para>Equals VIDEO_SLOWMOTION for this command.</para>
1271 <para>int nFrames</para>
1274 <para>The number of times to repeat each frame.</para>
1276 </row></tbody></tgroup></informaltable>
1279 <informaltable><tgroup cols="2"><tbody><row><entry
1284 <para>fd is not a valid open file descriptor</para>
1288 <para>EINTERNAL</para>
1291 <para>Internal error.</para>
1298 <para>Mode VIDEO_SOURCE_MEMORY not selected.</para>
1305 <para>Illegal parameter format.</para>
1307 </row></tbody></tgroup></informaltable>
1310 role="subsection"><title>VIDEO_GET_CAPABILITIES</title>
1313 <informaltable><tgroup cols="1"><tbody><row><entry
1315 <para>This ioctl call asks the video device about its decoding capabilities. On success
1316 it returns and integer which has bits set according to the defines in section ??.</para>
1318 </row></tbody></tgroup></informaltable>
1321 <informaltable><tgroup cols="1"><tbody><row><entry
1323 <para>int ioctl(fd, int request = VIDEO_GET_CAPABILITIES,
1324 unsigned int ⋆cap);</para>
1326 </row></tbody></tgroup></informaltable>
1329 <informaltable><tgroup cols="2"><tbody><row><entry
1334 <para>File descriptor returned by a previous call to open().</para>
1338 <para>int request</para>
1341 <para>Equals VIDEO_GET_CAPABILITIES for this
1346 <para>unsigned int *cap</para>
1349 <para>Pointer to a location where to store the capability
1352 </row></tbody></tgroup></informaltable>
1355 <informaltable><tgroup cols="2"><tbody><row><entry
1360 <para>fd is not a valid open file descriptor</para>
1367 <para>cap points to an invalid iframe.</para>
1369 </row></tbody></tgroup></informaltable>
1372 role="subsection"><title>VIDEO_SET_ID</title>
1375 <informaltable><tgroup cols="1"><tbody><row><entry
1377 <para>This ioctl selects which sub-stream is to be decoded if a program or system
1378 stream is sent to the video device.</para>
1380 </row></tbody></tgroup></informaltable>
1383 <informaltable><tgroup cols="1"><tbody><row><entry
1385 <para>int ioctl(int fd, int request = VIDEO_SET_ID, int
1388 </row></tbody></tgroup></informaltable>
1391 <informaltable><tgroup cols="2"><tbody><row><entry
1396 <para>File descriptor returned by a previous call to open().</para>
1400 <para>int request</para>
1403 <para>Equals VIDEO_SET_ID for this command.</para>
1410 <para>video sub-stream id</para>
1412 </row></tbody></tgroup></informaltable>
1415 <informaltable><tgroup cols="2"><tbody><row><entry
1420 <para>fd is not a valid open file descriptor.</para>
1424 <para>EINTERNAL</para>
1427 <para>Internal error.</para>
1434 <para>Invalid sub-stream id.</para>
1436 </row></tbody></tgroup></informaltable>
1439 role="subsection"><title>VIDEO_CLEAR_BUFFER</title>
1442 <informaltable><tgroup cols="1"><tbody><row><entry
1444 <para>This ioctl call clears all video buffers in the driver and in the decoder hardware.</para>
1446 </row></tbody></tgroup></informaltable>
1449 <informaltable><tgroup cols="1"><tbody><row><entry
1451 <para>int ioctl(fd, int request = VIDEO_CLEAR_BUFFER);</para>
1453 </row></tbody></tgroup></informaltable>
1456 <informaltable><tgroup cols="2"><tbody><row><entry
1461 <para>File descriptor returned by a previous call to open().</para>
1465 <para>int request</para>
1468 <para>Equals VIDEO_CLEAR_BUFFER for this command.</para>
1470 </row></tbody></tgroup></informaltable>
1473 <informaltable><tgroup cols="2"><tbody><row><entry
1478 <para>fd is not a valid open file descriptor</para>
1480 </row></tbody></tgroup></informaltable>
1483 role="subsection"><title>VIDEO_SET_STREAMTYPE</title>
1486 <informaltable><tgroup cols="1"><tbody><row><entry
1488 <para>This ioctl tells the driver which kind of stream to expect being written to it. If
1489 this call is not used the default of video PES is used. Some drivers might not
1490 support this call and always expect PES.</para>
1492 </row></tbody></tgroup></informaltable>
1495 <informaltable><tgroup cols="1"><tbody><row><entry
1497 <para>int ioctl(fd, int request = VIDEO_SET_STREAMTYPE,
1500 </row></tbody></tgroup></informaltable>
1503 <informaltable><tgroup cols="2"><tbody><row><entry
1508 <para>File descriptor returned by a previous call to open().</para>
1512 <para>int request</para>
1515 <para>Equals VIDEO_SET_STREAMTYPE for this command.</para>
1519 <para>int type</para>
1522 <para>stream type</para>
1524 </row></tbody></tgroup></informaltable>
1527 <informaltable><tgroup cols="2"><tbody><row><entry
1532 <para>fd is not a valid open file descriptor</para>
1539 <para>type is not a valid or supported stream type.</para>
1541 </row></tbody></tgroup></informaltable>
1544 role="subsection"><title>VIDEO_SET_FORMAT</title>
1547 <informaltable><tgroup cols="1"><tbody><row><entry
1549 <para>This ioctl sets the screen format (aspect ratio) of the connected output device
1550 (TV) so that the output of the decoder can be adjusted accordingly.</para>
1552 </row></tbody></tgroup></informaltable>
1555 <informaltable><tgroup cols="1"><tbody><row><entry
1557 <para> int ioctl(fd, int request = VIDEO_SET_FORMAT,
1558 video_format_t format);</para>
1560 </row></tbody></tgroup></informaltable>
1563 <informaltable><tgroup cols="2"><tbody><row><entry
1568 <para>File descriptor returned by a previous call to open().</para>
1572 <para>int request</para>
1575 <para>Equals VIDEO_SET_FORMAT for this command.</para>
1579 <para>video_format_t
1583 <para>video format of TV as defined in section ??.</para>
1585 </row></tbody></tgroup></informaltable>
1588 <informaltable><tgroup cols="2"><tbody><row><entry
1593 <para>fd is not a valid open file descriptor</para>
1600 <para>format is not a valid video format.</para>
1602 </row></tbody></tgroup></informaltable>
1605 role="subsection"><title>VIDEO_SET_SYSTEM</title>
1608 <informaltable><tgroup cols="1"><tbody><row><entry
1610 <para>This ioctl sets the television output format. The format (see section ??) may
1611 vary from the color format of the displayed MPEG stream. If the hardware is
1612 not able to display the requested format the call will return an error.</para>
1614 </row></tbody></tgroup></informaltable>
1617 <informaltable><tgroup cols="1"><tbody><row><entry
1619 <para> int ioctl(fd, int request = VIDEO_SET_SYSTEM ,
1620 video_system_t system);</para>
1622 </row></tbody></tgroup></informaltable>
1625 <informaltable><tgroup cols="2"><tbody><row><entry
1630 <para>File descriptor returned by a previous call to open().</para>
1634 <para>int request</para>
1637 <para>Equals VIDEO_SET_FORMAT for this command.</para>
1641 <para>video_system_t
1645 <para>video system of TV output.</para>
1647 </row></tbody></tgroup></informaltable>
1650 <informaltable><tgroup cols="2"><tbody><row><entry
1655 <para>fd is not a valid open file descriptor</para>
1662 <para>system is not a valid or supported video system.</para>
1664 </row></tbody></tgroup></informaltable>
1667 role="subsection"><title>VIDEO_SET_HIGHLIGHT</title>
1670 <informaltable><tgroup cols="1"><tbody><row><entry
1672 <para>This ioctl sets the SPU highlight information for the menu access of a DVD.</para>
1674 </row></tbody></tgroup></informaltable>
1677 <informaltable><tgroup cols="1"><tbody><row><entry
1679 <para> int ioctl(fd, int request = VIDEO_SET_HIGHLIGHT
1680 ,video_highlight_t ⋆vhilite)</para>
1682 </row></tbody></tgroup></informaltable>
1685 <informaltable><tgroup cols="2"><tbody><row><entry
1690 <para>File descriptor returned by a previous call to open().</para>
1694 <para>int request</para>
1697 <para>Equals VIDEO_SET_HIGHLIGHT for this command.</para>
1701 <para>video_highlight_t
1705 <para>SPU Highlight information according to section ??.</para>
1707 </row></tbody></tgroup></informaltable>
1710 <informaltable><tgroup cols="2"><tbody><row><entry
1715 <para>fd is not a valid open file descriptor.</para>
1722 <para>input is not a valid highlight setting.</para>
1724 </row></tbody></tgroup></informaltable>
1727 role="subsection"><title>VIDEO_SET_SPU</title>
1730 <informaltable><tgroup cols="1"><tbody><row><entry
1732 <para>This ioctl activates or deactivates SPU decoding in a DVD input stream. It can
1733 only be used, if the driver is able to handle a DVD stream.</para>
1735 </row></tbody></tgroup></informaltable>
1738 <informaltable><tgroup cols="1"><tbody><row><entry
1740 <para> int ioctl(fd, int request = VIDEO_SET_SPU ,
1741 video_spu_t ⋆spu)</para>
1743 </row></tbody></tgroup></informaltable>
1746 <informaltable><tgroup cols="2"><tbody><row><entry
1751 <para>File descriptor returned by a previous call to open().</para>
1755 <para>int request</para>
1758 <para>Equals VIDEO_SET_SPU for this command.</para>
1762 <para>video_spu_t *spu</para>
1765 <para>SPU decoding (de)activation and subid setting according
1766 to section ??.</para>
1768 </row></tbody></tgroup></informaltable>
1771 <informaltable><tgroup cols="2"><tbody><row><entry
1776 <para>fd is not a valid open file descriptor</para>
1783 <para>input is not a valid spu setting or driver cannot handle
1786 </row></tbody></tgroup></informaltable>
1789 role="subsection"><title>VIDEO_SET_SPU_PALETTE</title>
1792 <informaltable><tgroup cols="1"><tbody><row><entry
1794 <para>This ioctl sets the SPU color palette.</para>
1796 </row></tbody></tgroup></informaltable>
1799 <informaltable><tgroup cols="1"><tbody><row><entry
1801 <para> int ioctl(fd, int request = VIDEO_SET_SPU_PALETTE
1802 ,video_spu_palette_t ⋆palette )</para>
1804 </row></tbody></tgroup></informaltable>
1807 <informaltable><tgroup cols="2"><tbody><row><entry
1812 <para>File descriptor returned by a previous call to open().</para>
1816 <para>int request</para>
1819 <para>Equals VIDEO_SET_SPU_PALETTE for this command.</para>
1823 <para>video_spu_palette_t
1827 <para>SPU palette according to section ??.</para>
1829 </row></tbody></tgroup></informaltable>
1832 <informaltable><tgroup cols="2"><tbody><row><entry
1837 <para>fd is not a valid open file descriptor</para>
1844 <para>input is not a valid palette or driver doesn’t handle SPU.</para>
1846 </row></tbody></tgroup></informaltable>
1849 role="subsection"><title>VIDEO_GET_NAVI</title>
1852 <informaltable><tgroup cols="1"><tbody><row><entry
1854 <para>This ioctl returns navigational information from the DVD stream. This is
1855 especially needed if an encoded stream has to be decoded by the hardware.</para>
1857 </row></tbody></tgroup></informaltable>
1860 <informaltable><tgroup cols="1"><tbody><row><entry
1862 <para> int ioctl(fd, int request = VIDEO_GET_NAVI ,
1863 video_navi_pack_t ⋆navipack)</para>
1865 </row></tbody></tgroup></informaltable>
1868 <informaltable><tgroup cols="2"><tbody><row><entry
1873 <para>File descriptor returned by a previous call to open().</para>
1877 <para>int request</para>
1880 <para>Equals VIDEO_GET_NAVI for this command.</para>
1884 <para>video_navi_pack_t
1888 <para>PCI or DSI pack (private stream 2) according to section
1891 </row></tbody></tgroup></informaltable>
1894 <informaltable><tgroup cols="2"><tbody><row><entry
1899 <para>fd is not a valid open file descriptor</para>
1906 <para>driver is not able to return navigational information</para>
1908 </row></tbody></tgroup></informaltable>
1911 role="subsection"><title>VIDEO_SET_ATTRIBUTES</title>
1914 <informaltable><tgroup cols="1"><tbody><row><entry
1916 <para>This ioctl is intended for DVD playback and allows you to set certain
1917 information about the stream. Some hardware may not need this information,
1918 but the call also tells the hardware to prepare for DVD playback.</para>
1920 </row></tbody></tgroup></informaltable>
1923 <informaltable><tgroup cols="1"><tbody><row><entry
1925 <para> int ioctl(fd, int request = VIDEO_SET_ATTRIBUTE
1926 ,video_attributes_t vattr)</para>
1928 </row></tbody></tgroup></informaltable>
1931 <informaltable><tgroup cols="2"><tbody><row><entry
1936 <para>File descriptor returned by a previous call to open().</para>
1940 <para>int request</para>
1943 <para>Equals VIDEO_SET_ATTRIBUTE for this command.</para>
1947 <para>video_attributes_t
1951 <para>video attributes according to section ??.</para>
1953 </row></tbody></tgroup></informaltable>
1956 <informaltable><tgroup cols="2"><tbody><row><entry
1961 <para>fd is not a valid open file descriptor</para>
1968 <para>input is not a valid attribute setting.</para>
1970 </row></tbody></tgroup></informaltable>
1971 </section></section>