📄 camera.h
字号:
/* * linux/drivers/media/video/omap/camera.h * * Copyright (C) 2004 Texas Instruments Inc * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA */#include <linux/videodev.h>#define CAMERA_OV6630_DEV_ID 0xC0#define CAMERA_SANYO_DEV_ID 0x78#define QCIF_WIDTH 176#define QCIF_HEIGHT 144#define CIF_WIDTH 352#define CIF_HEIGHT 288struct camera_interface;typedef struct camera { // interface in which this camera is attached struct camera_interface * camif; int imageWidth; int imageHeight; int bytes_per_pixel; int (*detect)(void); // detect this camera int (*init)(void); // one-time setup void (*cleanup)(void); int (*open)(void); int (*close)(void); // called when image format changes int (*setup)(struct v4l2_pix_format* fmt); // frame period is .1 usec units, exclk returned in MHz int (*set_frame_period)(int fp, int* exclk, int test); int (*get_frame_period)(int* exclk); /* convert raw camera image to that specified by V4L2 layer */ int (*convert_image)(u8* src, void* dest, int to_user, int dest_stride, struct v4l2_pix_format* fmt); int (*query_control)(struct v4l2_queryctrl *qc); int (*get_control)(struct v4l2_control *vc); int (*set_control)(struct v4l2_control *vc); int (*query_menu)(struct v4l2_querymenu *qm);} camera_t;// Implementations of camera_textern struct camera camera_ov6x30;extern struct camera camera_sanyo;
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -