1951a39d68df598db08dfced8b4707755864a0492Ying Wang/**************************************************************************** 2 **************************************************************************** 3 *** 4 *** This header was automatically generated from a Linux kernel header 5 *** of the same name, to make information necessary for userspace to 6 *** call into the kernel available to libc. It contains only constants, 7 *** structures, and macros generated from the original header, and thus, 8 *** contains no copyrightable information. 9 *** 10 **************************************************************************** 11 ****************************************************************************/ 12#ifndef __LINUX_VIDEODEV_H 13#define __LINUX_VIDEODEV_H 14 15#include <linux/videodev2.h> 16 17struct video_capability 18{ 19 char name[32]; 20 int type; 21 int channels; 22 int audios; 23 int maxwidth; 24 int maxheight; 25 int minwidth; 26 int minheight; 27}; 28 29struct video_channel 30{ 31 int channel; 32 char name[32]; 33 int tuners; 34 __u32 flags; 35#define VIDEO_VC_TUNER 1 36#define VIDEO_VC_AUDIO 2 37 __u16 type; 38#define VIDEO_TYPE_TV 1 39#define VIDEO_TYPE_CAMERA 2 40 __u16 norm; 41}; 42 43struct video_tuner 44{ 45 int tuner; 46 char name[32]; 47 unsigned long rangelow, rangehigh; 48 __u32 flags; 49#define VIDEO_TUNER_PAL 1 50#define VIDEO_TUNER_NTSC 2 51#define VIDEO_TUNER_SECAM 4 52#define VIDEO_TUNER_LOW 8 53#define VIDEO_TUNER_NORM 16 54#define VIDEO_TUNER_STEREO_ON 128 55#define VIDEO_TUNER_RDS_ON 256 56#define VIDEO_TUNER_MBS_ON 512 57 __u16 mode; 58#define VIDEO_MODE_PAL 0 59#define VIDEO_MODE_NTSC 1 60#define VIDEO_MODE_SECAM 2 61#define VIDEO_MODE_AUTO 3 62 __u16 signal; 63}; 64 65struct video_picture 66{ 67 __u16 brightness; 68 __u16 hue; 69 __u16 colour; 70 __u16 contrast; 71 __u16 whiteness; 72 __u16 depth; 73 __u16 palette; 74#define VIDEO_PALETTE_GREY 1 75#define VIDEO_PALETTE_HI240 2 76#define VIDEO_PALETTE_RGB565 3 77#define VIDEO_PALETTE_RGB24 4 78#define VIDEO_PALETTE_RGB32 5 79#define VIDEO_PALETTE_RGB555 6 80#define VIDEO_PALETTE_YUV422 7 81#define VIDEO_PALETTE_YUYV 8 82#define VIDEO_PALETTE_UYVY 9 83#define VIDEO_PALETTE_YUV420 10 84#define VIDEO_PALETTE_YUV411 11 85#define VIDEO_PALETTE_RAW 12 86#define VIDEO_PALETTE_YUV422P 13 87#define VIDEO_PALETTE_YUV411P 14 88#define VIDEO_PALETTE_YUV420P 15 89#define VIDEO_PALETTE_YUV410P 16 90#define VIDEO_PALETTE_PLANAR 13 91#define VIDEO_PALETTE_COMPONENT 7 92}; 93 94struct video_audio 95{ 96 int audio; 97 __u16 volume; 98 __u16 bass, treble; 99 __u32 flags; 100#define VIDEO_AUDIO_MUTE 1 101#define VIDEO_AUDIO_MUTABLE 2 102#define VIDEO_AUDIO_VOLUME 4 103#define VIDEO_AUDIO_BASS 8 104#define VIDEO_AUDIO_TREBLE 16 105#define VIDEO_AUDIO_BALANCE 32 106 char name[16]; 107#define VIDEO_SOUND_MONO 1 108#define VIDEO_SOUND_STEREO 2 109#define VIDEO_SOUND_LANG1 4 110#define VIDEO_SOUND_LANG2 8 111 __u16 mode; 112 __u16 balance; 113 __u16 step; 114}; 115 116struct video_clip 117{ 118 __s32 x,y; 119 __s32 width, height; 120 struct video_clip *next; 121}; 122 123struct video_window 124{ 125 __u32 x,y; 126 __u32 width,height; 127 __u32 chromakey; 128 __u32 flags; 129 struct video_clip __user *clips; 130 int clipcount; 131#define VIDEO_WINDOW_INTERLACE 1 132#define VIDEO_WINDOW_CHROMAKEY 16 133#define VIDEO_CLIP_BITMAP -1 134 135#define VIDEO_CLIPMAP_SIZE (128 * 625) 136}; 137 138struct video_capture 139{ 140 __u32 x,y; 141 __u32 width, height; 142 __u16 decimation; 143 __u16 flags; 144#define VIDEO_CAPTURE_ODD 0 145#define VIDEO_CAPTURE_EVEN 1 146}; 147 148struct video_buffer 149{ 150 void *base; 151 int height,width; 152 int depth; 153 int bytesperline; 154}; 155 156struct video_mmap 157{ 158 unsigned int frame; 159 int height,width; 160 unsigned int format; 161}; 162 163struct video_key 164{ 165 __u8 key[8]; 166 __u32 flags; 167}; 168 169struct video_mbuf 170{ 171 int size; 172 int frames; 173 int offsets[VIDEO_MAX_FRAME]; 174}; 175 176#define VIDEO_NO_UNIT (-1) 177 178struct video_unit 179{ 180 int video; 181 int vbi; 182 int radio; 183 int audio; 184 int teletext; 185}; 186 187struct vbi_format { 188 __u32 sampling_rate; 189 __u32 samples_per_line; 190 __u32 sample_format; 191 __s32 start[2]; 192 __u32 count[2]; 193 __u32 flags; 194#define VBI_UNSYNC 1 195#define VBI_INTERLACED 2 196}; 197 198struct video_info 199{ 200 __u32 frame_count; 201 __u32 h_size; 202 __u32 v_size; 203 __u32 smpte_timecode; 204 __u32 picture_type; 205 __u32 temporal_reference; 206 __u8 user_data[256]; 207 208}; 209 210struct video_play_mode 211{ 212 int mode; 213 int p1; 214 int p2; 215}; 216 217struct video_code 218{ 219 char loadwhat[16]; 220 int datasize; 221 __u8 *data; 222}; 223 224#define VIDIOCGCAP _IOR('v',1,struct video_capability) 225#define VIDIOCGCHAN _IOWR('v',2,struct video_channel) 226#define VIDIOCSCHAN _IOW('v',3,struct video_channel) 227#define VIDIOCGTUNER _IOWR('v',4,struct video_tuner) 228#define VIDIOCSTUNER _IOW('v',5,struct video_tuner) 229#define VIDIOCGPICT _IOR('v',6,struct video_picture) 230#define VIDIOCSPICT _IOW('v',7,struct video_picture) 231#define VIDIOCCAPTURE _IOW('v',8,int) 232#define VIDIOCGWIN _IOR('v',9, struct video_window) 233#define VIDIOCSWIN _IOW('v',10, struct video_window) 234#define VIDIOCGFBUF _IOR('v',11, struct video_buffer) 235#define VIDIOCSFBUF _IOW('v',12, struct video_buffer) 236#define VIDIOCKEY _IOR('v',13, struct video_key) 237#define VIDIOCGFREQ _IOR('v',14, unsigned long) 238#define VIDIOCSFREQ _IOW('v',15, unsigned long) 239#define VIDIOCGAUDIO _IOR('v',16, struct video_audio) 240#define VIDIOCSAUDIO _IOW('v',17, struct video_audio) 241#define VIDIOCSYNC _IOW('v',18, int) 242#define VIDIOCMCAPTURE _IOW('v',19, struct video_mmap) 243#define VIDIOCGMBUF _IOR('v',20, struct video_mbuf) 244#define VIDIOCGUNIT _IOR('v',21, struct video_unit) 245#define VIDIOCGCAPTURE _IOR('v',22, struct video_capture) 246#define VIDIOCSCAPTURE _IOW('v',23, struct video_capture) 247#define VIDIOCSPLAYMODE _IOW('v',24, struct video_play_mode) 248#define VIDIOCSWRITEMODE _IOW('v',25, int) 249#define VIDIOCGPLAYINFO _IOR('v',26, struct video_info) 250#define VIDIOCSMICROCODE _IOW('v',27, struct video_code) 251#define VIDIOCGVBIFMT _IOR('v',28, struct vbi_format) 252#define VIDIOCSVBIFMT _IOW('v',29, struct vbi_format) 253 254#define BASE_VIDIOCPRIVATE 192 255 256#define VID_WRITE_MPEG_AUD 0 257#define VID_WRITE_MPEG_VID 1 258#define VID_WRITE_OSD 2 259#define VID_WRITE_TTX 3 260#define VID_WRITE_CC 4 261#define VID_WRITE_MJPEG 5 262 263#define VID_PLAY_VID_OUT_MODE 0 264 265#define VID_PLAY_GENLOCK 1 266 267#define VID_PLAY_NORMAL 2 268#define VID_PLAY_PAUSE 3 269#define VID_PLAY_SINGLE_FRAME 4 270#define VID_PLAY_FAST_FORWARD 5 271#define VID_PLAY_SLOW_MOTION 6 272#define VID_PLAY_IMMEDIATE_NORMAL 7 273#define VID_PLAY_SWITCH_CHANNELS 8 274#define VID_PLAY_FREEZE_FRAME 9 275#define VID_PLAY_STILL_MODE 10 276#define VID_PLAY_MASTER_MODE 11 277 278#define VID_PLAY_MASTER_NONE 1 279#define VID_PLAY_MASTER_VIDEO 2 280#define VID_PLAY_MASTER_AUDIO 3 281#define VID_PLAY_ACTIVE_SCANLINES 12 282 283#define VID_PLAY_RESET 13 284#define VID_PLAY_END_MARK 14 285 286#define VID_HARDWARE_BT848 1 287#define VID_HARDWARE_QCAM_BW 2 288#define VID_HARDWARE_PMS 3 289#define VID_HARDWARE_QCAM_C 4 290#define VID_HARDWARE_PSEUDO 5 291#define VID_HARDWARE_SAA5249 6 292#define VID_HARDWARE_AZTECH 7 293#define VID_HARDWARE_SF16MI 8 294#define VID_HARDWARE_RTRACK 9 295#define VID_HARDWARE_ZOLTRIX 10 296#define VID_HARDWARE_SAA7146 11 297#define VID_HARDWARE_VIDEUM 12 298#define VID_HARDWARE_RTRACK2 13 299#define VID_HARDWARE_PERMEDIA2 14 300#define VID_HARDWARE_RIVA128 15 301#define VID_HARDWARE_PLANB 16 302#define VID_HARDWARE_BROADWAY 17 303#define VID_HARDWARE_GEMTEK 18 304#define VID_HARDWARE_TYPHOON 19 305#define VID_HARDWARE_VINO 20 306#define VID_HARDWARE_CADET 21 307#define VID_HARDWARE_TRUST 22 308#define VID_HARDWARE_TERRATEC 23 309#define VID_HARDWARE_CPIA 24 310#define VID_HARDWARE_ZR36120 25 311#define VID_HARDWARE_ZR36067 26 312#define VID_HARDWARE_OV511 27 313#define VID_HARDWARE_ZR356700 28 314#define VID_HARDWARE_W9966 29 315#define VID_HARDWARE_SE401 30 316#define VID_HARDWARE_PWC 31 317#define VID_HARDWARE_MEYE 32 318#define VID_HARDWARE_CPIA2 33 319#define VID_HARDWARE_VICAM 34 320#define VID_HARDWARE_SF16FMR2 35 321#define VID_HARDWARE_W9968CF 36 322#define VID_HARDWARE_SAA7114H 37 323#define VID_HARDWARE_SN9C102 38 324#define VID_HARDWARE_ARV 39 325 326#endif 327 328