]> www.pilppa.org Git - linux-2.6-omap-h63xx.git/blob - drivers/media/video/omap/sensor_if.h
984ba5553d6b6a145244732db2d6c291ebf03835
[linux-2.6-omap-h63xx.git] / drivers / media / video / omap / sensor_if.h
1
2 /*
3  * drivers/media/video/omap/sensor_if.h
4  *
5  * Copyright (C) 2004 Texas Instruments, Inc. 
6  * 
7  * Sensor interface to OMAP camera capture drivers
8  * Sensor driver should implement this interface
9  *
10  * This package is free software; you can redistribute it and/or modify 
11  * it under the terms of the GNU General Public License version 2 as
12  * published by the Free Software Foundation. 
13  * 
14  * THIS PACKAGE IS PROVIDED ``AS IS'' AND WITHOUT ANY EXPRESS OR 
15  * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED 
16  * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. 
17  */
18  
19 #ifndef OMAP_SENSOR_IF_H
20 #define OMAP_SENSOR_IF_H
21  
22 #define LEN_SENSOR_NAME         31
23
24 struct camera_sensor {
25         unsigned int version;
26         char name[LEN_SENSOR_NAME + 1];
27
28         void *(*init)(struct v4l2_pix_format *);
29         int (*cleanup)(void *);
30
31         int (*power_on)(void *);
32         int (*power_off)(void *);
33
34         int (*enum_pixformat)(struct v4l2_fmtdesc *, void *);
35         int (*try_format) (struct v4l2_pix_format *, void *);
36
37         unsigned long (*calc_xclk) (struct v4l2_pix_format *,
38                 struct v4l2_fract *, void *);
39
40         int (*configure) (struct v4l2_pix_format *, unsigned long,
41                                           struct v4l2_fract *, void *);
42
43         int (*query_control) (struct v4l2_queryctrl *, void *);
44         int (*get_control) (struct  v4l2_control *, void *);
45         int (*set_control) (struct  v4l2_control *, void *);
46
47 };
48         
49 #endif