/* Min. value in VDELAY register. */ #define MIN_VDELAY 2 /* Even to get Cb first, odd for Cr. */ #define MAX_HDELAY (0x3FF & -2) /* Limits scaled width, which must be a multiple of 4. */ #define MAX_HACTIVE (0x3FF & -4)
struct bttv_tvnorm { int v4l2_id; char *name;
u32 Fsc;
u16 swidth, sheight; /* scaled standard width, height */
u16 totalwidth;
u8 adelay, bdelay, iform;
u32 scaledtwidth;
u16 hdelayx1, hactivex1;
u16 vdelay;
u8 vbipack;
u16 vtotal; int sram; /* ITU-R frame line number of the first VBI line we can capture, of the first and second field. The last possible line
is determined by cropcap.bounds. */
u16 vbistart[2]; /* Horizontally this counts fCLKx1 samples following the leading edge of the horizontal sync pulse, vertically ITU-R frame line
numbers of the first field times two (2, 4, 6, ... 524 or 624). */ struct v4l2_cropcap cropcap;
}; externconststruct bttv_tvnorm bttv_tvnorms[];
struct bttv_format { int fourcc; /* video4linux 2 */ int btformat; /* BT848_COLOR_FMT_* */ int btswap; /* BT848_COLOR_CTL_* */ int depth; /* bit/pixel */ int flags; int hshift,vshift; /* for planar modes */
};
/* Usual gpio signalling */
u32 mask_keycode;
u32 mask_keydown;
u32 mask_keyup;
u32 polling;
u32 last_gpio; int shift_by; int rc5_remote_gap;
/* RC5 gpio */ bool rc5_gpio; /* Is RC5 legacy GPIO enabled? */
u32 last_bit; /* last raw bit seen */
u32 code; /* raw code under construction */
ktime_t base_time; /* time of last seen code */ bool active; /* building raw code */
};
struct bttv_crop { /* A cropping rectangle in struct bttv_tvnorm.cropcap units. */ struct v4l2_rect rect;
/* Scaled image size limits with this crop rect. Divide max_height, but not min_height, by two when capturing single fields. See also bttv_crop_reset() and
bttv_crop_adjust() in bttv-driver.c. */
__s32 min_scaled_width;
__s32 min_scaled_height;
__s32 max_scaled_width;
__s32 max_scaled_height;
};
/* control dma register + risc main loop */ void bttv_set_dma(struct bttv *btv, int override); int bttv_risc_init_main(struct bttv *btv); int bttv_risc_hook(struct bttv *btv, int slot, struct btcx_riscmem *risc, int irqflags);
/* capture buffer handling */ int bttv_buffer_risc(struct bttv *btv, struct bttv_buffer *buf); int bttv_buffer_activate_video(struct bttv *btv, struct bttv_buffer_set *set); int bttv_buffer_risc_vbi(struct bttv *btv, struct bttv_buffer *buf); int bttv_buffer_activate_vbi(struct bttv *btv, struct bttv_buffer *vbi);
/* * 2048 for compatibility with earlier driver versions. The driver really * stores 1024 + tvnorm->vbipack * 4 samples per line in the buffer. Note * tvnorm->vbipack is <= 0xFF (limit of VBIPACK_LO + HI is 0x1FF DWORDs) and * VBI read()s store a frame counter in the last four bytes of the VBI image.
*/ #define VBI_BPL 2048
#define VBI_DEFLINES 16
int bttv_try_fmt_vbi_cap(struct file *file, void *fh, struct v4l2_format *f); int bttv_g_fmt_vbi_cap(struct file *file, void *fh, struct v4l2_format *f); int bttv_s_fmt_vbi_cap(struct file *file, void *fh, struct v4l2_format *f);
/* infrared remote */ int has_remote; struct bttv_ir *remote;
/* I2C remote data */ struct IR_i2c_init_data init_data;
/* locking */
spinlock_t s_lock; struct mutex lock; int resources;
/* video state */ unsignedint input; unsignedint audio_input; unsignedint mute; unsignedlong tv_freq; unsignedint tvnorm;
v4l2_std_id std; int hue, contrast, bright, saturation; struct v4l2_framebuffer fbuf;
__u32 field_count;
/* various options */ int opt_combfilter; int opt_automute; int opt_vcr_hack; int opt_uv_ratio;
/* radio data/state */ int has_radio; int has_radio_tuner; int radio_user; int radio_uses_msp_demodulator; unsignedlong radio_freq;
/* miro/pinnacle + Aimslab VHX
philips matchbox (tea5757 radio tuner) support */ int has_tea575x; struct bttv_tea575x_gpio tea_gpio; struct snd_tea575x tea;
/* ISA stuff (Terratec Active Radio Upgrade) */ int mbox_ior; int mbox_iow; int mbox_csel;
/* switch status for multi-controller cards */ char sw_status[4];
/* risc memory management data - must acquire s_lock before changing these
- only the irq handler is supported to touch top + bottom + vcurr */ struct btcx_riscmem main; struct list_head capture; /* video capture queue */ struct list_head vcapture; /* vbi capture queue */ struct bttv_buffer_set curr; /* active buffers */ struct bttv_buffer *cvbi; /* active vbi buffer */ int loop_irq; int new_input;
/* Application called VIDIOC_S_SELECTION. */ int do_crop;
/* used to make dvb-bt8xx autoloadable */ struct work_struct request_module_wk;
/* Default (0) and current (1) video capturing cropping parameters in bttv_tvnorm.cropcap units. Protected
by bttv.lock. */ struct bttv_crop crop[2];
/* Earliest possible start of video capturing in bttv_tvnorm.cropcap line units. Set by check_alloc_btres()
and free_btres(). Protected by bttv.lock. */
__s32 vbi_end;
/* Latest possible end of VBI capturing (= crop[x].rect.top when VIDEO_RESOURCES are locked). Set by check_alloc_btres()
and free_btres(). Protected by bttv.lock. */
__s32 crop_start;
};
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.