📄 pwc-uncompress.h
字号:
/* (C) 1999-2003 Nemosoft Unv. (webcam@smcc.demon.nl) 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*//* This file is the bridge between the kernel module and the plugin; it describes the structures and datatypes used in both modules. Any significant change should be reflected by increasing the pwc_decompressor_version major number. */#ifndef PWC_UNCOMPRESS_H#define PWC_UNCOMPRESS_H#include <linux/config.h>#include <linux/linkage.h>#include <linux/list.h>#include "pwc-ioctl.h"/* from pwc-dec.h */#define PWCX_FLAG_PLANAR 0x0001/* *//* Small hack for GCC 2.*; that compiler doesn't like asmlinkage in function pointer declarations, so we ignore them for that version. This doesn't present a problem since the default regparm() mode for GCC 2 is that same as with asmlinkage defined. */ #if __GNUC__ == 2#define PWC_LINKAGE#else#define PWC_LINKAGE asmlinkage#endif#ifdef __cplusplusextern "C" {#endif/* The decompressor structure. Every type of decompressor registers itself with the main module. When a device is opened, it looks up the correct compressor, and uses that when a compressed video mode is requested. */struct pwc_decompressor{ int type; /* type of camera (645, 680, etc) */ int table_size; /* memory needed */ PWC_LINKAGE void (* init)(int type, int release, void *buffer, void *table); /* Initialization routine; should be called after each set_video_mode */ PWC_LINKAGE void (* exit)(void); /* Cleanup routine */ PWC_LINKAGE void (* decompress)(struct pwc_coord *image, struct pwc_coord *view, struct pwc_coord *offset, void *src, void *dst, int flags, void *table, int bandlength); void (* lock)(void); /* make sure module cannot be unloaded */ void (* unlock)(void); /* release lock on module */ struct list_head pwcd_list;};#undef PWC_LINKAGE/* Our structure version number. Is set to the version number major */extern const int pwc_decompressor_version;/* Adds decompressor to list, based on its 'type' field (which matches the 'type' field in pwc_device; ignores any double requests */extern void pwc_register_decompressor(struct pwc_decompressor *pwcd);/* Removes decompressor, based on the type number */extern void pwc_unregister_decompressor(int type);/* Returns pointer to decompressor struct, or NULL if it doesn't exist */extern struct pwc_decompressor *pwc_find_decompressor(int type);#ifdef CONFIG_USB_PWCX/* If the decompressor is compiled in, we must call these manually */extern int usb_pwcx_init(void);extern void usb_pwcx_exit(void);#endif#ifdef __cplusplus}#endif#endif
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -