summaryrefslogtreecommitdiff
path: root/linux/include
diff options
context:
space:
mode:
authorHans Verkuil <hverkuil@xs4all.nl>2009-02-13 14:57:48 +0100
committerHans Verkuil <hverkuil@xs4all.nl>2009-02-13 14:57:48 +0100
commit12a53c2ca239e0fd7a2b858b577d624677982ab9 (patch)
treeb2582249f9817c2e3f4db6e6cec4f7b3f9bb5d0e /linux/include
parent52a672f1e1c02901afbfcc810f5ab962759a05e0 (diff)
downloadmediapointer-dvb-s2-12a53c2ca239e0fd7a2b858b577d624677982ab9.tar.gz
mediapointer-dvb-s2-12a53c2ca239e0fd7a2b858b577d624677982ab9.tar.bz2
v4l2-common: add comments warning that about the sort order
From: Hans Verkuil <hverkuil@xs4all.nl> Control arrays as are used with v4l2_ctrl_next must be sorted from low to high. Add a comment at the top of all such arrays to warn about this. Priority: normal Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Diffstat (limited to 'linux/include')
-rw-r--r--linux/include/media/v4l2-common.h5
1 files changed, 5 insertions, 0 deletions
diff --git a/linux/include/media/v4l2-common.h b/linux/include/media/v4l2-common.h
index 0f864f8da..4d82f1619 100644
--- a/linux/include/media/v4l2-common.h
+++ b/linux/include/media/v4l2-common.h
@@ -107,6 +107,11 @@ int v4l2_ctrl_query_menu(struct v4l2_querymenu *qmenu,
struct v4l2_queryctrl *qctrl, const char **menu_items);
#define V4L2_CTRL_MENU_IDS_END (0xffffffff)
int v4l2_ctrl_query_menu_valid_items(struct v4l2_querymenu *qmenu, const u32 *ids);
+
+/* Note: ctrl_classes points to an array of u32 pointers. Each u32 array is a
+ 0-terminated array of control IDs. Each array must be sorted low to high
+ and belong to the same control class. The array of u32 pointers must also
+ be sorted, from low class IDs to high class IDs. */
u32 v4l2_ctrl_next(const u32 * const *ctrl_classes, u32 id);
/* ------------------------------------------------------------------------- */