18c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
28c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  Video for Linux Two header file
38c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
48c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  Copyright (C) 1999-2007 the contributors
58c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
68c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  This program is free software; you can redistribute it and/or modify
78c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  it under the terms of the GNU General Public License as published by
88c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  the Free Software Foundation; either version 2 of the License, or
98c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  (at your option) any later version.
108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  This program is distributed in the hope that it will be useful,
128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  but WITHOUT ANY WARRANTY; without even the implied warranty of
138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  GNU General Public License for more details.
158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  Alternatively you can redistribute this file under the terms of the
178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  BSD license as stated below:
188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  Redistribution and use in source and binary forms, with or without
208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  modification, are permitted provided that the following conditions
218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  are met:
228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  1. Redistributions of source code must retain the above copyright
238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *     notice, this list of conditions and the following disclaimer.
248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  2. Redistributions in binary form must reproduce the above copyright
258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *     notice, this list of conditions and the following disclaimer in
268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *     the documentation and/or other materials provided with the
278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *     distribution.
288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  3. The names of its contributors may not be used to endorse or promote
298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *     products derived from this software without specific prior written
308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *     permission.
318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *  SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	Header file for v4l or V4L2 drivers and applications
458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * with public API.
468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * All kernel-specific stuff were moved to media/v4l2-dev.h, so
478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * no #if __KERNEL tests are allowed here
488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	See http://linuxtv.org for more info
508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	Author: Bill Dirks <bill@thedirks.org>
528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *		Justin Schoeman
538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *              Hans Verkuil <hverkuil@xs4all.nl>
548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *		et al.
558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#ifndef __LINUX_VIDEODEV2_H
578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define __LINUX_VIDEODEV2_H
588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#ifdef __KERNEL__
608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#include <linux/time.h>     /* need struct timeval */
618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#else
628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#include <sys/time.h>
638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#endif
648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#include <linux/compiler.h>
658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#include <linux/ioctl.h>
668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#include <linux/types.h>
678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * Common stuff for both V4L1 and V4L2
708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * Moved from videodev.h
718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDEO_MAX_FRAME               32
738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDEO_MAX_PLANES               8
748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#ifndef __KERNEL__
768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* These defines are V4L1 specific and should not be used with the V4L2 API!
788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris   They will be removed from this header in the future. */
798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VID_TYPE_CAPTURE	1	/* Can capture */
818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VID_TYPE_TUNER		2	/* Can tune */
828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VID_TYPE_TELETEXT	4	/* Does teletext */
838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VID_TYPE_OVERLAY	8	/* Overlay onto frame buffer */
848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VID_TYPE_CHROMAKEY	16	/* Overlay by chromakey */
858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VID_TYPE_CLIPPING	32	/* Can clip */
868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VID_TYPE_FRAMERAM	64	/* Uses the frame buffer memory */
878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VID_TYPE_SCALES		128	/* Scalable */
888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VID_TYPE_MONOCHROME	256	/* Monochrome only */
898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VID_TYPE_SUBCAPTURE	512	/* Can capture subareas of the image */
908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VID_TYPE_MPEG_DECODER	1024	/* Can decode MPEG streams */
918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VID_TYPE_MPEG_ENCODER	2048	/* Can encode MPEG streams */
928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VID_TYPE_MJPEG_DECODER	4096	/* Can decode MJPEG streams */
938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VID_TYPE_MJPEG_ENCODER	8192	/* Can encode MJPEG streams */
948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#endif
958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	M I S C E L L A N E O U S
988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
1008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Four-character-code (FOURCC) */
1018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define v4l2_fourcc(a, b, c, d)\
1028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	((__u32)(a) | ((__u32)(b) << 8) | ((__u32)(c) << 16) | ((__u32)(d) << 24))
1038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
1048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
1058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	E N U M S
1068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
1078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_field {
1088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FIELD_ANY           = 0, /* driver can choose from none,
1098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris					 top, bottom, interlaced
1108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris					 depending on whatever it thinks
1118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris					 is approximate ... */
1128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FIELD_NONE          = 1, /* this device has no fields ... */
1138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FIELD_TOP           = 2, /* top field only */
1148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FIELD_BOTTOM        = 3, /* bottom field only */
1158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FIELD_INTERLACED    = 4, /* both fields interlaced */
1168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FIELD_SEQ_TB        = 5, /* both fields sequential into one
1178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris					 buffer, top-bottom order */
1188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FIELD_SEQ_BT        = 6, /* same as above + bottom-top order */
1198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FIELD_ALTERNATE     = 7, /* both fields alternating into
1208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris					 separate buffers */
1218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FIELD_INTERLACED_TB = 8, /* both fields interlaced, top field
1228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris					 first and the top field is
1238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris					 transmitted first */
1248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FIELD_INTERLACED_BT = 9, /* both fields interlaced, top field
1258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris					 first and the bottom field is
1268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris					 transmitted first */
1278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
1288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FIELD_HAS_TOP(field)	\
1298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	((field) == V4L2_FIELD_TOP 	||\
1308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 (field) == V4L2_FIELD_INTERLACED ||\
1318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 (field) == V4L2_FIELD_INTERLACED_TB ||\
1328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 (field) == V4L2_FIELD_INTERLACED_BT ||\
1338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 (field) == V4L2_FIELD_SEQ_TB	||\
1348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 (field) == V4L2_FIELD_SEQ_BT)
1358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FIELD_HAS_BOTTOM(field)	\
1368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	((field) == V4L2_FIELD_BOTTOM 	||\
1378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 (field) == V4L2_FIELD_INTERLACED ||\
1388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 (field) == V4L2_FIELD_INTERLACED_TB ||\
1398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 (field) == V4L2_FIELD_INTERLACED_BT ||\
1408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 (field) == V4L2_FIELD_SEQ_TB	||\
1418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 (field) == V4L2_FIELD_SEQ_BT)
1428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FIELD_HAS_BOTH(field)	\
1438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	((field) == V4L2_FIELD_INTERLACED ||\
1448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 (field) == V4L2_FIELD_INTERLACED_TB ||\
1458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 (field) == V4L2_FIELD_INTERLACED_BT ||\
1468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 (field) == V4L2_FIELD_SEQ_TB ||\
1478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 (field) == V4L2_FIELD_SEQ_BT)
1488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
1498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_buf_type {
1508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_BUF_TYPE_VIDEO_CAPTURE        = 1,
1518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_BUF_TYPE_VIDEO_OUTPUT         = 2,
1528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_BUF_TYPE_VIDEO_OVERLAY        = 3,
1538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_BUF_TYPE_VBI_CAPTURE          = 4,
1548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_BUF_TYPE_VBI_OUTPUT           = 5,
1558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_BUF_TYPE_SLICED_VBI_CAPTURE   = 6,
1568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_BUF_TYPE_SLICED_VBI_OUTPUT    = 7,
1578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#if 1
1588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	/* Experimental */
1598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY = 8,
1608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#endif
1618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE = 9,
1628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE  = 10,
1638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_BUF_TYPE_PRIVATE              = 0x80,
1648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
1658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
1668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TYPE_IS_MULTIPLANAR(type)			\
1678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	((type) == V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE	\
1688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 || (type) == V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE)
1698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
1708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TYPE_IS_OUTPUT(type)				\
1718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	((type) == V4L2_BUF_TYPE_VIDEO_OUTPUT			\
1728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 || (type) == V4L2_BUF_TYPE_VIDEO_OUTPUT_MPLANE		\
1738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 || (type) == V4L2_BUF_TYPE_VIDEO_OVERLAY		\
1748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 || (type) == V4L2_BUF_TYPE_VIDEO_OUTPUT_OVERLAY	\
1758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 || (type) == V4L2_BUF_TYPE_VBI_OUTPUT			\
1768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 || (type) == V4L2_BUF_TYPE_SLICED_VBI_OUTPUT)
1778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
1788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_tuner_type {
1798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_TUNER_RADIO	     = 1,
1808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_TUNER_ANALOG_TV	     = 2,
1818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_TUNER_DIGITAL_TV	     = 3,
1828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
1838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
1848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_memory {
1858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MEMORY_MMAP             = 1,
1868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MEMORY_USERPTR          = 2,
1878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MEMORY_OVERLAY          = 3,
1888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
1898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
1908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* see also http://vektor.theorem.ca/graphics/ycbcr/ */
1918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_colorspace {
1928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	/* ITU-R 601 -- broadcast NTSC/PAL */
1938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORSPACE_SMPTE170M     = 1,
1948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
1958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	/* 1125-Line (US) HDTV */
1968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORSPACE_SMPTE240M     = 2,
1978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
1988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	/* HD and modern captures. */
1998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORSPACE_REC709        = 3,
2008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
2018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	/* broken BT878 extents (601, luma range 16-253 instead of 16-235) */
2028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORSPACE_BT878         = 4,
2038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
2048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	/* These should be useful.  Assume 601 extents. */
2058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORSPACE_470_SYSTEM_M  = 5,
2068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORSPACE_470_SYSTEM_BG = 6,
2078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
2088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	/* I know there will be cameras that send this.  So, this is
2098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 * unspecified chromaticities and full 0-255 on each of the
2108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 * Y'CbCr components
2118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 */
2128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORSPACE_JPEG          = 7,
2138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
2148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	/* For RGB colourspaces, this is probably a good start. */
2158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORSPACE_SRGB          = 8,
2168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
2178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
2188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_priority {
2198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_PRIORITY_UNSET       = 0,  /* not initialized */
2208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_PRIORITY_BACKGROUND  = 1,
2218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_PRIORITY_INTERACTIVE = 2,
2228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_PRIORITY_RECORD      = 3,
2238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_PRIORITY_DEFAULT     = V4L2_PRIORITY_INTERACTIVE,
2248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
2258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
2268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_rect {
2278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__s32   left;
2288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__s32   top;
2298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__s32   width;
2308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__s32   height;
2318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
2328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
2338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_fract {
2348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32   numerator;
2358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32   denominator;
2368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
2378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
2388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/**
2398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris  * struct v4l2_capability - Describes V4L2 device caps returned by VIDIOC_QUERYCAP
2408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris  *
2418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris  * @driver:	   name of the driver module (e.g. "bttv")
2428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris  * @card:	   name of the card (e.g. "Hauppauge WinTV")
2438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris  * @bus_info:	   name of the bus (e.g. "PCI:" + pci_name(pci_dev) )
2448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris  * @version:	   KERNEL_VERSION
2458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris  * @capabilities: capabilities of the physical device as a whole
2468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris  * @device_caps:  capabilities accessed via this particular device (node)
2478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris  * @reserved:	   reserved fields for future extensions
2488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris  */
2498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_capability {
2508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8	driver[16];
2518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8	card[32];
2528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8	bus_info[32];
2538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32   version;
2548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	capabilities;
2558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	device_caps;
2568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	reserved[3];
2578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
2588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
2598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Values for 'capabilities' field */
2608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_VIDEO_CAPTURE		0x00000001  /* Is a video capture device */
2618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_VIDEO_OUTPUT		0x00000002  /* Is a video output device */
2628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_VIDEO_OVERLAY		0x00000004  /* Can do video overlay */
2638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_VBI_CAPTURE		0x00000010  /* Is a raw VBI capture device */
2648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_VBI_OUTPUT		0x00000020  /* Is a raw VBI output device */
2658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_SLICED_VBI_CAPTURE	0x00000040  /* Is a sliced VBI capture device */
2668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_SLICED_VBI_OUTPUT	0x00000080  /* Is a sliced VBI output device */
2678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_RDS_CAPTURE		0x00000100  /* RDS data capture */
2688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_VIDEO_OUTPUT_OVERLAY	0x00000200  /* Can do video output overlay */
2698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_HW_FREQ_SEEK		0x00000400  /* Can do hardware frequency seek  */
2708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_RDS_OUTPUT		0x00000800  /* Is an RDS encoder */
2718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
2728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Is a video capture device that supports multiplanar formats */
2738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_VIDEO_CAPTURE_MPLANE	0x00001000
2748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Is a video output device that supports multiplanar formats */
2758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_VIDEO_OUTPUT_MPLANE	0x00002000
2768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
2778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_TUNER			0x00010000  /* has a tuner */
2788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_AUDIO			0x00020000  /* has audio support */
2798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_RADIO			0x00040000  /* is a radio device */
2808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_MODULATOR		0x00080000  /* has a modulator */
2818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
2828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_READWRITE              0x01000000  /* read/write systemcalls */
2838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_ASYNCIO                0x02000000  /* async I/O */
2848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_STREAMING              0x04000000  /* streaming I/O ioctls */
2858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
2868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_DEVICE_CAPS            0x80000000  /* sets device capabilities field */
2878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
2888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
2898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	V I D E O   I M A G E   F O R M A T
2908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
2918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_pix_format {
2928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32         		width;
2938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			height;
2948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			pixelformat;
2958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_field  	field;
2968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32            	bytesperline;	/* for padding, zero if unused */
2978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32          		sizeimage;
2988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_colorspace	colorspace;
2998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			priv;		/* private data, depends on pixelformat */
3008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
3018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
3028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*      Pixel format         FOURCC                          depth  Description  */
3038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
3048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* RGB formats */
3058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_RGB332  v4l2_fourcc('R', 'G', 'B', '1') /*  8  RGB-3-3-2     */
3068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_RGB444  v4l2_fourcc('R', '4', '4', '4') /* 16  xxxxrrrr ggggbbbb */
3078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_RGB555  v4l2_fourcc('R', 'G', 'B', 'O') /* 16  RGB-5-5-5     */
3088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_RGB565  v4l2_fourcc('R', 'G', 'B', 'P') /* 16  RGB-5-6-5     */
3098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_RGB555X v4l2_fourcc('R', 'G', 'B', 'Q') /* 16  RGB-5-5-5 BE  */
3108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_RGB565X v4l2_fourcc('R', 'G', 'B', 'R') /* 16  RGB-5-6-5 BE  */
3118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_BGR666  v4l2_fourcc('B', 'G', 'R', 'H') /* 18  BGR-6-6-6	  */
3128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_BGR24   v4l2_fourcc('B', 'G', 'R', '3') /* 24  BGR-8-8-8     */
3138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_RGB24   v4l2_fourcc('R', 'G', 'B', '3') /* 24  RGB-8-8-8     */
3148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_BGR32   v4l2_fourcc('B', 'G', 'R', '4') /* 32  BGR-8-8-8-8   */
3158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_RGB32   v4l2_fourcc('R', 'G', 'B', '4') /* 32  RGB-8-8-8-8   */
3168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
3178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Grey formats */
3188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_GREY    v4l2_fourcc('G', 'R', 'E', 'Y') /*  8  Greyscale     */
3198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_Y4      v4l2_fourcc('Y', '0', '4', ' ') /*  4  Greyscale     */
3208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_Y6      v4l2_fourcc('Y', '0', '6', ' ') /*  6  Greyscale     */
3218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_Y10     v4l2_fourcc('Y', '1', '0', ' ') /* 10  Greyscale     */
3228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_Y12     v4l2_fourcc('Y', '1', '2', ' ') /* 12  Greyscale     */
3238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_Y16     v4l2_fourcc('Y', '1', '6', ' ') /* 16  Greyscale     */
3248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
3258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Grey bit-packed formats */
3268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_Y10BPACK    v4l2_fourcc('Y', '1', '0', 'B') /* 10  Greyscale bit-packed */
3278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
3288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Palette formats */
3298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_PAL8    v4l2_fourcc('P', 'A', 'L', '8') /*  8  8-bit palette */
3308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
3318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Luminance+Chrominance formats */
3328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_YVU410  v4l2_fourcc('Y', 'V', 'U', '9') /*  9  YVU 4:1:0     */
3338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_YVU420  v4l2_fourcc('Y', 'V', '1', '2') /* 12  YVU 4:2:0     */
3348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_YUYV    v4l2_fourcc('Y', 'U', 'Y', 'V') /* 16  YUV 4:2:2     */
3358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_YYUV    v4l2_fourcc('Y', 'Y', 'U', 'V') /* 16  YUV 4:2:2     */
3368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_YVYU    v4l2_fourcc('Y', 'V', 'Y', 'U') /* 16 YVU 4:2:2 */
3378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_UYVY    v4l2_fourcc('U', 'Y', 'V', 'Y') /* 16  YUV 4:2:2     */
3388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_VYUY    v4l2_fourcc('V', 'Y', 'U', 'Y') /* 16  YUV 4:2:2     */
3398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_YUV422P v4l2_fourcc('4', '2', '2', 'P') /* 16  YVU422 planar */
3408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_YUV411P v4l2_fourcc('4', '1', '1', 'P') /* 16  YVU411 planar */
3418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_Y41P    v4l2_fourcc('Y', '4', '1', 'P') /* 12  YUV 4:1:1     */
3428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_YUV444  v4l2_fourcc('Y', '4', '4', '4') /* 16  xxxxyyyy uuuuvvvv */
3438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_YUV555  v4l2_fourcc('Y', 'U', 'V', 'O') /* 16  YUV-5-5-5     */
3448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_YUV565  v4l2_fourcc('Y', 'U', 'V', 'P') /* 16  YUV-5-6-5     */
3458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_YUV32   v4l2_fourcc('Y', 'U', 'V', '4') /* 32  YUV-8-8-8-8   */
3468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_YUV410  v4l2_fourcc('Y', 'U', 'V', '9') /*  9  YUV 4:1:0     */
3478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_YUV420  v4l2_fourcc('Y', 'U', '1', '2') /* 12  YUV 4:2:0     */
3488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_HI240   v4l2_fourcc('H', 'I', '2', '4') /*  8  8-bit color   */
3498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_HM12    v4l2_fourcc('H', 'M', '1', '2') /*  8  YUV 4:2:0 16x16 macroblocks */
3508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_M420    v4l2_fourcc('M', '4', '2', '0') /* 12  YUV 4:2:0 2 lines y, 1 line uv interleaved */
3518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
3528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* two planes -- one Y, one Cr + Cb interleaved  */
3538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_NV12    v4l2_fourcc('N', 'V', '1', '2') /* 12  Y/CbCr 4:2:0  */
3548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_NV21    v4l2_fourcc('N', 'V', '2', '1') /* 12  Y/CrCb 4:2:0  */
3558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_NV16    v4l2_fourcc('N', 'V', '1', '6') /* 16  Y/CbCr 4:2:2  */
3568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_NV61    v4l2_fourcc('N', 'V', '6', '1') /* 16  Y/CrCb 4:2:2  */
3578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_NV24    v4l2_fourcc('N', 'V', '2', '4') /* 24  Y/CbCr 4:4:4  */
3588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_NV42    v4l2_fourcc('N', 'V', '4', '2') /* 24  Y/CrCb 4:4:4  */
3598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
3608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* two non contiguous planes - one Y, one Cr + Cb interleaved  */
3618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_NV12M   v4l2_fourcc('N', 'M', '1', '2') /* 12  Y/CbCr 4:2:0  */
3628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_NV12MT  v4l2_fourcc('T', 'M', '1', '2') /* 12  Y/CbCr 4:2:0 64x32 macroblocks */
3638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
3648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* three non contiguous planes - Y, Cb, Cr */
3658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_YUV420M v4l2_fourcc('Y', 'M', '1', '2') /* 12  YUV420 planar */
3668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
3678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Bayer formats - see http://www.siliconimaging.com/RGB%20Bayer.htm */
3688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SBGGR8  v4l2_fourcc('B', 'A', '8', '1') /*  8  BGBG.. GRGR.. */
3698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SGBRG8  v4l2_fourcc('G', 'B', 'R', 'G') /*  8  GBGB.. RGRG.. */
3708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SGRBG8  v4l2_fourcc('G', 'R', 'B', 'G') /*  8  GRGR.. BGBG.. */
3718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SRGGB8  v4l2_fourcc('R', 'G', 'G', 'B') /*  8  RGRG.. GBGB.. */
3728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SBGGR10 v4l2_fourcc('B', 'G', '1', '0') /* 10  BGBG.. GRGR.. */
3738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SGBRG10 v4l2_fourcc('G', 'B', '1', '0') /* 10  GBGB.. RGRG.. */
3748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SGRBG10 v4l2_fourcc('B', 'A', '1', '0') /* 10  GRGR.. BGBG.. */
3758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SRGGB10 v4l2_fourcc('R', 'G', '1', '0') /* 10  RGRG.. GBGB.. */
3768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SBGGR12 v4l2_fourcc('B', 'G', '1', '2') /* 12  BGBG.. GRGR.. */
3778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SGBRG12 v4l2_fourcc('G', 'B', '1', '2') /* 12  GBGB.. RGRG.. */
3788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SGRBG12 v4l2_fourcc('B', 'A', '1', '2') /* 12  GRGR.. BGBG.. */
3798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SRGGB12 v4l2_fourcc('R', 'G', '1', '2') /* 12  RGRG.. GBGB.. */
3808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	/* 10bit raw bayer DPCM compressed to 8 bits */
3818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SGRBG10DPCM8 v4l2_fourcc('B', 'D', '1', '0')
3828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	/*
3838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 * 10bit raw bayer, expanded to 16 bits
3848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 * xxxxrrrrrrrrrrxxxxgggggggggg xxxxggggggggggxxxxbbbbbbbbbb...
3858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	 */
3868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SBGGR16 v4l2_fourcc('B', 'Y', 'R', '2') /* 16  BGBG.. GRGR.. */
3878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
3888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* compressed formats */
3898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_MJPEG    v4l2_fourcc('M', 'J', 'P', 'G') /* Motion-JPEG   */
3908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_JPEG     v4l2_fourcc('J', 'P', 'E', 'G') /* JFIF JPEG     */
3918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_DV       v4l2_fourcc('d', 'v', 's', 'd') /* 1394          */
3928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_MPEG     v4l2_fourcc('M', 'P', 'E', 'G') /* MPEG-1/2/4 Multiplexed */
3938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_H264     v4l2_fourcc('H', '2', '6', '4') /* H264 with start codes */
3948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_H264_NO_SC v4l2_fourcc('A', 'V', 'C', '1') /* H264 without start codes */
3958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_H263     v4l2_fourcc('H', '2', '6', '3') /* H263          */
3968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_MPEG1    v4l2_fourcc('M', 'P', 'G', '1') /* MPEG-1 ES     */
3978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_MPEG2    v4l2_fourcc('M', 'P', 'G', '2') /* MPEG-2 ES     */
3988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_MPEG4    v4l2_fourcc('M', 'P', 'G', '4') /* MPEG-4 ES     */
3998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_XVID     v4l2_fourcc('X', 'V', 'I', 'D') /* Xvid           */
4008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_VC1_ANNEX_G v4l2_fourcc('V', 'C', '1', 'G') /* SMPTE 421M Annex G compliant stream */
4018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_VC1_ANNEX_L v4l2_fourcc('V', 'C', '1', 'L') /* SMPTE 421M Annex L compliant stream */
4028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_DIVX_311  v4l2_fourcc('D', 'I', 'V', '3') /* DIVX311     */
4038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_DIVX      v4l2_fourcc('D', 'I', 'V', 'X') /* DIVX        */
4048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_VP8 v4l2_fourcc('V', 'P', '8', '0') /* ON2 VP8 stream */
4058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_HEVC v4l2_fourcc('H', 'E', 'V', 'C') /* for HEVC stream */
4068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
4078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Vendor-specific formats   */
4088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_CPIA1    v4l2_fourcc('C', 'P', 'I', 'A') /* cpia1 YUV */
4098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_WNVA     v4l2_fourcc('W', 'N', 'V', 'A') /* Winnov hw compress */
4108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SN9C10X  v4l2_fourcc('S', '9', '1', '0') /* SN9C10x compression */
4118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SN9C20X_I420 v4l2_fourcc('S', '9', '2', '0') /* SN9C20x YUV 4:2:0 */
4128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_PWC1     v4l2_fourcc('P', 'W', 'C', '1') /* pwc older webcam */
4138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_PWC2     v4l2_fourcc('P', 'W', 'C', '2') /* pwc newer webcam */
4148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_ET61X251 v4l2_fourcc('E', '6', '2', '5') /* ET61X251 compression */
4158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SPCA501  v4l2_fourcc('S', '5', '0', '1') /* YUYV per line */
4168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SPCA505  v4l2_fourcc('S', '5', '0', '5') /* YYUV per line */
4178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SPCA508  v4l2_fourcc('S', '5', '0', '8') /* YUVY per line */
4188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SPCA561  v4l2_fourcc('S', '5', '6', '1') /* compressed GBRG bayer */
4198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_PAC207   v4l2_fourcc('P', '2', '0', '7') /* compressed BGGR bayer */
4208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_MR97310A v4l2_fourcc('M', '3', '1', '0') /* compressed BGGR bayer */
4218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_JL2005BCD v4l2_fourcc('J', 'L', '2', '0') /* compressed RGGB bayer */
4228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SN9C2028 v4l2_fourcc('S', 'O', 'N', 'X') /* compressed GBRG bayer */
4238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SQ905C   v4l2_fourcc('9', '0', '5', 'C') /* compressed RGGB bayer */
4248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_PJPG     v4l2_fourcc('P', 'J', 'P', 'G') /* Pixart 73xx JPEG */
4258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_OV511    v4l2_fourcc('O', '5', '1', '1') /* ov511 JPEG */
4268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_OV518    v4l2_fourcc('O', '5', '1', '8') /* ov518 JPEG */
4278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_STV0680  v4l2_fourcc('S', '6', '8', '0') /* stv0680 bayer */
4288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_TM6000   v4l2_fourcc('T', 'M', '6', '0') /* tm5600/tm60x0 */
4298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_CIT_YYVYUY v4l2_fourcc('C', 'I', 'T', 'V') /* one line of Y then 1 line of VYUY */
4308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_KONICA420  v4l2_fourcc('K', 'O', 'N', 'I') /* YUV420 planar in blocks of 256 pixels */
4318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_JPGL	v4l2_fourcc('J', 'P', 'G', 'L') /* JPEG-Lite */
4328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* se401 janggu compressed rgb */
4338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_SE401      v4l2_fourcc('S', '4', '0', '1')
4348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Composite stats */
4358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_STATS_COMB v4l2_fourcc('S', 'T', 'C', 'M')
4368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* AEC stats */
4378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_STATS_AE   v4l2_fourcc('S', 'T', 'A', 'E')
4388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* AF stats */
4398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_STATS_AF   v4l2_fourcc('S', 'T', 'A', 'F')
4408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* AWB stats */
4418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_STATS_AWB  v4l2_fourcc('S', 'T', 'W', 'B')
4428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* IHIST stats */
4438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_STATS_IHST v4l2_fourcc('I', 'H', 'S', 'T')
4448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Column count stats */
4458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_STATS_CS   v4l2_fourcc('S', 'T', 'C', 'S')
4468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Row count stats */
4478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_STATS_RS   v4l2_fourcc('S', 'T', 'R', 'S')
4488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Bayer Grid stats */
4498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_STATS_BG   v4l2_fourcc('S', 'T', 'B', 'G')
4508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Bayer focus stats */
4518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_STATS_BF   v4l2_fourcc('S', 'T', 'B', 'F')
4528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Bayer hist stats */
4538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_PIX_FMT_STATS_BHST v4l2_fourcc('B', 'H', 'S', 'T')
4548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
4558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
4568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	F O R M A T   E N U M E R A T I O N
4578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
4588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_fmtdesc {
4598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		    index;             /* Format number      */
4608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_buf_type  type;              /* buffer type        */
4618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32               flags;
4628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8		    description[32];   /* Description string */
4638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		    pixelformat;       /* Format fourcc      */
4648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		    reserved[4];
4658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
4668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
4678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FMT_FLAG_COMPRESSED 0x0001
4688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FMT_FLAG_EMULATED   0x0002
4698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
4708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#if 1
4718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	/* Experimental Frame Size and frame rate enumeration */
4728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
4738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	F R A M E   S I Z E   E N U M E R A T I O N
4748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
4758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_frmsizetypes {
4768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FRMSIZE_TYPE_DISCRETE	= 1,
4778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FRMSIZE_TYPE_CONTINUOUS	= 2,
4788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FRMSIZE_TYPE_STEPWISE	= 3,
4798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
4808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
4818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_frmsize_discrete {
4828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			width;		/* Frame width [pixel] */
4838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			height;		/* Frame height [pixel] */
4848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
4858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
4868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_frmsize_stepwise {
4878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			min_width;	/* Minimum frame width [pixel] */
4888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			max_width;	/* Maximum frame width [pixel] */
4898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			step_width;	/* Frame width step size [pixel] */
4908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			min_height;	/* Minimum frame height [pixel] */
4918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			max_height;	/* Maximum frame height [pixel] */
4928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			step_height;	/* Frame height step size [pixel] */
4938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
4948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
4958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_frmsizeenum {
4968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			index;		/* Frame size number */
4978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			pixel_format;	/* Pixel format */
4988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			type;		/* Frame size type the device supports. */
4998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
5008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	union {					/* Frame size */
5018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_frmsize_discrete	discrete;
5028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_frmsize_stepwise	stepwise;
5038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	};
5048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
5058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32   reserved[2];			/* Reserved space for future use */
5068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
5078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
5088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
5098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	F R A M E   R A T E   E N U M E R A T I O N
5108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
5118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_frmivaltypes {
5128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FRMIVAL_TYPE_DISCRETE	= 1,
5138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FRMIVAL_TYPE_CONTINUOUS	= 2,
5148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FRMIVAL_TYPE_STEPWISE	= 3,
5158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
5168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
5178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_frmival_stepwise {
5188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_fract	min;		/* Minimum frame interval [s] */
5198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_fract	max;		/* Maximum frame interval [s] */
5208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_fract	step;		/* Frame interval step size [s] */
5218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
5228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
5238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_frmivalenum {
5248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			index;		/* Frame format index */
5258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			pixel_format;	/* Pixel format */
5268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			width;		/* Frame width */
5278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			height;		/* Frame height */
5288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			type;		/* Frame interval type the device supports. */
5298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
5308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	union {					/* Frame interval */
5318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_fract		discrete;
5328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_frmival_stepwise	stepwise;
5338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	};
5348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
5358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	reserved[2];			/* Reserved space for future use */
5368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
5378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#endif
5388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
5398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
5408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	T I M E C O D E
5418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
5428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_timecode {
5438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	type;
5448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	flags;
5458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8	frames;
5468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8	seconds;
5478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8	minutes;
5488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8	hours;
5498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8	userbits[4];
5508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
5518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
5528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Type  */
5538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TC_TYPE_24FPS		1
5548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TC_TYPE_25FPS		2
5558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TC_TYPE_30FPS		3
5568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TC_TYPE_50FPS		4
5578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TC_TYPE_60FPS		5
5588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
5598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Flags  */
5608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TC_FLAG_DROPFRAME		0x0001 /* "drop-frame" mode */
5618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TC_FLAG_COLORFRAME		0x0002
5628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TC_USERBITS_field		0x000C
5638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TC_USERBITS_USERDEFINED	0x0000
5648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TC_USERBITS_8BITCHARS	0x0008
5658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* The above is based on SMPTE timecodes */
5668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
5678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_jpegcompression {
5688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	int quality;
5698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
5708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	int  APPn;              /* Number of APP segment to be written,
5718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 * must be 0..15 */
5728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	int  APP_len;           /* Length of data in JPEG APPn segment */
5738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	char APP_data[60];      /* Data in the JPEG APPn segment. */
5748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
5758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	int  COM_len;           /* Length of data in JPEG COM segment */
5768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	char COM_data[60];      /* Data in JPEG COM segment */
5778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
5788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 jpeg_markers;     /* Which markers should go into the JPEG
5798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 * output. Unless you exactly know what
5808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 * you do, leave them untouched.
5818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 * Inluding less markers will make the
5828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 * resulting code smaller, but there will
5838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 * be fewer applications which can read it.
5848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 * The presence of the APP and COM marker
5858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 * is influenced by APP_len and COM_len
5868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 * ONLY, not by this property! */
5878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
5888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_JPEG_MARKER_DHT (1<<3)    /* Define Huffman Tables */
5898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_JPEG_MARKER_DQT (1<<4)    /* Define Quantization Tables */
5908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_JPEG_MARKER_DRI (1<<5)    /* Define Restart Interval */
5918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_JPEG_MARKER_COM (1<<6)    /* Comment segment */
5928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_JPEG_MARKER_APP (1<<7)    /* App segment, driver will
5938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris					* allways use APP0 */
5948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
5958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
5968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
5978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	M E M O R Y - M A P P I N G   B U F F E R S
5988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
5998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_requestbuffers {
6008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			count;
6018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_buf_type      type;
6028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_memory        memory;
6038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			reserved[2];
6048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
6058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
6068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/**
6078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * struct v4l2_plane - plane info for multi-planar buffers
6088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @bytesused:		number of bytes occupied by data in the plane (payload)
6098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @length:		size of this plane (NOT the payload) in bytes
6108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @mem_offset:		when memory in the associated struct v4l2_buffer is
6118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *			V4L2_MEMORY_MMAP, equals the offset from the start of
6128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *			the device memory for this plane (or is a "cookie" that
6138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *			should be passed to mmap() called on the video node)
6148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @userptr:		when memory is V4L2_MEMORY_USERPTR, a userspace pointer
6158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *			pointing to this plane
6168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @data_offset:	offset in the plane to the start of data; usually 0,
6178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *			unless there is a header in front of the data
6188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
6198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * Multi-planar buffers consist of one or more planes, e.g. an YCbCr buffer
6208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * with two planes can have one plane for Y, and another for interleaved CbCr
6218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * components. Each plane can reside in a separate memory buffer, or even in
6228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * a completely separate memory node (e.g. in embedded devices).
6238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
6248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_plane {
6258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			bytesused;
6268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			length;
6278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	union {
6288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		__u32		mem_offset;
6298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		unsigned long	userptr;
6308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	} m;
6318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			data_offset;
6328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			reserved[11];
6338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
6348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
6358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/**
6368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * struct v4l2_buffer - video buffer info
6378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @index:	id number of the buffer
6388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @type:	buffer type (type == *_MPLANE for multiplanar buffers)
6398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @bytesused:	number of bytes occupied by data in the buffer (payload);
6408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *		unused (set to 0) for multiplanar buffers
6418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @flags:	buffer informational flags
6428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @field:	field order of the image in the buffer
6438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @timestamp:	frame timestamp
6448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @timecode:	frame timecode
6458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @sequence:	sequence count of this frame
6468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @memory:	the method, in which the actual video data is passed
6478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @offset:	for non-multiplanar buffers with memory == V4L2_MEMORY_MMAP;
6488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *		offset from the start of the device memory for this plane,
6498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *		(or a "cookie" that should be passed to mmap() as offset)
6508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @userptr:	for non-multiplanar buffers with memory == V4L2_MEMORY_USERPTR;
6518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *		a userspace pointer pointing to this buffer
6528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @planes:	for multiplanar buffers; userspace pointer to the array of plane
6538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *		info structs for this buffer
6548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @length:	size in bytes of the buffer (NOT its payload) for single-plane
6558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *		buffers (when type != *_MPLANE); number of elements in the
6568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *		planes array for multi-plane buffers
6578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @input:	input number from which the video data has has been captured
6588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
6598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * Contains data exchanged by application and driver using one of the Streaming
6608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * I/O methods.
6618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
6628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_buffer {
6638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			index;
6648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_buf_type      type;
6658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			bytesused;
6668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			flags;
6678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_field		field;
6688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct timeval		timestamp;
6698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_timecode	timecode;
6708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			sequence;
6718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
6728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	/* memory location */
6738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_memory        memory;
6748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	union {
6758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		__u32           offset;
6768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		unsigned long   userptr;
6778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_plane *planes;
6788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	} m;
6798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			length;
6808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			input;
6818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			reserved;
6828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
6838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
6848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Flags for 'flags' field */
6858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_BUF_FLAG_MAPPED	0x0001  /* Buffer is mapped (flag) */
6868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_BUF_FLAG_QUEUED	0x0002	/* Buffer is queued for processing */
6878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_BUF_FLAG_DONE	0x0004	/* Buffer is ready */
6888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_BUF_FLAG_KEYFRAME	0x0008	/* Image is a keyframe (I-frame) */
6898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_BUF_FLAG_PFRAME	0x0010	/* Image is a P-frame */
6908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_BUF_FLAG_BFRAME	0x0020	/* Image is a B-frame */
6918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Buffer is ready, but the data contained within is corrupted. */
6928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_BUF_FLAG_ERROR	0x0040
6938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_BUF_FLAG_TIMECODE	0x0100	/* timecode field is valid */
6948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_BUF_FLAG_INPUT     0x0200  /* input field is valid */
6958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_BUF_FLAG_PREPARED	0x0400	/* Buffer is prepared for queuing */
6968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Cache handling flags */
6978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_BUF_FLAG_NO_CACHE_INVALIDATE	0x0800
6988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_BUF_FLAG_NO_CACHE_CLEAN		0x1000
6998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_BUF_FLAG_EOS		0x2000
7008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_QCOM_BUF_FLAG_CODECCONFIG  0x4000
7018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_QCOM_BUF_FLAG_EOSEQ  0x8000
7028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_QCOM_BUF_TIMESTAMP_INVALID 0x10000
7038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_QCOM_BUF_FLAG_IDRFRAME	0x20000	/* Image is a IDR-frame */
7048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_QCOM_BUF_FLAG_DECODEONLY 0x40000
7058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_QCOM_BUF_DATA_CORRUPT 0x80000
7068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_QCOM_BUF_DROP_FRAME 0x100000
7078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_QCOM_BUF_INPUT_UNSUPPORTED 0x200000
7088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_QCOM_BUF_FLAG_READONLY 0x400000
7098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
7108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
7118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	O V E R L A Y   P R E V I E W
7128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
7138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_framebuffer {
7148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			capability;
7158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			flags;
7168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* FIXME: in theory we should pass something like PCI device + memory
7178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * region + offset instead of some physical address */
7188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	void                    *base;
7198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_pix_format	fmt;
7208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
7218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Flags for the 'capability' field. Read only */
7228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FBUF_CAP_EXTERNOVERLAY	0x0001
7238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FBUF_CAP_CHROMAKEY		0x0002
7248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FBUF_CAP_LIST_CLIPPING     0x0004
7258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FBUF_CAP_BITMAP_CLIPPING	0x0008
7268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FBUF_CAP_LOCAL_ALPHA	0x0010
7278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FBUF_CAP_GLOBAL_ALPHA	0x0020
7288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FBUF_CAP_LOCAL_INV_ALPHA	0x0040
7298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FBUF_CAP_SRC_CHROMAKEY	0x0080
7308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Flags for the 'flags' field. */
7318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FBUF_FLAG_PRIMARY		0x0001
7328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FBUF_FLAG_OVERLAY		0x0002
7338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FBUF_FLAG_CHROMAKEY	0x0004
7348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FBUF_FLAG_LOCAL_ALPHA	0x0008
7358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FBUF_FLAG_GLOBAL_ALPHA	0x0010
7368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FBUF_FLAG_LOCAL_INV_ALPHA	0x0020
7378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FBUF_FLAG_SRC_CHROMAKEY	0x0040
7388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
7398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_clip {
7408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_rect        c;
7418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_clip	__user *next;
7428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
7438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
7448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_window {
7458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_rect        w;
7468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_field  	field;
7478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			chromakey;
7488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_clip	__user *clips;
7498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			clipcount;
7508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	void			__user *bitmap;
7518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8                    global_alpha;
7528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
7538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
7548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
7558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	C A P T U R E   P A R A M E T E R S
7568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
7578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_captureparm {
7588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		   capability;	  /*  Supported modes */
7598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		   capturemode;	  /*  Current mode */
7608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_fract  timeperframe;  /*  Time per frame in .1us units */
7618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		   extendedmode;  /*  Driver-specific extensions */
7628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32              readbuffers;   /*  # of buffers for read */
7638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		   reserved[4];
7648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
7658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
7668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Flags for 'capability' and 'capturemode' fields */
7678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_MODE_HIGHQUALITY	0x0001	/*  High quality imaging mode */
7688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_TIMEPERFRAME	0x1000	/*  timeperframe field is supported */
7698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CAP_QCOM_FRAMESKIP	0x2000	/*  frame skipping is supported */
7708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
7718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_qcom_frameskip {
7728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u64		maxframeinterval;
7738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
7748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
7758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_outputparm {
7768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		   capability;	 /*  Supported modes */
7778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		   outputmode;	 /*  Current mode */
7788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_fract  timeperframe; /*  Time per frame in seconds */
7798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		   extendedmode; /*  Driver-specific extensions */
7808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32              writebuffers; /*  # of buffers for write */
7818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		   reserved[4];
7828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
7838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
7848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
7858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	I N P U T   I M A G E   C R O P P I N G
7868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
7878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_cropcap {
7888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_buf_type      type;
7898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_rect        bounds;
7908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_rect        defrect;
7918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_fract       pixelaspect;
7928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
7938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
7948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_crop {
7958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_buf_type      type;
7968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_rect        c;
7978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
7988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
7998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Hints for adjustments of selection rectangle */
8008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_SEL_FLAG_GE	0x00000001
8018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_SEL_FLAG_LE	0x00000002
8028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
8038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Selection targets */
8048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
8058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Current cropping area */
8068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_SEL_TGT_CROP_ACTIVE	0x0000
8078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Default cropping area */
8088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_SEL_TGT_CROP_DEFAULT	0x0001
8098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Cropping bounds */
8108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_SEL_TGT_CROP_BOUNDS	0x0002
8118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Current composing area */
8128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_SEL_TGT_COMPOSE_ACTIVE	0x0100
8138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Default composing area */
8148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_SEL_TGT_COMPOSE_DEFAULT	0x0101
8158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Composing bounds */
8168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_SEL_TGT_COMPOSE_BOUNDS	0x0102
8178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Current composing area plus all padding pixels */
8188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_SEL_TGT_COMPOSE_PADDED	0x0103
8198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
8208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/**
8218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * struct v4l2_selection - selection info
8228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @type:	buffer type (do not use *_MPLANE types)
8238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @target:	selection target, used to choose one of possible rectangles
8248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @flags:	constraints flags
8258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @r:		coordinates of selection window
8268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @reserved:	for future use, rounds structure size to 64 bytes, set to zero
8278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
8288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * Hardware may use multiple helper windows to process a video stream.
8298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * The structure is used to exchange this selection areas between
8308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * an application and a driver.
8318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
8328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_selection {
8338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			type;
8348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			target;
8358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32                   flags;
8368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_rect        r;
8378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32                   reserved[9];
8388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
8398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
8408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
8418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
8428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *      A N A L O G   V I D E O   S T A N D A R D
8438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
8448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
8458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferristypedef __u64 v4l2_std_id;
8468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
8478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* one bit for each */
8488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_PAL_B          ((v4l2_std_id)0x00000001)
8498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_PAL_B1         ((v4l2_std_id)0x00000002)
8508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_PAL_G          ((v4l2_std_id)0x00000004)
8518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_PAL_H          ((v4l2_std_id)0x00000008)
8528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_PAL_I          ((v4l2_std_id)0x00000010)
8538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_PAL_D          ((v4l2_std_id)0x00000020)
8548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_PAL_D1         ((v4l2_std_id)0x00000040)
8558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_PAL_K          ((v4l2_std_id)0x00000080)
8568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
8578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_PAL_M          ((v4l2_std_id)0x00000100)
8588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_PAL_N          ((v4l2_std_id)0x00000200)
8598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_PAL_Nc         ((v4l2_std_id)0x00000400)
8608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_PAL_60         ((v4l2_std_id)0x00000800)
8618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
8628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_NTSC_M         ((v4l2_std_id)0x00001000)	/* BTSC */
8638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_NTSC_M_JP      ((v4l2_std_id)0x00002000)	/* EIA-J */
8648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_NTSC_443       ((v4l2_std_id)0x00004000)
8658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_NTSC_M_KR      ((v4l2_std_id)0x00008000)	/* FM A2 */
8668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
8678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_SECAM_B        ((v4l2_std_id)0x00010000)
8688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_SECAM_D        ((v4l2_std_id)0x00020000)
8698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_SECAM_G        ((v4l2_std_id)0x00040000)
8708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_SECAM_H        ((v4l2_std_id)0x00080000)
8718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_SECAM_K        ((v4l2_std_id)0x00100000)
8728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_SECAM_K1       ((v4l2_std_id)0x00200000)
8738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_SECAM_L        ((v4l2_std_id)0x00400000)
8748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_SECAM_LC       ((v4l2_std_id)0x00800000)
8758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
8768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* ATSC/HDTV */
8778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_ATSC_8_VSB     ((v4l2_std_id)0x01000000)
8788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_ATSC_16_VSB    ((v4l2_std_id)0x02000000)
8798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
8808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* FIXME:
8818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris   Although std_id is 64 bits, there is an issue on PPC32 architecture that
8828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris   makes switch(__u64) to break. So, there's a hack on v4l2-common.c rounding
8838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris   this value to 32 bits.
8848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris   As, currently, the max value is for V4L2_STD_ATSC_16_VSB (30 bits wide),
8858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris   it should work fine. However, if needed to add more than two standards,
8868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris   v4l2-common.c should be fixed.
8878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
8888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
8898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
8908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * Some macros to merge video standards in order to make live easier for the
8918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * drivers and V4L2 applications
8928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
8938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
8948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
8958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * "Common" NTSC/M - It should be noticed that V4L2_STD_NTSC_443 is
8968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * Missing here.
8978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
8988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_NTSC           (V4L2_STD_NTSC_M	|\
8998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_NTSC_M_JP     |\
9008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_NTSC_M_KR)
9018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Secam macros */
9028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_SECAM_DK      	(V4L2_STD_SECAM_D	|\
9038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_SECAM_K	|\
9048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_SECAM_K1)
9058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* All Secam Standards */
9068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_SECAM		(V4L2_STD_SECAM_B	|\
9078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_SECAM_G	|\
9088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_SECAM_H	|\
9098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_SECAM_DK	|\
9108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_SECAM_L       |\
9118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_SECAM_LC)
9128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* PAL macros */
9138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_PAL_BG		(V4L2_STD_PAL_B		|\
9148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_PAL_B1	|\
9158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_PAL_G)
9168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_PAL_DK		(V4L2_STD_PAL_D		|\
9178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_PAL_D1	|\
9188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_PAL_K)
9198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
9208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * "Common" PAL - This macro is there to be compatible with the old
9218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * V4L1 concept of "PAL": /BGDKHI.
9228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * Several PAL standards are mising here: /M, /N and /Nc
9238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
9248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_PAL		(V4L2_STD_PAL_BG	|\
9258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_PAL_DK	|\
9268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_PAL_H		|\
9278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_PAL_I)
9288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Chroma "agnostic" standards */
9298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_B		(V4L2_STD_PAL_B		|\
9308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_PAL_B1	|\
9318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_SECAM_B)
9328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_G		(V4L2_STD_PAL_G		|\
9338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_SECAM_G)
9348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_H		(V4L2_STD_PAL_H		|\
9358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_SECAM_H)
9368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_L		(V4L2_STD_SECAM_L	|\
9378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_SECAM_LC)
9388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_GH		(V4L2_STD_G		|\
9398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_H)
9408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_DK		(V4L2_STD_PAL_DK	|\
9418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_SECAM_DK)
9428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_BG		(V4L2_STD_B		|\
9438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_G)
9448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_MN		(V4L2_STD_PAL_M		|\
9458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_PAL_N		|\
9468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_PAL_Nc	|\
9478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_NTSC)
9488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
9498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Standards where MTS/BTSC stereo could be found */
9508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_MTS		(V4L2_STD_NTSC_M	|\
9518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_PAL_M		|\
9528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_PAL_N		|\
9538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_PAL_Nc)
9548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
9558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Standards for Countries with 60Hz Line frequency */
9568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_525_60		(V4L2_STD_PAL_M		|\
9578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_PAL_60	|\
9588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_NTSC		|\
9598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_NTSC_443)
9608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Standards for Countries with 50Hz Line frequency */
9618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_625_50		(V4L2_STD_PAL		|\
9628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_PAL_N		|\
9638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_PAL_Nc	|\
9648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_SECAM)
9658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
9668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_ATSC           (V4L2_STD_ATSC_8_VSB    |\
9678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_ATSC_16_VSB)
9688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Macros with none and all analog standards */
9698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_UNKNOWN        0
9708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_STD_ALL            (V4L2_STD_525_60	|\
9718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 V4L2_STD_625_50)
9728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
9738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_standard {
9748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		     index;
9758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	v4l2_std_id          id;
9768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8		     name[24];
9778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_fract    frameperiod; /* Frames, not fields */
9788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		     framelines;
9798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		     reserved[4];
9808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
9818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
9828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
9838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	V I D E O	T I M I N G S	D V	P R E S E T
9848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
9858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_dv_preset {
9868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	preset;
9878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	reserved[4];
9888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
9898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
9908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
9918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	D V	P R E S E T S	E N U M E R A T I O N
9928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
9938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_dv_enum_preset {
9948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	index;
9958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	preset;
9968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8	name[32]; /* Name of the preset timing */
9978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	width;
9988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	height;
9998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	reserved[4];
10008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
10018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
10028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
10038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * 	D V	P R E S E T	V A L U E S
10048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
10058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_INVALID		0
10068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_480P59_94	1 /* BT.1362 */
10078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_576P50		2 /* BT.1362 */
10088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_720P24		3 /* SMPTE 296M */
10098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_720P25		4 /* SMPTE 296M */
10108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_720P30		5 /* SMPTE 296M */
10118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_720P50		6 /* SMPTE 296M */
10128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_720P59_94	7 /* SMPTE 274M */
10138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_720P60		8 /* SMPTE 274M/296M */
10148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_1080I29_97	9 /* BT.1120/ SMPTE 274M */
10158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_1080I30		10 /* BT.1120/ SMPTE 274M */
10168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_1080I25		11 /* BT.1120 */
10178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_1080I50		12 /* SMPTE 296M */
10188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_1080I60		13 /* SMPTE 296M */
10198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_1080P24		14 /* SMPTE 296M */
10208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_1080P25		15 /* SMPTE 296M */
10218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_1080P30		16 /* SMPTE 296M */
10228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_1080P50		17 /* BT.1120 */
10238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define		V4L2_DV_1080P60		18 /* BT.1120 */
10248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
10258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
10268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	D V 	B T	T I M I N G S
10278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
10288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
10298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* BT.656/BT.1120 timing data */
10308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_bt_timings {
10318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	width;		/* width in pixels */
10328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	height;		/* height in lines */
10338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	interlaced;	/* Interlaced or progressive */
10348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	polarities;	/* Positive or negative polarity */
10358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u64	pixelclock;	/* Pixel clock in HZ. Ex. 74.25MHz->74250000 */
10368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	hfrontporch;	/* Horizpontal front porch in pixels */
10378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	hsync;		/* Horizontal Sync length in pixels */
10388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	hbackporch;	/* Horizontal back porch in pixels */
10398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	vfrontporch;	/* Vertical front porch in pixels */
10408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	vsync;		/* Vertical Sync length in lines */
10418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	vbackporch;	/* Vertical back porch in lines */
10428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	il_vfrontporch;	/* Vertical front porch for bottom field of
10438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 * interlaced field formats
10448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 */
10458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	il_vsync;	/* Vertical sync length for bottom field of
10468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 * interlaced field formats
10478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 */
10488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	il_vbackporch;	/* Vertical back porch for bottom field of
10498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 * interlaced field formats
10508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 */
10518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	reserved[16];
10528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris} __attribute__ ((packed));
10538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
10548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Interlaced or progressive format */
10558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	V4L2_DV_PROGRESSIVE	0
10568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	V4L2_DV_INTERLACED	1
10578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
10588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Polarities. If bit is not set, it is assumed to be negative polarity */
10598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_DV_VSYNC_POS_POL	0x00000001
10608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_DV_HSYNC_POS_POL	0x00000002
10618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
10628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
10638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* DV timings */
10648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_dv_timings {
10658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 type;
10668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	union {
10678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_bt_timings	bt;
10688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		__u32	reserved[32];
10698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	};
10708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris} __attribute__ ((packed));
10718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
10728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Values for the type field */
10738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_DV_BT_656_1120	0	/* BT.656/1120 timing type */
10748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
10758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
10768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	V I D E O   I N P U T S
10778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
10788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_input {
10798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	     index;		/*  Which input */
10808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8	     name[32];		/*  Label */
10818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	     type;		/*  Type of input */
10828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	     audioset;		/*  Associated audios (bitfield) */
10838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32        tuner;             /*  Associated tuner */
10848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	v4l2_std_id  std;
10858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	     status;
10868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	     capabilities;
10878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	     reserved[3];
10888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
10898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
10908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Values for the 'type' field */
10918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_INPUT_TYPE_TUNER		1
10928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_INPUT_TYPE_CAMERA		2
10938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
10948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* field 'status' - general */
10958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_IN_ST_NO_POWER    0x00000001  /* Attached device is off */
10968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_IN_ST_NO_SIGNAL   0x00000002
10978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_IN_ST_NO_COLOR    0x00000004
10988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
10998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* field 'status' - sensor orientation */
11008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* If sensor is mounted upside down set both bits */
11018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_IN_ST_HFLIP       0x00000010 /* Frames are flipped horizontally */
11028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_IN_ST_VFLIP       0x00000020 /* Frames are flipped vertically */
11038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
11048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* field 'status' - analog */
11058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_IN_ST_NO_H_LOCK   0x00000100  /* No horizontal sync lock */
11068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_IN_ST_COLOR_KILL  0x00000200  /* Color killer is active */
11078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
11088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* field 'status' - digital */
11098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_IN_ST_NO_SYNC     0x00010000  /* No synchronization lock */
11108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_IN_ST_NO_EQU      0x00020000  /* No equalizer lock */
11118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_IN_ST_NO_CARRIER  0x00040000  /* Carrier recovery failed */
11128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
11138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* field 'status' - VCR and set-top box */
11148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_IN_ST_MACROVISION 0x01000000  /* Macrovision detected */
11158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_IN_ST_NO_ACCESS   0x02000000  /* Conditional access denied */
11168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_IN_ST_VTR         0x04000000  /* VTR time constant */
11178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
11188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* capabilities flags */
11198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_IN_CAP_PRESETS		0x00000001 /* Supports S_DV_PRESET */
11208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_IN_CAP_CUSTOM_TIMINGS	0x00000002 /* Supports S_DV_TIMINGS */
11218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_IN_CAP_STD			0x00000004 /* Supports S_STD */
11228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
11238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
11248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	V I D E O   O U T P U T S
11258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
11268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_output {
11278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	     index;		/*  Which output */
11288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8	     name[32];		/*  Label */
11298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	     type;		/*  Type of output */
11308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	     audioset;		/*  Associated audios (bitfield) */
11318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	     modulator;         /*  Associated modulator */
11328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	v4l2_std_id  std;
11338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	     capabilities;
11348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	     reserved[3];
11358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
11368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Values for the 'type' field */
11378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_OUTPUT_TYPE_MODULATOR		1
11388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_OUTPUT_TYPE_ANALOG			2
11398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_OUTPUT_TYPE_ANALOGVGAOVERLAY	3
11408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
11418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* capabilities flags */
11428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_OUT_CAP_PRESETS		0x00000001 /* Supports S_DV_PRESET */
11438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_OUT_CAP_CUSTOM_TIMINGS	0x00000002 /* Supports S_DV_TIMINGS */
11448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_OUT_CAP_STD		0x00000004 /* Supports S_STD */
11458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
11468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
11478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	C O N T R O L S
11488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
11498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_control {
11508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		     id;
11518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__s32		     value;
11528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
11538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
11548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_ext_control {
11558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 id;
11568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 size;
11578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 reserved2[1];
11588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	union {
11598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		__s32 value;
11608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		__s64 value64;
11618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		char *string;
11628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	};
11638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris} __attribute__ ((packed));
11648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
11658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_ext_controls {
11668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 ctrl_class;
11678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 count;
11688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 error_idx;
11698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 reserved[2];
11708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_ext_control *controls;
11718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
11728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
11738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Values for ctrl_class field */
11748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_CLASS_USER 0x00980000	/* Old-style 'user' controls */
11758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_CLASS_MPEG 0x00990000	/* MPEG-compression controls */
11768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_CLASS_CAMERA 0x009a0000	/* Camera class controls */
11778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_CLASS_FM_TX 0x009b0000	/* FM Modulator control class */
11788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_CLASS_FLASH 0x009c0000	/* Camera flash controls */
11798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_CLASS_JPEG 0x009d0000		/* JPEG-compression controls */
11808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
11818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_ID_MASK      	  (0x0fffffff)
11828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_ID2CLASS(id)    ((id) & 0x0fff0000UL)
11838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_DRIVER_PRIV(id) (((id) & 0xffff) >= 0x1000)
11848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
11858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_ctrl_type {
11868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CTRL_TYPE_INTEGER	     = 1,
11878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CTRL_TYPE_BOOLEAN	     = 2,
11888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CTRL_TYPE_MENU	     = 3,
11898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CTRL_TYPE_BUTTON	     = 4,
11908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CTRL_TYPE_INTEGER64     = 5,
11918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CTRL_TYPE_CTRL_CLASS    = 6,
11928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CTRL_TYPE_STRING        = 7,
11938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CTRL_TYPE_BITMASK       = 8,
11948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
11958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
11968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Used in the VIDIOC_QUERYCTRL ioctl for querying controls */
11978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_queryctrl {
11988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		     id;
11998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_ctrl_type  type;
12008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8		     name[32];	/* Whatever */
12018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__s32		     minimum;	/* Note signedness */
12028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__s32		     maximum;
12038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__s32		     step;
12048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__s32		     default_value;
12058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32                flags;
12068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		     reserved[2];
12078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
12088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
12098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Used in the VIDIOC_QUERYMENU ioctl for querying menu items */
12108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_querymenu {
12118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		id;
12128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		index;
12138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8		name[32];	/* Whatever */
12148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		reserved;
12158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
12168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
12178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Control flags  */
12188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_FLAG_DISABLED		0x0001
12198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_FLAG_GRABBED		0x0002
12208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_FLAG_READ_ONLY 	0x0004
12218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_FLAG_UPDATE 		0x0008
12228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_FLAG_INACTIVE 	0x0010
12238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_FLAG_SLIDER 		0x0020
12248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_FLAG_WRITE_ONLY 	0x0040
12258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_FLAG_VOLATILE		0x0080
12268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
12278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Query flag, to be ORed with the control ID */
12288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CTRL_FLAG_NEXT_CTRL	0x80000000
12298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
12308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  User-class control IDs defined by V4L2 */
12318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MAX_CTRLS		1024
12328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_BASE			(V4L2_CTRL_CLASS_USER | 0x900)
12338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_USER_BASE 		V4L2_CID_BASE
12348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  IDs reserved for driver specific controls */
12358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_PRIVATE_BASE		0x08000000
12368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
12378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_USER_CLASS 		(V4L2_CTRL_CLASS_USER | 1)
12388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_BRIGHTNESS		(V4L2_CID_BASE+0)
12398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_CONTRAST		(V4L2_CID_BASE+1)
12408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_SATURATION		(V4L2_CID_BASE+2)
12418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_HUE			(V4L2_CID_BASE+3)
12428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_AUDIO_VOLUME		(V4L2_CID_BASE+5)
12438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_AUDIO_BALANCE		(V4L2_CID_BASE+6)
12448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_AUDIO_BASS		(V4L2_CID_BASE+7)
12458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_AUDIO_TREBLE		(V4L2_CID_BASE+8)
12468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_AUDIO_MUTE		(V4L2_CID_BASE+9)
12478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_AUDIO_LOUDNESS		(V4L2_CID_BASE+10)
12488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_BLACK_LEVEL		(V4L2_CID_BASE+11) /* Deprecated */
12498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_AUTO_WHITE_BALANCE	(V4L2_CID_BASE+12)
12508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_DO_WHITE_BALANCE	(V4L2_CID_BASE+13)
12518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_RED_BALANCE		(V4L2_CID_BASE+14)
12528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_BLUE_BALANCE		(V4L2_CID_BASE+15)
12538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_GAMMA			(V4L2_CID_BASE+16)
12548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_WHITENESS		(V4L2_CID_GAMMA) /* Deprecated */
12558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_EXPOSURE		(V4L2_CID_BASE+17)
12568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_AUTOGAIN		(V4L2_CID_BASE+18)
12578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_GAIN			(V4L2_CID_BASE+19)
12588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_HFLIP			(V4L2_CID_BASE+20)
12598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_VFLIP			(V4L2_CID_BASE+21)
12608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
12618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Deprecated; use V4L2_CID_PAN_RESET and V4L2_CID_TILT_RESET */
12628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_HCENTER		(V4L2_CID_BASE+22)
12638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_VCENTER		(V4L2_CID_BASE+23)
12648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
12658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_POWER_LINE_FREQUENCY	(V4L2_CID_BASE+24)
12668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_power_line_frequency {
12678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_POWER_LINE_FREQUENCY_DISABLED	= 0,
12688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_POWER_LINE_FREQUENCY_50HZ	= 1,
12698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_POWER_LINE_FREQUENCY_60HZ	= 2,
12708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_POWER_LINE_FREQUENCY_AUTO	= 3,
12718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
12728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_HUE_AUTO			(V4L2_CID_BASE+25)
12738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_WHITE_BALANCE_TEMPERATURE	(V4L2_CID_BASE+26)
12748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_SHARPNESS			(V4L2_CID_BASE+27)
12758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_BACKLIGHT_COMPENSATION 	(V4L2_CID_BASE+28)
12768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_CHROMA_AGC                     (V4L2_CID_BASE+29)
12778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_COLOR_KILLER                   (V4L2_CID_BASE+30)
12788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_COLORFX			(V4L2_CID_BASE+31)
12798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_colorfx {
12808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORFX_NONE	= 0,
12818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORFX_BW		= 1,
12828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORFX_SEPIA	= 2,
12838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORFX_NEGATIVE = 3,
12848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORFX_EMBOSS = 4,
12858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORFX_SKETCH = 5,
12868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORFX_SKY_BLUE = 6,
12878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORFX_GRASS_GREEN = 7,
12888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORFX_SKIN_WHITEN = 8,
12898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_COLORFX_VIVID = 9,
12908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
12918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_AUTOBRIGHTNESS			(V4L2_CID_BASE+32)
12928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_BAND_STOP_FILTER		(V4L2_CID_BASE+33)
12938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
12948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_ROTATE				(V4L2_CID_BASE+34)
12958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_BG_COLOR			(V4L2_CID_BASE+35)
12968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
12978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_CHROMA_GAIN                    (V4L2_CID_BASE+36)
12988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
12998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_ILLUMINATORS_1			(V4L2_CID_BASE+37)
13008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_ILLUMINATORS_2			(V4L2_CID_BASE+38)
13018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
13028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MIN_BUFFERS_FOR_CAPTURE	(V4L2_CID_BASE+39)
13038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MIN_BUFFERS_FOR_OUTPUT		(V4L2_CID_BASE+40)
13048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
13058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_ALPHA_COMPONENT		(V4L2_CID_BASE+41)
13068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
13078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* last CID + 1 */
13088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_LASTP1                         (V4L2_CID_BASE+42)
13098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_SPECIAL_EFFECT			(V4L2_CID_BASE+43)
13108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Minimum number of buffer neede by the device */
13118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
13128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  MPEG-class control IDs defined by V4L2 */
13138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_BASE 			(V4L2_CTRL_CLASS_MPEG | 0x900)
13148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_CLASS 			(V4L2_CTRL_CLASS_MPEG | 1)
13158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
13168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  MPEG streams, specific to multiplexed streams */
13178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_STREAM_TYPE 		(V4L2_CID_MPEG_BASE+0)
13188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_stream_type {
13198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_STREAM_TYPE_MPEG2_PS   = 0, /* MPEG-2 program stream */
13208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_STREAM_TYPE_MPEG2_TS   = 1, /* MPEG-2 transport stream */
13218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_STREAM_TYPE_MPEG1_SS   = 2, /* MPEG-1 system stream */
13228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_STREAM_TYPE_MPEG2_DVD  = 3, /* MPEG-2 DVD-compatible stream */
13238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_STREAM_TYPE_MPEG1_VCD  = 4, /* MPEG-1 VCD-compatible stream */
13248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_STREAM_TYPE_MPEG2_SVCD = 5, /* MPEG-2 SVCD-compatible stream */
13258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
13268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_STREAM_PID_PMT 		(V4L2_CID_MPEG_BASE+1)
13278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_STREAM_PID_AUDIO 		(V4L2_CID_MPEG_BASE+2)
13288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_STREAM_PID_VIDEO 		(V4L2_CID_MPEG_BASE+3)
13298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_STREAM_PID_PCR 		(V4L2_CID_MPEG_BASE+4)
13308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_STREAM_PES_ID_AUDIO 	(V4L2_CID_MPEG_BASE+5)
13318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_STREAM_PES_ID_VIDEO 	(V4L2_CID_MPEG_BASE+6)
13328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_STREAM_VBI_FMT 		(V4L2_CID_MPEG_BASE+7)
13338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_stream_vbi_fmt {
13348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_STREAM_VBI_FMT_NONE = 0,  /* No VBI in the MPEG stream */
13358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_STREAM_VBI_FMT_IVTV = 1,  /* VBI in private packets, IVTV format */
13368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
13378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
13388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  MPEG audio controls specific to multiplexed streams  */
13398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_AUDIO_SAMPLING_FREQ 	(V4L2_CID_MPEG_BASE+100)
13408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_audio_sampling_freq {
13418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_SAMPLING_FREQ_44100 = 0,
13428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_SAMPLING_FREQ_48000 = 1,
13438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_SAMPLING_FREQ_32000 = 2,
13448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
13458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_AUDIO_ENCODING 		(V4L2_CID_MPEG_BASE+101)
13468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_audio_encoding {
13478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_ENCODING_LAYER_1 = 0,
13488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_ENCODING_LAYER_2 = 1,
13498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_ENCODING_LAYER_3 = 2,
13508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_ENCODING_AAC     = 3,
13518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_ENCODING_AC3     = 4,
13528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
13538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_AUDIO_L1_BITRATE 		(V4L2_CID_MPEG_BASE+102)
13548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_audio_l1_bitrate {
13558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L1_BITRATE_32K  = 0,
13568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L1_BITRATE_64K  = 1,
13578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L1_BITRATE_96K  = 2,
13588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L1_BITRATE_128K = 3,
13598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L1_BITRATE_160K = 4,
13608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L1_BITRATE_192K = 5,
13618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L1_BITRATE_224K = 6,
13628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L1_BITRATE_256K = 7,
13638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L1_BITRATE_288K = 8,
13648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L1_BITRATE_320K = 9,
13658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L1_BITRATE_352K = 10,
13668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L1_BITRATE_384K = 11,
13678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L1_BITRATE_416K = 12,
13688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L1_BITRATE_448K = 13,
13698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
13708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_AUDIO_L2_BITRATE 		(V4L2_CID_MPEG_BASE+103)
13718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_audio_l2_bitrate {
13728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L2_BITRATE_32K  = 0,
13738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L2_BITRATE_48K  = 1,
13748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L2_BITRATE_56K  = 2,
13758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L2_BITRATE_64K  = 3,
13768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L2_BITRATE_80K  = 4,
13778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L2_BITRATE_96K  = 5,
13788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L2_BITRATE_112K = 6,
13798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L2_BITRATE_128K = 7,
13808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L2_BITRATE_160K = 8,
13818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L2_BITRATE_192K = 9,
13828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L2_BITRATE_224K = 10,
13838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L2_BITRATE_256K = 11,
13848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L2_BITRATE_320K = 12,
13858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L2_BITRATE_384K = 13,
13868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
13878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_AUDIO_L3_BITRATE 		(V4L2_CID_MPEG_BASE+104)
13888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_audio_l3_bitrate {
13898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L3_BITRATE_32K  = 0,
13908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L3_BITRATE_40K  = 1,
13918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L3_BITRATE_48K  = 2,
13928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L3_BITRATE_56K  = 3,
13938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L3_BITRATE_64K  = 4,
13948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L3_BITRATE_80K  = 5,
13958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L3_BITRATE_96K  = 6,
13968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L3_BITRATE_112K = 7,
13978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L3_BITRATE_128K = 8,
13988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L3_BITRATE_160K = 9,
13998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L3_BITRATE_192K = 10,
14008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L3_BITRATE_224K = 11,
14018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L3_BITRATE_256K = 12,
14028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_L3_BITRATE_320K = 13,
14038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
14048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_AUDIO_MODE 		(V4L2_CID_MPEG_BASE+105)
14058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_audio_mode {
14068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_MODE_STEREO       = 0,
14078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_MODE_JOINT_STEREO = 1,
14088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_MODE_DUAL         = 2,
14098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_MODE_MONO         = 3,
14108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
14118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_AUDIO_MODE_EXTENSION 	(V4L2_CID_MPEG_BASE+106)
14128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_audio_mode_extension {
14138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_4  = 0,
14148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_8  = 1,
14158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_12 = 2,
14168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_MODE_EXTENSION_BOUND_16 = 3,
14178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
14188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_AUDIO_EMPHASIS 		(V4L2_CID_MPEG_BASE+107)
14198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_audio_emphasis {
14208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_EMPHASIS_NONE         = 0,
14218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_EMPHASIS_50_DIV_15_uS = 1,
14228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_EMPHASIS_CCITT_J17    = 2,
14238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
14248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_AUDIO_CRC 		(V4L2_CID_MPEG_BASE+108)
14258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_audio_crc {
14268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_CRC_NONE  = 0,
14278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_CRC_CRC16 = 1,
14288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
14298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_AUDIO_MUTE 		(V4L2_CID_MPEG_BASE+109)
14308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_AUDIO_AAC_BITRATE		(V4L2_CID_MPEG_BASE+110)
14318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_AUDIO_AC3_BITRATE		(V4L2_CID_MPEG_BASE+111)
14328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_audio_ac3_bitrate {
14338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_32K  = 0,
14348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_40K  = 1,
14358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_48K  = 2,
14368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_56K  = 3,
14378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_64K  = 4,
14388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_80K  = 5,
14398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_96K  = 6,
14408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_112K = 7,
14418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_128K = 8,
14428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_160K = 9,
14438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_192K = 10,
14448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_224K = 11,
14458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_256K = 12,
14468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_320K = 13,
14478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_384K = 14,
14488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_448K = 15,
14498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_512K = 16,
14508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_576K = 17,
14518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_AC3_BITRATE_640K = 18,
14528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
14538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_AUDIO_DEC_PLAYBACK	(V4L2_CID_MPEG_BASE+112)
14548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_audio_dec_playback {
14558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_DEC_PLAYBACK_AUTO	    = 0,
14568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_DEC_PLAYBACK_STEREO	    = 1,
14578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_DEC_PLAYBACK_LEFT	    = 2,
14588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_DEC_PLAYBACK_RIGHT	    = 3,
14598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_DEC_PLAYBACK_MONO	    = 4,
14608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_AUDIO_DEC_PLAYBACK_SWAPPED_STEREO = 5,
14618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
14628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_AUDIO_DEC_MULTILINGUAL_PLAYBACK (V4L2_CID_MPEG_BASE+113)
14638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
14648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  MPEG video controls specific to multiplexed streams */
14658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_ENCODING 		(V4L2_CID_MPEG_BASE+200)
14668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_video_encoding {
14678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_ENCODING_MPEG_1     = 0,
14688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_ENCODING_MPEG_2     = 1,
14698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_ENCODING_MPEG_4_AVC = 2,
14708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
14718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_ASPECT 		(V4L2_CID_MPEG_BASE+201)
14728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_video_aspect {
14738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_ASPECT_1x1     = 0,
14748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_ASPECT_4x3     = 1,
14758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_ASPECT_16x9    = 2,
14768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_ASPECT_221x100 = 3,
14778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
14788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_B_FRAMES 		(V4L2_CID_MPEG_BASE+202)
14798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_GOP_SIZE 		(V4L2_CID_MPEG_BASE+203)
14808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_GOP_CLOSURE 	(V4L2_CID_MPEG_BASE+204)
14818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_PULLDOWN 		(V4L2_CID_MPEG_BASE+205)
14828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_BITRATE_MODE 	(V4L2_CID_MPEG_BASE+206)
14838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_video_bitrate_mode {
14848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_BITRATE_MODE_VBR = 0,
14858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_BITRATE_MODE_CBR = 1,
14868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
14878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_BITRATE 		(V4L2_CID_MPEG_BASE+207)
14888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_BITRATE_PEAK 	(V4L2_CID_MPEG_BASE+208)
14898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_TEMPORAL_DECIMATION (V4L2_CID_MPEG_BASE+209)
14908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_MUTE 		(V4L2_CID_MPEG_BASE+210)
14918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_MUTE_YUV 		(V4L2_CID_MPEG_BASE+211)
14928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_DECODER_SLICE_INTERFACE		(V4L2_CID_MPEG_BASE+212)
14938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_DECODER_MPEG4_DEBLOCK_FILTER	(V4L2_CID_MPEG_BASE+213)
14948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_CYCLIC_INTRA_REFRESH_MB		(V4L2_CID_MPEG_BASE+214)
14958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_FRAME_RC_ENABLE			(V4L2_CID_MPEG_BASE+215)
14968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_HEADER_MODE				(V4L2_CID_MPEG_BASE+216)
14978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_video_header_mode {
14988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_HEADER_MODE_SEPARATE			= 0,
14998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_HEADER_MODE_JOINED_WITH_1ST_FRAME	= 1,
15008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_HEADER_MODE_JOINED_WITH_I_FRAME		= 2,
15018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
15028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
15038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_MAX_REF_PIC			(V4L2_CID_MPEG_BASE+217)
15048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_MB_RC_ENABLE		(V4L2_CID_MPEG_BASE+218)
15058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_BYTES	(V4L2_CID_MPEG_BASE+219)
15068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MAX_MB		(V4L2_CID_MPEG_BASE+220)
15078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_MULTI_SLICE_MODE		(V4L2_CID_MPEG_BASE+221)
15088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_video_multi_slice_mode {
15098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_MULTI_SLICE_MODE_SINGLE		= 0,
15108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_MULTI_SICE_MODE_MAX_MB		= 1,
15118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_MULTI_SICE_MODE_MAX_BYTES	= 2,
15128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_MULTI_SLICE_GOB			= 3,
15138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
15148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_VBV_SIZE			(V4L2_CID_MPEG_BASE+222)
15158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_DEC_PTS			(V4L2_CID_MPEG_BASE+223)
15168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_DEC_FRAME			(V4L2_CID_MPEG_BASE+224)
15178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
15188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H263_I_FRAME_QP		(V4L2_CID_MPEG_BASE+300)
15198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H263_P_FRAME_QP		(V4L2_CID_MPEG_BASE+301)
15208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H263_B_FRAME_QP		(V4L2_CID_MPEG_BASE+302)
15218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H263_MIN_QP			(V4L2_CID_MPEG_BASE+303)
15228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H263_MAX_QP			(V4L2_CID_MPEG_BASE+304)
15238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_I_FRAME_QP		(V4L2_CID_MPEG_BASE+350)
15248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_P_FRAME_QP		(V4L2_CID_MPEG_BASE+351)
15258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_B_FRAME_QP		(V4L2_CID_MPEG_BASE+352)
15268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_MIN_QP			(V4L2_CID_MPEG_BASE+353)
15278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_MAX_QP			(V4L2_CID_MPEG_BASE+354)
15288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_8X8_TRANSFORM		(V4L2_CID_MPEG_BASE+355)
15298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_CPB_SIZE		(V4L2_CID_MPEG_BASE+356)
15308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_ENTROPY_MODE		(V4L2_CID_MPEG_BASE+357)
15318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_video_h264_entropy_mode {
15328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CAVLC	= 0,
15338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_ENTROPY_MODE_CABAC	= 1,
15348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
15358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_I_PERIOD		(V4L2_CID_MPEG_BASE+358)
15368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_LEVEL			(V4L2_CID_MPEG_BASE+359)
15378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_video_h264_level {
15388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LEVEL_1_0	= 0,
15398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LEVEL_1B	= 1,
15408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LEVEL_1_1	= 2,
15418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LEVEL_1_2	= 3,
15428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LEVEL_1_3	= 4,
15438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LEVEL_2_0	= 5,
15448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LEVEL_2_1	= 6,
15458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LEVEL_2_2	= 7,
15468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LEVEL_3_0	= 8,
15478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LEVEL_3_1	= 9,
15488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LEVEL_3_2	= 10,
15498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LEVEL_4_0	= 11,
15508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LEVEL_4_1	= 12,
15518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LEVEL_4_2	= 13,
15528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LEVEL_5_0	= 14,
15538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LEVEL_5_1	= 15,
15548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
15558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_ALPHA	(V4L2_CID_MPEG_BASE+360)
15568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_BETA	(V4L2_CID_MPEG_BASE+361)
15578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_LOOP_FILTER_MODE	(V4L2_CID_MPEG_BASE+362)
15588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_video_h264_loop_filter_mode {
15598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_ENABLED				= 0,
15608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED				= 1,
15618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_LOOP_FILTER_MODE_DISABLED_AT_SLICE_BOUNDARY	= 2,
15628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
15638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_PROFILE		(V4L2_CID_MPEG_BASE+363)
15648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_video_h264_profile {
15658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_BASELINE			= 0,
15668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_BASELINE	= 1,
15678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_MAIN			= 2,
15688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_EXTENDED			= 3,
15698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_HIGH			= 4,
15708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_10			= 5,
15718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_422			= 6,
15728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_444_PREDICTIVE	= 7,
15738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_10_INTRA		= 8,
15748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_422_INTRA		= 9,
15758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_HIGH_444_INTRA		= 10,
15768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_CAVLC_444_INTRA		= 11,
15778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_BASELINE		= 12,
15788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_HIGH		= 13,
15798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_SCALABLE_HIGH_INTRA	= 14,
15808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_STEREO_HIGH		= 15,
15818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_MULTIVIEW_HIGH		= 16,
15828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_PROFILE_CONSTRAINED_HIGH		= 17,
15838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
15848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_HEIGHT	(V4L2_CID_MPEG_BASE+364)
15858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_VUI_EXT_SAR_WIDTH	(V4L2_CID_MPEG_BASE+365)
15868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_ENABLE		(V4L2_CID_MPEG_BASE+366)
15878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_H264_VUI_SAR_IDC		(V4L2_CID_MPEG_BASE+367)
15888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_video_h264_vui_sar_idc {
15898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_UNSPECIFIED	= 0,
15908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_1x1		= 1,
15918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_12x11		= 2,
15928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_10x11		= 3,
15938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_16x11		= 4,
15948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_40x33		= 5,
15958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_24x11		= 6,
15968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_20x11		= 7,
15978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_32x11		= 8,
15988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_80x33		= 9,
15998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_18x11		= 10,
16008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_15x11		= 11,
16018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_64x33		= 12,
16028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_160x99		= 13,
16038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_4x3		= 14,
16048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_3x2		= 15,
16058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_2x1		= 16,
16068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_H264_VUI_SAR_IDC_EXTENDED	= 17,
16078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
16088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_MPEG4_I_FRAME_QP	(V4L2_CID_MPEG_BASE+400)
16098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_MPEG4_P_FRAME_QP	(V4L2_CID_MPEG_BASE+401)
16108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_MPEG4_B_FRAME_QP	(V4L2_CID_MPEG_BASE+402)
16118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_MPEG4_MIN_QP	(V4L2_CID_MPEG_BASE+403)
16128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_MPEG4_MAX_QP	(V4L2_CID_MPEG_BASE+404)
16138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_MPEG4_LEVEL		(V4L2_CID_MPEG_BASE+405)
16148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_video_mpeg4_level {
16158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_MPEG4_LEVEL_0	= 0,
16168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_MPEG4_LEVEL_0B	= 1,
16178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_MPEG4_LEVEL_1	= 2,
16188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_MPEG4_LEVEL_2	= 3,
16198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_MPEG4_LEVEL_3	= 4,
16208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_MPEG4_LEVEL_3B	= 5,
16218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_MPEG4_LEVEL_4	= 6,
16228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_MPEG4_LEVEL_5	= 7,
16238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
16248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_MPEG4_PROFILE	(V4L2_CID_MPEG_BASE+406)
16258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_video_mpeg4_profile {
16268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE				= 0,
16278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_SIMPLE			= 1,
16288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_MPEG4_PROFILE_CORE				= 2,
16298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_MPEG4_PROFILE_SIMPLE_SCALABLE			= 3,
16308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDEO_MPEG4_PROFILE_ADVANCED_CODING_EFFICIENCY	= 4,
16318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
16328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_MPEG4_QPEL		(V4L2_CID_MPEG_BASE+407)
16338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_QCOM_VIDEO_SYNC_FRAME_SEQ_HDR		(V4L2_CID_MPEG_BASE+408)
16348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
16358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  MPEG-class control IDs specific to the CX2341x driver as defined by V4L2 */
16368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_CX2341X_BASE 				(V4L2_CTRL_CLASS_MPEG | 0x1000)
16378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE 	(V4L2_CID_MPEG_CX2341X_BASE+0)
16388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_cx2341x_video_spatial_filter_mode {
16398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_MANUAL = 0,
16408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE_AUTO   = 1,
16418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
16428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER 		(V4L2_CID_MPEG_CX2341X_BASE+1)
16438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE 	(V4L2_CID_MPEG_CX2341X_BASE+2)
16448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_cx2341x_video_luma_spatial_filter_type {
16458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_OFF                  = 0,
16468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_HOR               = 1,
16478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_1D_VERT              = 2,
16488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_HV_SEPARABLE      = 3,
16498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_CX2341X_VIDEO_LUMA_SPATIAL_FILTER_TYPE_2D_SYM_NON_SEPARABLE = 4,
16508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
16518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE 	(V4L2_CID_MPEG_CX2341X_BASE+3)
16528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_cx2341x_video_chroma_spatial_filter_type {
16538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_OFF    = 0,
16548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_CX2341X_VIDEO_CHROMA_SPATIAL_FILTER_TYPE_1D_HOR = 1,
16558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
16568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE 	(V4L2_CID_MPEG_CX2341X_BASE+4)
16578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_cx2341x_video_temporal_filter_mode {
16588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_MANUAL = 0,
16598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER_MODE_AUTO   = 1,
16608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
16618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_CX2341X_VIDEO_TEMPORAL_FILTER 		(V4L2_CID_MPEG_CX2341X_BASE+5)
16628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE 		(V4L2_CID_MPEG_CX2341X_BASE+6)
16638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_cx2341x_video_median_filter_type {
16648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_OFF      = 0,
16658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR      = 1,
16668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_VERT     = 2,
16678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_HOR_VERT = 3,
16688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_CX2341X_VIDEO_MEDIAN_FILTER_TYPE_DIAG     = 4,
16698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
16708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_BOTTOM 	(V4L2_CID_MPEG_CX2341X_BASE+7)
16718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_CX2341X_VIDEO_LUMA_MEDIAN_FILTER_TOP 	(V4L2_CID_MPEG_CX2341X_BASE+8)
16728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_BOTTOM	(V4L2_CID_MPEG_CX2341X_BASE+9)
16738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_CX2341X_VIDEO_CHROMA_MEDIAN_FILTER_TOP 	(V4L2_CID_MPEG_CX2341X_BASE+10)
16748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_CX2341X_STREAM_INSERT_NAV_PACKETS 	(V4L2_CID_MPEG_CX2341X_BASE+11)
16758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
16768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  MPEG-class control IDs specific to the Samsung MFC 5.1 driver as defined by V4L2 */
16778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_MFC51_BASE				(V4L2_CTRL_CLASS_MPEG | 0x1100)
16788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
16798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY		(V4L2_CID_MPEG_MFC51_BASE+0)
16808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_MFC51_VIDEO_DECODER_H264_DISPLAY_DELAY_ENABLE	(V4L2_CID_MPEG_MFC51_BASE+1)
16818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE			(V4L2_CID_MPEG_MFC51_BASE+2)
16828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_mfc51_video_frame_skip_mode {
16838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_DISABLED		= 0,
16848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_LEVEL_LIMIT	= 1,
16858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_MFC51_VIDEO_FRAME_SKIP_MODE_BUF_LIMIT		= 2,
16868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
16878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE			(V4L2_CID_MPEG_MFC51_BASE+3)
16888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_mfc51_video_force_frame_type {
16898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE_DISABLED		= 0,
16908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE_I_FRAME		= 1,
16918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_MFC51_VIDEO_FORCE_FRAME_TYPE_NOT_CODED	= 2,
16928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
16938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_MFC51_VIDEO_PADDING				(V4L2_CID_MPEG_MFC51_BASE+4)
16948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_MFC51_VIDEO_PADDING_YUV				(V4L2_CID_MPEG_MFC51_BASE+5)
16958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_MFC51_VIDEO_RC_FIXED_TARGET_BIT			(V4L2_CID_MPEG_MFC51_BASE+6)
16968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_MFC51_VIDEO_RC_REACTION_COEFF			(V4L2_CID_MPEG_MFC51_BASE+7)
16978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_ACTIVITY		(V4L2_CID_MPEG_MFC51_BASE+50)
16988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_DARK			(V4L2_CID_MPEG_MFC51_BASE+51)
16998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_SMOOTH		(V4L2_CID_MPEG_MFC51_BASE+52)
17008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_MFC51_VIDEO_H264_ADAPTIVE_RC_STATIC		(V4L2_CID_MPEG_MFC51_BASE+53)
17018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_MFC51_VIDEO_H264_NUM_REF_PIC_FOR_P		(V4L2_CID_MPEG_MFC51_BASE+54)
17028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
17038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  MPEG-class control IDs specific to the msm_vidc driver */
17048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_MSM_VIDC_BASE		(V4L2_CTRL_CLASS_MPEG | 0x2000)
17058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
17068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_ENABLE_PICTURE_TYPE \
17078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris			(V4L2_CID_MPEG_MSM_VIDC_BASE+0)
17088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_KEEP_ASPECT_RATIO \
17098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris			(V4L2_CID_MPEG_MSM_VIDC_BASE+1)
17108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_POST_LOOP_DEBLOCKER_MODE \
17118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris			(V4L2_CID_MPEG_MSM_VIDC_BASE+2)
17128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_DIVX_FORMAT \
17138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris			(V4L2_CID_MPEG_MSM_VIDC_BASE+3)
17148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_video_divx_format_type {
17158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_DIVX_FORMAT_4		= 0,
17168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_DIVX_FORMAT_5		= 1,
17178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_DIVX_FORMAT_6	    = 2,
17188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
17198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_MB_ERROR_MAP_REPORTING	\
17208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris			(V4L2_CID_MPEG_MSM_VIDC_BASE+4)
17218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_CONTINUE_DATA_TRANSFER \
17228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris			(V4L2_CID_MPEG_MSM_VIDC_BASE+5)
17238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
17248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_STREAM_FORMAT   (V4L2_CID_MPEG_MSM_VIDC_BASE+6)
17258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_video_stream_format {
17268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_NAL_FORMAT_STARTCODES         = 0,
17278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_NAL_FORMAT_ONE_NAL_PER_BUFFER = 1,
17288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_NAL_FORMAT_ONE_BYTE_LENGTH    = 2,
17298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_NAL_FORMAT_TWO_BYTE_LENGTH    = 3,
17308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_NAL_FORMAT_FOUR_BYTE_LENGTH   = 4,
17318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
17328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
17338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_OUTPUT_ORDER   (V4L2_CID_MPEG_MSM_VIDC_BASE+7)
17348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_video_output_order {
17358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_OUTPUT_ORDER_DISPLAY         = 0,
17368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_OUTPUT_ORDER_DECODE          = 1,
17378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
17388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
17398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_FRAME_RATE   (V4L2_CID_MPEG_MSM_VIDC_BASE+8)
17408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_IDR_PERIOD   (V4L2_CID_MPEG_MSM_VIDC_BASE+9)
17418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_NUM_P_FRAMES (V4L2_CID_MPEG_MSM_VIDC_BASE+10)
17428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_NUM_B_FRAMES (V4L2_CID_MPEG_MSM_VIDC_BASE+11)
17438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_REQUEST_IFRAME (V4L2_CID_MPEG_MSM_VIDC_BASE+12)
17448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
17458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL (V4L2_CID_MPEG_MSM_VIDC_BASE+13)
17468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_video_rate_control {
17478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_OFF = 0,
17488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_VBR_VFR = 1,
17498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_VBR_CFR = 2,
17508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_CBR_VFR = 3,
17518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_VIDEO_RATE_CONTROL_CBR_CFR = 4,
17528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
17538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
17548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_ROTATION (V4L2_CID_MPEG_MSM_VIDC_BASE+14)
17558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_video_rotation {
17568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_VIDEO_ROTATION_NONE = 0,
17578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_VIDEO_ROTATION_90 = 1,
17588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_VIDEO_ROTATION_180 = 2,
17598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_VIDEO_ROTATION_270 = 3,
17608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
17618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define MSM_VIDC_BASE V4L2_CID_MPEG_MSM_VIDC_BASE
17628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_H264_CABAC_MODEL (MSM_VIDC_BASE+15)
17638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_h264_cabac_model {
17648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_VIDEO_H264_CABAC_MODEL_0 = 0,
17658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_VIDEO_H264_CABAC_MODEL_1 = 1,
17668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_VIDEO_H264_CABAC_MODEL_2 = 2,
17678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
17688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
17698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_INTRA_REFRESH_MODE (MSM_VIDC_BASE+16)
17708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_video_intra_refresh_mode {
17718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_VIDEO_INTRA_REFRESH_NONE = 0,
17728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_VIDEO_INTRA_REFRESH_CYCLIC = 1,
17738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_VIDEO_INTRA_REFRESH_ADAPTIVE = 2,
17748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_VIDEO_INTRA_REFRESH_CYCLIC_ADAPTIVE = 3,
17758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_VIDEO_INTRA_REFRESH_RANDOM = 4,
17768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
17778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_AIR_MBS (V4L2_CID_MPEG_MSM_VIDC_BASE+17)
17788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_AIR_REF (V4L2_CID_MPEG_MSM_VIDC_BASE+18)
17798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_CIR_MBS (V4L2_CID_MPEG_MSM_VIDC_BASE+19)
17808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
17818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_H263_PROFILE (V4L2_CID_MPEG_MSM_VIDC_BASE+20)
17828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_video_h263_profile {
17838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H263_PROFILE_BASELINE = 0,
17848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H263_PROFILE_H320CODING	= 1,
17858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H263_PROFILE_BACKWARDCOMPATIBLE = 2,
17868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H263_PROFILE_ISWV2 = 3,
17878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H263_PROFILE_ISWV3 = 4,
17888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H263_PROFILE_HIGHCOMPRESSION = 5,
17898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H263_PROFILE_INTERNET = 6,
17908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H263_PROFILE_INTERLACE = 7,
17918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H263_PROFILE_HIGHLATENCY = 8,
17928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
17938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
17948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_H263_LEVEL (V4L2_CID_MPEG_MSM_VIDC_BASE+21)
17958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_video_h263_level {
17968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H263_LEVEL_1_0 = 0,
17978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H263_LEVEL_2_0 = 1,
17988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H263_LEVEL_3_0 = 2,
17998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H263_LEVEL_4_0 = 3,
18008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H263_LEVEL_4_5 = 4,
18018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H263_LEVEL_5_0 = 5,
18028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H263_LEVEL_6_0 = 6,
18038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H263_LEVEL_7_0 = 7,
18048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
18058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
18068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_H264_AU_DELIMITER \
18078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		(V4L2_CID_MPEG_MSM_VIDC_BASE + 22)
18088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_video_h264_au_delimiter {
18098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H264_AU_DELIMITER_DISABLED = 0,
18108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H264_AU_DELIMITER_ENABLED = 1
18118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
18128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_SYNC_FRAME_DECODE \
18138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		(V4L2_CID_MPEG_MSM_VIDC_BASE + 23)
18148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_video_sync_frame_decode {
18158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_SYNC_FRAME_DECODE_DISABLE = 0,
18168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_SYNC_FRAME_DECODE_ENABLE = 1
18178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
18188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_SECURE (V4L2_CID_MPEG_MSM_VIDC_BASE+24)
18198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_EXTRADATA \
18208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		(V4L2_CID_MPEG_MSM_VIDC_BASE + 25)
18218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_extradata {
18228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_EXTRADATA_NONE,
18238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_EXTRADATA_MB_QUANTIZATION,
18248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_EXTRADATA_INTERLACE_VIDEO,
18258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_EXTRADATA_VC1_FRAMEDISP,
18268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_EXTRADATA_VC1_SEQDISP,
18278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_EXTRADATA_TIMESTAMP,
18288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_EXTRADATA_S3D_FRAME_PACKING,
18298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_EXTRADATA_FRAME_RATE,
18308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_EXTRADATA_PANSCAN_WINDOW,
18318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_EXTRADATA_RECOVERY_POINT_SEI,
18328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_EXTRADATA_CLOSED_CAPTION_UD,
18338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_EXTRADATA_AFD_UD,
18348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_EXTRADATA_MULTISLICE_INFO,
18358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_EXTRADATA_NUM_CONCEALED_MB,
18368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_EXTRADATA_METADATA_FILLER,
18378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_INDEX_EXTRADATA_INPUT_CROP,
18388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_INDEX_EXTRADATA_DIGITAL_ZOOM,
18398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_INDEX_EXTRADATA_ASPECT_RATIO,
18408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_EXTRADATA_MPEG2_SEQDISP
18418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
18428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
18438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_SET_PERF_LEVEL (V4L2_CID_MPEG_MSM_VIDC_BASE + 26)
18448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_perf_level {
18458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_PERF_LEVEL_NOMINAL			= 0,
18468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_PERF_LEVEL_PERFORMANCE		= 1,
18478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_CID_MPEG_VIDC_PERF_LEVEL_TURBO			= 2,
18488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
18498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
18508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_MULTI_SLICE_GOB		\
18518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		(V4L2_CID_MPEG_MSM_VIDC_BASE + 27)
18528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
18538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDEO_MULTI_SLICE_DELIVERY_MODE	\
18548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	(V4L2_CID_MPEG_MSM_VIDC_BASE + 28)
18558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
18568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_H264_VUI_TIMING_INFO \
18578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		(V4L2_CID_MPEG_MSM_VIDC_BASE + 29)
18588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_video_h264_vui_timing_info {
18598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H264_VUI_TIMING_INFO_DISABLED = 0,
18608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H264_VUI_TIMING_INFO_ENABLED = 1
18618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
18628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
18638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_ALLOC_MODE_INPUT	\
18648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		(V4L2_CID_MPEG_MSM_VIDC_BASE + 30)
18658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_ALLOC_MODE_OUTPUT       \
18668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		(V4L2_CID_MPEG_MSM_VIDC_BASE + 31)
18678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_video_alloc_mode_type {
18688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_STATIC	= 0,
18698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_RING	= 1,
18708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_DYNAMIC	= 2,
18718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
18728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
18738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_FRAME_ASSEMBLY	\
18748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		(V4L2_CID_MPEG_MSM_VIDC_BASE + 32)
18758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_video_assembly {
18768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_FRAME_ASSEMBLY_DISABLE	= 0,
18778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_FRAME_ASSEMBLY_ENABLE	= 1,
18788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
18798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
18808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_VP8_PROFILE_LEVEL \
18818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		(V4L2_CID_MPEG_MSM_VIDC_BASE + 33)
18828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_video_vp8_profile_level {
18838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_VP8_UNUSED,
18848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_VP8_VERSION_0,
18858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_VP8_VERSION_1,
18868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_VP8_VERSION_2,
18878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_VP8_VERSION_3,
18888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
18898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
18908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_H264_VUI_BITSTREAM_RESTRICT \
18918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		(V4L2_CID_MPEG_MSM_VIDC_BASE + 34)
18928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_video_h264_vui_bitstream_restrict {
18938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H264_VUI_BITSTREAM_RESTRICT_DISABLED = 0,
18948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_H264_VUI_BITSTREAM_RESTRICT_ENABLED = 1
18958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
18968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
18978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_PRESERVE_TEXT_QUALITY \
18988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		(V4L2_CID_MPEG_MSM_VIDC_BASE + 35)
18998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_mpeg_vidc_video_preserve_text_quality {
19008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_PRESERVE_TEXT_QUALITY_DISABLED = 0,
19018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_MPEG_VIDC_VIDEO_PRESERVE_TEXT_QUALITY_ENABLED = 1
19028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
19038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_MPEG_VIDC_VIDEO_REQUEST_SEQ_HEADER \
19058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	(V4L2_CID_MPEG_MSM_VIDC_BASE + 36)
19068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Camera class control IDs */
19088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_CAMERA_CLASS_BASE 	(V4L2_CTRL_CLASS_CAMERA | 0x900)
19098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_CAMERA_CLASS 		(V4L2_CTRL_CLASS_CAMERA | 1)
19108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_EXPOSURE_AUTO			(V4L2_CID_CAMERA_CLASS_BASE+1)
19128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum  v4l2_exposure_auto_type {
19138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_EXPOSURE_AUTO = 0,
19148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_EXPOSURE_MANUAL = 1,
19158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_EXPOSURE_SHUTTER_PRIORITY = 2,
19168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_EXPOSURE_APERTURE_PRIORITY = 3
19178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
19188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_EXPOSURE_ABSOLUTE		(V4L2_CID_CAMERA_CLASS_BASE+2)
19198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_EXPOSURE_AUTO_PRIORITY		(V4L2_CID_CAMERA_CLASS_BASE+3)
19208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_PAN_RELATIVE			(V4L2_CID_CAMERA_CLASS_BASE+4)
19228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_TILT_RELATIVE			(V4L2_CID_CAMERA_CLASS_BASE+5)
19238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_PAN_RESET			(V4L2_CID_CAMERA_CLASS_BASE+6)
19248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_TILT_RESET			(V4L2_CID_CAMERA_CLASS_BASE+7)
19258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_PAN_ABSOLUTE			(V4L2_CID_CAMERA_CLASS_BASE+8)
19278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_TILT_ABSOLUTE			(V4L2_CID_CAMERA_CLASS_BASE+9)
19288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FOCUS_ABSOLUTE			(V4L2_CID_CAMERA_CLASS_BASE+10)
19308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FOCUS_RELATIVE			(V4L2_CID_CAMERA_CLASS_BASE+11)
19318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FOCUS_AUTO			(V4L2_CID_CAMERA_CLASS_BASE+12)
19328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_ZOOM_ABSOLUTE			(V4L2_CID_CAMERA_CLASS_BASE+13)
19348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_ZOOM_RELATIVE			(V4L2_CID_CAMERA_CLASS_BASE+14)
19358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_ZOOM_CONTINUOUS		(V4L2_CID_CAMERA_CLASS_BASE+15)
19368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_PRIVACY			(V4L2_CID_CAMERA_CLASS_BASE+16)
19388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_IRIS_ABSOLUTE			(V4L2_CID_CAMERA_CLASS_BASE+17)
19408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_IRIS_RELATIVE			(V4L2_CID_CAMERA_CLASS_BASE+18)
19418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* FM Modulator class control IDs */
19438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FM_TX_CLASS_BASE		(V4L2_CTRL_CLASS_FM_TX | 0x900)
19448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FM_TX_CLASS			(V4L2_CTRL_CLASS_FM_TX | 1)
19458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_RDS_TX_DEVIATION		(V4L2_CID_FM_TX_CLASS_BASE + 1)
19478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_RDS_TX_PI			(V4L2_CID_FM_TX_CLASS_BASE + 2)
19488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_RDS_TX_PTY			(V4L2_CID_FM_TX_CLASS_BASE + 3)
19498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_RDS_TX_PS_NAME			(V4L2_CID_FM_TX_CLASS_BASE + 5)
19508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_RDS_TX_RADIO_TEXT		(V4L2_CID_FM_TX_CLASS_BASE + 6)
19518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_AUDIO_LIMITER_ENABLED		(V4L2_CID_FM_TX_CLASS_BASE + 64)
19538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_AUDIO_LIMITER_RELEASE_TIME	(V4L2_CID_FM_TX_CLASS_BASE + 65)
19548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_AUDIO_LIMITER_DEVIATION	(V4L2_CID_FM_TX_CLASS_BASE + 66)
19558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_AUDIO_COMPRESSION_ENABLED	(V4L2_CID_FM_TX_CLASS_BASE + 80)
19578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_AUDIO_COMPRESSION_GAIN		(V4L2_CID_FM_TX_CLASS_BASE + 81)
19588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_AUDIO_COMPRESSION_THRESHOLD	(V4L2_CID_FM_TX_CLASS_BASE + 82)
19598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_AUDIO_COMPRESSION_ATTACK_TIME	(V4L2_CID_FM_TX_CLASS_BASE + 83)
19608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_AUDIO_COMPRESSION_RELEASE_TIME	(V4L2_CID_FM_TX_CLASS_BASE + 84)
19618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_PILOT_TONE_ENABLED		(V4L2_CID_FM_TX_CLASS_BASE + 96)
19638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_PILOT_TONE_DEVIATION		(V4L2_CID_FM_TX_CLASS_BASE + 97)
19648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_PILOT_TONE_FREQUENCY		(V4L2_CID_FM_TX_CLASS_BASE + 98)
19658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_TUNE_PREEMPHASIS		(V4L2_CID_FM_TX_CLASS_BASE + 112)
19678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_preemphasis {
19688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_PREEMPHASIS_DISABLED	= 0,
19698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_PREEMPHASIS_50_uS		= 1,
19708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_PREEMPHASIS_75_uS		= 2,
19718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
19728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_TUNE_POWER_LEVEL		(V4L2_CID_FM_TX_CLASS_BASE + 113)
19738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_TUNE_ANTENNA_CAPACITOR		(V4L2_CID_FM_TX_CLASS_BASE + 114)
19748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Flash and privacy (indicator) light controls */
19768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FLASH_CLASS_BASE		(V4L2_CTRL_CLASS_FLASH | 0x900)
19778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FLASH_CLASS			(V4L2_CTRL_CLASS_FLASH | 1)
19788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FLASH_LED_MODE			(V4L2_CID_FLASH_CLASS_BASE + 1)
19808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_flash_led_mode {
19818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FLASH_LED_MODE_NONE,
19828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FLASH_LED_MODE_FLASH,
19838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FLASH_LED_MODE_TORCH,
19848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
19858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FLASH_STROBE_SOURCE		(V4L2_CID_FLASH_CLASS_BASE + 2)
19878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_flash_strobe_source {
19888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FLASH_STROBE_SOURCE_SOFTWARE,
19898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_FLASH_STROBE_SOURCE_EXTERNAL,
19908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
19918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FLASH_STROBE			(V4L2_CID_FLASH_CLASS_BASE + 3)
19938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FLASH_STROBE_STOP		(V4L2_CID_FLASH_CLASS_BASE + 4)
19948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FLASH_STROBE_STATUS		(V4L2_CID_FLASH_CLASS_BASE + 5)
19958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
19968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FLASH_TIMEOUT			(V4L2_CID_FLASH_CLASS_BASE + 6)
19978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FLASH_INTENSITY		(V4L2_CID_FLASH_CLASS_BASE + 7)
19988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FLASH_TORCH_INTENSITY		(V4L2_CID_FLASH_CLASS_BASE + 8)
19998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FLASH_INDICATOR_INTENSITY	(V4L2_CID_FLASH_CLASS_BASE + 9)
20008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
20018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FLASH_FAULT			(V4L2_CID_FLASH_CLASS_BASE + 10)
20028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FLASH_FAULT_OVER_VOLTAGE		(1 << 0)
20038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FLASH_FAULT_TIMEOUT		(1 << 1)
20048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FLASH_FAULT_OVER_TEMPERATURE	(1 << 2)
20058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FLASH_FAULT_SHORT_CIRCUIT		(1 << 3)
20068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FLASH_FAULT_OVER_CURRENT		(1 << 4)
20078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_FLASH_FAULT_INDICATOR		(1 << 5)
20088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
20098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FLASH_CHARGE			(V4L2_CID_FLASH_CLASS_BASE + 11)
20108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_FLASH_READY			(V4L2_CID_FLASH_CLASS_BASE + 12)
20118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
20128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  JPEG-class control IDs defined by V4L2 */
20138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_JPEG_CLASS_BASE		(V4L2_CTRL_CLASS_JPEG | 0x900)
20148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CID_JPEG_CLASS			(V4L2_CTRL_CLASS_JPEG | 1)
20158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
20168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	V4L2_CID_JPEG_CHROMA_SUBSAMPLING	(V4L2_CID_JPEG_CLASS_BASE + 1)
20178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisenum v4l2_jpeg_chroma_subsampling {
20188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_JPEG_CHROMA_SUBSAMPLING_444	= 0,
20198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_JPEG_CHROMA_SUBSAMPLING_422	= 1,
20208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_JPEG_CHROMA_SUBSAMPLING_420	= 2,
20218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_JPEG_CHROMA_SUBSAMPLING_411	= 3,
20228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_JPEG_CHROMA_SUBSAMPLING_410	= 4,
20238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	V4L2_JPEG_CHROMA_SUBSAMPLING_GRAY	= 5,
20248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
20258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	V4L2_CID_JPEG_RESTART_INTERVAL		(V4L2_CID_JPEG_CLASS_BASE + 2)
20268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	V4L2_CID_JPEG_COMPRESSION_QUALITY	(V4L2_CID_JPEG_CLASS_BASE + 3)
20278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
20288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	V4L2_CID_JPEG_ACTIVE_MARKER		(V4L2_CID_JPEG_CLASS_BASE + 4)
20298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	V4L2_JPEG_ACTIVE_MARKER_APP0		(1 << 0)
20308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	V4L2_JPEG_ACTIVE_MARKER_APP1		(1 << 1)
20318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	V4L2_JPEG_ACTIVE_MARKER_COM		(1 << 16)
20328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	V4L2_JPEG_ACTIVE_MARKER_DQT		(1 << 17)
20338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	V4L2_JPEG_ACTIVE_MARKER_DHT		(1 << 18)
20348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
20358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
20368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	T U N I N G
20378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
20388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_tuner {
20398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32                   index;
20408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8			name[32];
20418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_tuner_type    type;
20428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			capability;
20438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			rangelow;
20448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			rangehigh;
20458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			rxsubchans;
20468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			audmode;
20478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__s32			signal;
20488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__s32			afc;
20498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			reserved[4];
20508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
20518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
20528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_modulator {
20538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			index;
20548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8			name[32];
20558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			capability;
20568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			rangelow;
20578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			rangehigh;
20588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			txsubchans;
20598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			reserved[4];
20608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
20618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
20628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Flags for the 'capability' field */
20638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_CAP_LOW		0x0001
20648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_CAP_NORM		0x0002
20658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_CAP_STEREO		0x0010
20668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_CAP_LANG2		0x0020
20678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_CAP_SAP		0x0020
20688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_CAP_LANG1		0x0040
20698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_CAP_RDS		0x0080
20708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_CAP_RDS_BLOCK_IO	0x0100
20718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_CAP_RDS_CONTROLS	0x0200
20728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
20738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Flags for the 'rxsubchans' field */
20748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_SUB_MONO		0x0001
20758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_SUB_STEREO		0x0002
20768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_SUB_LANG2		0x0004
20778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_SUB_SAP		0x0004
20788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_SUB_LANG1		0x0008
20798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_SUB_RDS		0x0010
20808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
20818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Values for the 'audmode' field */
20828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_MODE_MONO		0x0000
20838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_MODE_STEREO		0x0001
20848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_MODE_LANG2		0x0002
20858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_MODE_SAP		0x0002
20868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_MODE_LANG1		0x0003
20878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_TUNER_MODE_LANG1_LANG2	0x0004
20888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
20898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_frequency {
20908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		      tuner;
20918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_tuner_type  type;
20928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		      frequency;
20938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		      reserved[8];
20948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
20958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
20968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_hw_freq_seek {
20978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		      tuner;
20988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_tuner_type  type;
20998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		      seek_upward;
21008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		      wrap_around;
21018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		      spacing;
21028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		      reserved[7];
21038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
21048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
21058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
21068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	R D S
21078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
21088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
21098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_rds_data {
21108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8 	lsb;
21118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8 	msb;
21128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8 	block;
21138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris} __attribute__ ((packed));
21148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
21158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_RDS_BLOCK_MSK 	 0x7
21168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_RDS_BLOCK_A 	 0
21178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_RDS_BLOCK_B 	 1
21188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_RDS_BLOCK_C 	 2
21198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_RDS_BLOCK_D 	 3
21208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_RDS_BLOCK_C_ALT 	 4
21218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_RDS_BLOCK_INVALID 	 7
21228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
21238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_RDS_BLOCK_CORRECTED 0x40
21248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_RDS_BLOCK_ERROR 	 0x80
21258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
21268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
21278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	A U D I O
21288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
21298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_audio {
21308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	index;
21318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8	name[32];
21328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	capability;
21338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	mode;
21348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	reserved[2];
21358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
21368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
21378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Flags for the 'capability' field */
21388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_AUDCAP_STEREO		0x00001
21398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_AUDCAP_AVL			0x00002
21408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
21418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  Flags for the 'mode' field */
21428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_AUDMODE_AVL		0x00001
21438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
21448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_audioout {
21458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	index;
21468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8	name[32];
21478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	capability;
21488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	mode;
21498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	reserved[2];
21508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
21518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
21528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
21538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	M P E G   S E R V I C E S
21548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
21558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	NOTE: EXPERIMENTAL API
21568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
21578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#if 1
21588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_ENC_IDX_FRAME_I    (0)
21598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_ENC_IDX_FRAME_P    (1)
21608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_ENC_IDX_FRAME_B    (2)
21618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_ENC_IDX_FRAME_MASK (0xf)
21628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
21638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_enc_idx_entry {
21648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u64 offset;
21658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u64 pts;
21668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 length;
21678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 flags;
21688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 reserved[2];
21698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
21708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
21718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_ENC_IDX_ENTRIES (64)
21728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_enc_idx {
21738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 entries;
21748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 entries_cap;
21758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 reserved[4];
21768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_enc_idx_entry entry[V4L2_ENC_IDX_ENTRIES];
21778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
21788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
21798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
21808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_ENC_CMD_START      (0)
21818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_ENC_CMD_STOP       (1)
21828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_ENC_CMD_PAUSE      (2)
21838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_ENC_CMD_RESUME     (3)
21848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_ENC_QCOM_CMD_FLUSH  (4)
21858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
21868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Flags for V4L2_ENC_CMD_STOP */
21878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_ENC_CMD_STOP_AT_GOP_END    (1 << 0)
21888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
21898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_encoder_cmd {
21908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 cmd;
21918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 flags;
21928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	union {
21938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct {
21948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris			__u32 data[8];
21958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		} raw;
21968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	};
21978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
21988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
21998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Decoder commands */
22008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_DEC_CMD_START       (0)
22018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_DEC_CMD_STOP        (1)
22028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_DEC_CMD_PAUSE       (2)
22038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_DEC_CMD_RESUME      (3)
22048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_DEC_QCOM_CMD_FLUSH  (4)
22058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
22068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Flags for V4L2_DEC_CMD_START */
22078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_DEC_CMD_START_MUTE_AUDIO	(1 << 0)
22088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
22098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Flags for V4L2_DEC_CMD_PAUSE */
22108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_DEC_CMD_PAUSE_TO_BLACK	(1 << 0)
22118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
22128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Flags for V4L2_DEC_CMD_STOP */
22138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_DEC_CMD_STOP_TO_BLACK	(1 << 0)
22148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_DEC_CMD_STOP_IMMEDIATELY	(1 << 1)
22158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
22168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Flags for V4L2_DEC_QCOM_CMD_FLUSH */
22178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_DEC_QCOM_CMD_FLUSH_OUTPUT  (1 << 0)
22188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_DEC_QCOM_CMD_FLUSH_CAPTURE (1 << 1)
22198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
22208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_QCOM_CMD_FLUSH_OUTPUT  (1 << 0)
22218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_QCOM_CMD_FLUSH_CAPTURE (1 << 1)
22228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
22238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Play format requirements (returned by the driver): */
22248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
22258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* The decoder has no special format requirements */
22268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_DEC_START_FMT_NONE		(0)
22278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* The decoder requires full GOPs */
22288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_DEC_START_FMT_GOP		(1)
22298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
22308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* The structure must be zeroed before use by the application
22318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris   This ensures it can be extended safely in the future. */
22328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_decoder_cmd {
22338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 cmd;
22348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 flags;
22358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	union {
22368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct {
22378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris			__u64 pts;
22388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		} stop;
22398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
22408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct {
22418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris			/* 0 or 1000 specifies normal speed,
22428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris			   1 specifies forward single stepping,
22438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris			   -1 specifies backward single stepping,
22448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris			   >1: playback at speed/1000 of the normal speed,
22458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris			   <-1: reverse playback at (-speed/1000) of the normal speed. */
22468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris			__s32 speed;
22478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris			__u32 format;
22488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		} start;
22498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
22508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct {
22518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris			__u32 data[16];
22528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		} raw;
22538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	};
22548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
22558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#endif
22568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
22578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
22588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
22598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	D A T A   S E R V I C E S   ( V B I )
22608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
22618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	Data services API by Michael Schimek
22628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
22638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
22648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Raw VBI */
22658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_vbi_format {
22668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	sampling_rate;		/* in 1 Hz */
22678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	offset;
22688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	samples_per_line;
22698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	sample_format;		/* V4L2_PIX_FMT_* */
22708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__s32	start[2];
22718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	count[2];
22728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	flags;			/* V4L2_VBI_* */
22738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32	reserved[2];		/* must be zero */
22748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
22758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
22768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*  VBI flags  */
22778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_VBI_UNSYNC		(1 << 0)
22788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_VBI_INTERLACED	(1 << 1)
22798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
22808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Sliced VBI
22818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
22828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *    This implements is a proposal V4L2 API to allow SLICED VBI
22838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * required for some hardware encoders. It should change without
22848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * notice in the definitive implementation.
22858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
22868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
22878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_sliced_vbi_format {
22888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u16   service_set;
22898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	/* service_lines[0][...] specifies lines 0-23 (1-23 used) of the first field
22908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	   service_lines[1][...] specifies lines 0-23 (1-23 used) of the second field
22918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 (equals frame lines 313-336 for 625 line video
22928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				  standards, 263-286 for 525 line standards) */
22938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u16   service_lines[2][24];
22948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32   io_size;
22958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32   reserved[2];            /* must be zero */
22968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
22978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
22988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Teletext World System Teletext
22998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris   (WST), defined on ITU-R BT.653-2 */
23008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_SLICED_TELETEXT_B          (0x0001)
23018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Video Program System, defined on ETS 300 231*/
23028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_SLICED_VPS                 (0x0400)
23038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Closed Caption, defined on EIA-608 */
23048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_SLICED_CAPTION_525         (0x1000)
23058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Wide Screen System, defined on ITU-R BT1119.1 */
23068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_SLICED_WSS_625             (0x4000)
23078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
23088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_SLICED_VBI_525             (V4L2_SLICED_CAPTION_525)
23098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_SLICED_VBI_625             (V4L2_SLICED_TELETEXT_B | V4L2_SLICED_VPS | V4L2_SLICED_WSS_625)
23108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
23118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_sliced_vbi_cap {
23128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u16   service_set;
23138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	/* service_lines[0][...] specifies lines 0-23 (1-23 used) of the first field
23148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	   service_lines[1][...] specifies lines 0-23 (1-23 used) of the second field
23158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				 (equals frame lines 313-336 for 625 line video
23168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris				  standards, 263-286 for 525 line standards) */
23178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u16   service_lines[2][24];
23188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_buf_type type;
23198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32   reserved[3];    /* must be 0 */
23208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
23218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
23228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_sliced_vbi_data {
23238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32   id;
23248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32   field;          /* 0: first field, 1: second field */
23258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32   line;           /* 1-23 */
23268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32   reserved;       /* must be 0 */
23278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8    data[48];
23288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
23298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
23308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
23318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * Sliced VBI data inserted into MPEG Streams
23328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
23338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
23348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
23358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * V4L2_MPEG_STREAM_VBI_FMT_IVTV:
23368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
23378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * Structure of payload contained in an MPEG 2 Private Stream 1 PES Packet in an
23388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * MPEG-2 Program Pack that contains V4L2_MPEG_STREAM_VBI_FMT_IVTV Sliced VBI
23398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * data
23408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
23418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * Note, the MPEG-2 Program Pack and Private Stream 1 PES packet header
23428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * definitions are not included here.  See the MPEG-2 specifications for details
23438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * on these headers.
23448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
23458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
23468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Line type IDs */
23478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_MPEG_VBI_IVTV_TELETEXT_B     (1)
23488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_MPEG_VBI_IVTV_CAPTION_525    (4)
23498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_MPEG_VBI_IVTV_WSS_625        (5)
23508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_MPEG_VBI_IVTV_VPS            (7)
23518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
23528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_mpeg_vbi_itv0_line {
23538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8 id;	/* One of V4L2_MPEG_VBI_IVTV_* above */
23548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8 data[42];	/* Sliced VBI data for the line */
23558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris} __attribute__ ((packed));
23568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
23578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_mpeg_vbi_itv0 {
23588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__le32 linemask[2]; /* Bitmasks of VBI service lines present */
23598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_mpeg_vbi_itv0_line line[35];
23608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris} __attribute__ ((packed));
23618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
23628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_mpeg_vbi_ITV0 {
23638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_mpeg_vbi_itv0_line line[36];
23648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris} __attribute__ ((packed));
23658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
23668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_MPEG_VBI_IVTV_MAGIC0	"itv0"
23678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_MPEG_VBI_IVTV_MAGIC1	"ITV0"
23688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
23698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_mpeg_vbi_fmt_ivtv {
23708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8 magic[4];
23718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	union {
23728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_mpeg_vbi_itv0 itv0;
23738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_mpeg_vbi_ITV0 ITV0;
23748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	};
23758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris} __attribute__ ((packed));
23768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
23778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
23788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	A G G R E G A T E   S T R U C T U R E S
23798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
23808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
23818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/**
23828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * struct v4l2_plane_pix_format - additional, per-plane format definition
23838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @sizeimage:		maximum size in bytes required for data, for which
23848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *			this plane will be used
23858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @bytesperline:	distance in bytes between the leftmost pixels in two
23868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *			adjacent lines
23878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
23888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_plane_pix_format {
23898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32		sizeimage;
23908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u16		bytesperline;
23918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u16		reserved[7];
23928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris} __attribute__ ((packed));
23938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
23948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/**
23958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * struct v4l2_pix_format_mplane - multiplanar format definition
23968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @width:		image width in pixels
23978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @height:		image height in pixels
23988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @pixelformat:	little endian four character code (fourcc)
23998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @field:		field order (for interlaced video)
24008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @colorspace:		supplemental to pixelformat
24018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @plane_fmt:		per-plane information
24028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @num_planes:		number of planes for this format
24038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
24048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_pix_format_mplane {
24058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32				width;
24068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32				height;
24078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32				pixelformat;
24088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_field			field;
24098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_colorspace		colorspace;
24108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
24118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_plane_pix_format	plane_fmt[VIDEO_MAX_PLANES];
24128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8				num_planes;
24138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8				reserved[11];
24148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris} __attribute__ ((packed));
24158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
24168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/**
24178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * struct v4l2_format - stream data format
24188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @type:	type of the data stream
24198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @pix:	definition of an image format
24208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @pix_mp:	definition of a multiplanar image format
24218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @win:	definition of an overlaid image
24228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @vbi:	raw VBI capture or output parameters
24238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @sliced:	sliced VBI capture or output parameters
24248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @raw_data:	placeholder for future extensions and custom formats
24258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
24268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_format {
24278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_buf_type type;
24288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	union {
24298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_pix_format		pix;     /* V4L2_BUF_TYPE_VIDEO_CAPTURE */
24308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_pix_format_mplane	pix_mp;  /* V4L2_BUF_TYPE_VIDEO_CAPTURE_MPLANE */
24318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_window		win;     /* V4L2_BUF_TYPE_VIDEO_OVERLAY */
24328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_vbi_format		vbi;     /* V4L2_BUF_TYPE_VBI_CAPTURE */
24338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_sliced_vbi_format	sliced;  /* V4L2_BUF_TYPE_SLICED_VBI_CAPTURE */
24348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		__u8	raw_data[200];                   /* user-defined */
24358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	} fmt;
24368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
24378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
24388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*	Stream type-dependent parameters
24398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
24408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_streamparm {
24418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_buf_type type;
24428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	union {
24438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_captureparm	capture;
24448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_outputparm	output;
24458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		__u8	raw_data[200];  /* user-defined */
24468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	} parm;
24478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
24488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
24498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
24508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	E V E N T S
24518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
24528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
24538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_ALL				0
24548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_VSYNC			1
24558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_EOS				2
24568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_CTRL				3
24578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_FRAME_SYNC			4
24588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_PRIVATE_START		0x08000000
24598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
24608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_MSM_VIDC_START	(V4L2_EVENT_PRIVATE_START + 0x00001000)
24618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_MSM_VIDC_FLUSH_DONE	(V4L2_EVENT_MSM_VIDC_START + 1)
24628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_MSM_VIDC_PORT_SETTINGS_CHANGED_SUFFICIENT	\
24638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		(V4L2_EVENT_MSM_VIDC_START + 2)
24648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_MSM_VIDC_PORT_SETTINGS_CHANGED_INSUFFICIENT	\
24658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		(V4L2_EVENT_MSM_VIDC_START + 3)
24668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_MSM_VIDC_CLOSE_DONE	(V4L2_EVENT_MSM_VIDC_START + 4)
24678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_MSM_VIDC_SYS_ERROR	(V4L2_EVENT_MSM_VIDC_START + 5)
24688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_MSM_VIDC_RELEASE_BUFFER_REFERENCE \
24698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		(V4L2_EVENT_MSM_VIDC_START + 6)
24708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_MSM_VIDC_RELEASE_UNQUEUED_BUFFER \
24718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		(V4L2_EVENT_MSM_VIDC_START + 7)
24728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
24738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Payload for V4L2_EVENT_VSYNC */
24748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_event_vsync {
24758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	/* Can be V4L2_FIELD_ANY, _NONE, _TOP or _BOTTOM */
24768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u8 field;
24778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris} __attribute__ ((packed));
24788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
24798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Payload for V4L2_EVENT_CTRL */
24808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_CTRL_CH_VALUE		(1 << 0)
24818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_CTRL_CH_FLAGS		(1 << 1)
24828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
24838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_event_ctrl {
24848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 changes;
24858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 type;
24868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	union {
24878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		__s32 value;
24888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		__s64 value64;
24898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	};
24908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 flags;
24918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__s32 minimum;
24928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__s32 maximum;
24938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__s32 step;
24948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__s32 default_value;
24958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
24968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
24978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_event_frame_sync {
24988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 frame_sequence;
24998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
25008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
25018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_event {
25028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32				type;
25038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	union {
25048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_event_vsync		vsync;
25058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_event_ctrl		ctrl;
25068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		struct v4l2_event_frame_sync	frame_sync;
25078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		__u8				data[64];
25088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	} u;
25098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32				pending;
25108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32				sequence;
25118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct timespec			timestamp;
25128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32				id;
25138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32				reserved[8];
25148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
25158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
25168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_SUB_FL_SEND_INITIAL		(1 << 0)
25178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_EVENT_SUB_FL_ALLOW_FEEDBACK	(1 << 1)
25188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
25198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_event_subscription {
25208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32				type;
25218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32				id;
25228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32				flags;
25238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32				reserved[5];
25248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
25258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
25268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
25278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	A D V A N C E D   D E B U G G I N G
25288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
25298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	NOTE: EXPERIMENTAL API, NEVER RELY ON THIS IN APPLICATIONS!
25308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	FOR DEBUGGING, TESTING AND INTERNAL USE ONLY!
25318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
25328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
25338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* VIDIOC_DBG_G_REGISTER and VIDIOC_DBG_S_REGISTER */
25348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
25358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CHIP_MATCH_HOST       0  /* Match against chip ID on host (0 for the host) */
25368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CHIP_MATCH_I2C_DRIVER 1  /* Match against I2C driver name */
25378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CHIP_MATCH_I2C_ADDR   2  /* Match against I2C 7-bit address */
25388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define V4L2_CHIP_MATCH_AC97       3  /* Match against anciliary AC97 chip */
25398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
25408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_dbg_match {
25418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 type; /* Match type */
25428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	union {     /* Match this chip, meaning determined by type */
25438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		__u32 addr;
25448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris		char name[32];
25458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	};
25468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris} __attribute__ ((packed));
25478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
25488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_dbg_register {
25498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_dbg_match match;
25508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 size;	/* register size in bytes */
25518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u64 reg;
25528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u64 val;
25538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris} __attribute__ ((packed));
25548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
25558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* VIDIOC_DBG_G_CHIP_IDENT */
25568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_dbg_chip_ident {
25578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_dbg_match match;
25588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 ident;       /* chip identifier as specified in <media/v4l2-chip-ident.h> */
25598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32 revision;    /* chip revision, chip specific */
25608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris} __attribute__ ((packed));
25618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
25628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/**
25638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * struct v4l2_create_buffers - VIDIOC_CREATE_BUFS argument
25648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @index:	on return, index of the first created buffer
25658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @count:	entry: number of requested buffers,
25668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *		return: number of created buffers
25678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @memory:	buffer memory type
25688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @format:	frame format, for which buffers are requested
25698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris * @reserved:	future extensions
25708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
25718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferrisstruct v4l2_create_buffers {
25728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			index;
25738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			count;
25748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	enum v4l2_memory        memory;
25758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	struct v4l2_format	format;
25768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris	__u32			reserved[8];
25778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris};
25788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
25798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/*
25808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *	I O C T L   C O D E S   F O R   V I D E O   D E V I C E S
25818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris *
25828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris */
25838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_QUERYCAP		 _IOR('V',  0, struct v4l2_capability)
25848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_RESERVED		  _IO('V',  1)
25858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_ENUM_FMT         _IOWR('V',  2, struct v4l2_fmtdesc)
25868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_FMT		_IOWR('V',  4, struct v4l2_format)
25878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_FMT		_IOWR('V',  5, struct v4l2_format)
25888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_REQBUFS		_IOWR('V',  8, struct v4l2_requestbuffers)
25898c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_QUERYBUF		_IOWR('V',  9, struct v4l2_buffer)
25908c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_FBUF		 _IOR('V', 10, struct v4l2_framebuffer)
25918c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_FBUF		 _IOW('V', 11, struct v4l2_framebuffer)
25928c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_OVERLAY		 _IOW('V', 14, int)
25938c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_QBUF		_IOWR('V', 15, struct v4l2_buffer)
25948c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_DQBUF		_IOWR('V', 17, struct v4l2_buffer)
25958c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_STREAMON		 _IOW('V', 18, int)
25968c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_STREAMOFF	 _IOW('V', 19, int)
25978c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_PARM		_IOWR('V', 21, struct v4l2_streamparm)
25988c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_PARM		_IOWR('V', 22, struct v4l2_streamparm)
25998c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_STD		 _IOR('V', 23, v4l2_std_id)
26008c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_STD		 _IOW('V', 24, v4l2_std_id)
26018c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_ENUMSTD		_IOWR('V', 25, struct v4l2_standard)
26028c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_ENUMINPUT	_IOWR('V', 26, struct v4l2_input)
26038c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_CTRL		_IOWR('V', 27, struct v4l2_control)
26048c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_CTRL		_IOWR('V', 28, struct v4l2_control)
26058c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_TUNER		_IOWR('V', 29, struct v4l2_tuner)
26068c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_TUNER		 _IOW('V', 30, struct v4l2_tuner)
26078c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_AUDIO		 _IOR('V', 33, struct v4l2_audio)
26088c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_AUDIO		 _IOW('V', 34, struct v4l2_audio)
26098c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_QUERYCTRL	_IOWR('V', 36, struct v4l2_queryctrl)
26108c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_QUERYMENU	_IOWR('V', 37, struct v4l2_querymenu)
26118c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_INPUT		 _IOR('V', 38, int)
26128c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_INPUT		_IOWR('V', 39, int)
26138c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_OUTPUT		 _IOR('V', 46, int)
26148c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_OUTPUT		_IOWR('V', 47, int)
26158c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_ENUMOUTPUT	_IOWR('V', 48, struct v4l2_output)
26168c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_AUDOUT		 _IOR('V', 49, struct v4l2_audioout)
26178c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_AUDOUT		 _IOW('V', 50, struct v4l2_audioout)
26188c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_MODULATOR	_IOWR('V', 54, struct v4l2_modulator)
26198c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_MODULATOR	 _IOW('V', 55, struct v4l2_modulator)
26208c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_FREQUENCY	_IOWR('V', 56, struct v4l2_frequency)
26218c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_FREQUENCY	 _IOW('V', 57, struct v4l2_frequency)
26228c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_CROPCAP		_IOWR('V', 58, struct v4l2_cropcap)
26238c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_CROP		_IOWR('V', 59, struct v4l2_crop)
26248c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_CROP		 _IOW('V', 60, struct v4l2_crop)
26258c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_JPEGCOMP	 _IOR('V', 61, struct v4l2_jpegcompression)
26268c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_JPEGCOMP	 _IOW('V', 62, struct v4l2_jpegcompression)
26278c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_QUERYSTD      	 _IOR('V', 63, v4l2_std_id)
26288c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_TRY_FMT      	_IOWR('V', 64, struct v4l2_format)
26298c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_ENUMAUDIO	_IOWR('V', 65, struct v4l2_audio)
26308c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_ENUMAUDOUT	_IOWR('V', 66, struct v4l2_audioout)
26318c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_PRIORITY        _IOR('V', 67, enum v4l2_priority)
26328c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_PRIORITY        _IOW('V', 68, enum v4l2_priority)
26338c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_SLICED_VBI_CAP _IOWR('V', 69, struct v4l2_sliced_vbi_cap)
26348c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_LOG_STATUS         _IO('V', 70)
26358c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_EXT_CTRLS	_IOWR('V', 71, struct v4l2_ext_controls)
26368c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_EXT_CTRLS	_IOWR('V', 72, struct v4l2_ext_controls)
26378c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_TRY_EXT_CTRLS	_IOWR('V', 73, struct v4l2_ext_controls)
26388c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#if 1
26398c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_ENUM_FRAMESIZES	_IOWR('V', 74, struct v4l2_frmsizeenum)
26408c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_ENUM_FRAMEINTERVALS _IOWR('V', 75, struct v4l2_frmivalenum)
26418c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_ENC_INDEX       _IOR('V', 76, struct v4l2_enc_idx)
26428c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_ENCODER_CMD      _IOWR('V', 77, struct v4l2_encoder_cmd)
26438c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_TRY_ENCODER_CMD  _IOWR('V', 78, struct v4l2_encoder_cmd)
26448c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#endif
26458c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
26468c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#if 1
26478c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Experimental, meant for debugging, testing and internal use.
26488c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris   Only implemented if CONFIG_VIDEO_ADV_DEBUG is defined.
26498c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris   You must be root to use these ioctls. Never use these in applications! */
26508c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	VIDIOC_DBG_S_REGISTER 	 _IOW('V', 79, struct v4l2_dbg_register)
26518c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	VIDIOC_DBG_G_REGISTER 	_IOWR('V', 80, struct v4l2_dbg_register)
26528c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
26538c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Experimental, meant for debugging, testing and internal use.
26548c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris   Never use this ioctl in applications! */
26558c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_DBG_G_CHIP_IDENT _IOWR('V', 81, struct v4l2_dbg_chip_ident)
26568c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#endif
26578c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
26588c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_HW_FREQ_SEEK	 _IOW('V', 82, struct v4l2_hw_freq_seek)
26598c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	VIDIOC_ENUM_DV_PRESETS	_IOWR('V', 83, struct v4l2_dv_enum_preset)
26608c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	VIDIOC_S_DV_PRESET	_IOWR('V', 84, struct v4l2_dv_preset)
26618c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	VIDIOC_G_DV_PRESET	_IOWR('V', 85, struct v4l2_dv_preset)
26628c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	VIDIOC_QUERY_DV_PRESET	_IOR('V',  86, struct v4l2_dv_preset)
26638c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	VIDIOC_S_DV_TIMINGS	_IOWR('V', 87, struct v4l2_dv_timings)
26648c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	VIDIOC_G_DV_TIMINGS	_IOWR('V', 88, struct v4l2_dv_timings)
26658c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	VIDIOC_DQEVENT		 _IOR('V', 89, struct v4l2_event)
26668c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	VIDIOC_SUBSCRIBE_EVENT	 _IOW('V', 90, struct v4l2_event_subscription)
26678c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define	VIDIOC_UNSUBSCRIBE_EVENT _IOW('V', 91, struct v4l2_event_subscription)
26688c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
26698c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Experimental, the below two ioctls may change over the next couple of kernel
26708c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris   versions */
26718c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_CREATE_BUFS	_IOWR('V', 92, struct v4l2_create_buffers)
26728c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_PREPARE_BUF	_IOWR('V', 93, struct v4l2_buffer)
26738c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
26748c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Experimental selection API */
26758c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_G_SELECTION	_IOWR('V', 94, struct v4l2_selection)
26768c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_S_SELECTION	_IOWR('V', 95, struct v4l2_selection)
26778c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
26788c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Experimental, these two ioctls may change over the next couple of kernel
26798c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris   versions. */
26808c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_DECODER_CMD	_IOWR('V', 96, struct v4l2_decoder_cmd)
26818c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define VIDIOC_TRY_DECODER_CMD	_IOWR('V', 97, struct v4l2_decoder_cmd)
26828c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
26838c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris/* Reminder: when adding new ioctls please add support for them to
26848c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris   drivers/media/video/v4l2-compat-ioctl32.c as well! */
26858c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
26868c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#define BASE_VIDIOC_PRIVATE	192		/* 192-255 are private */
26878c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris
26888c4fb624ecf6fb5a2e71ddbaf50973a568bd27d3Christopher Ferris#endif /* __LINUX_VIDEODEV2_H */
2689