Lines Matching refs:geo
326 bttv_calc_geo_old(struct bttv *btv, struct bttv_geometry *geo, in bttv_calc_geo_old() argument
346 geo->hscale = ((totalwidth*4096UL)/xsf-4096); in bttv_calc_geo_old()
347 geo->hdelay = tvnorm->hdelayx1; in bttv_calc_geo_old()
348 geo->hdelay = (geo->hdelay*width)/swidth; in bttv_calc_geo_old()
349 geo->hdelay &= 0x3fe; in bttv_calc_geo_old()
351 geo->vscale = (0x10000UL-sr) & 0x1fff; in bttv_calc_geo_old()
352 geo->crop = ((width>>8)&0x03) | ((geo->hdelay>>6)&0x0c) | in bttv_calc_geo_old()
354 geo->vscale |= interleaved ? (BT848_VSCALE_INT<<8) : 0; in bttv_calc_geo_old()
355 geo->vdelay = vdelay; in bttv_calc_geo_old()
356 geo->width = width; in bttv_calc_geo_old()
357 geo->sheight = tvnorm->sheight; in bttv_calc_geo_old()
358 geo->vtotal = tvnorm->vtotal; in bttv_calc_geo_old()
361 geo->vtc = (width < 193) ? 2 : ((width < 385) ? 1 : 0); in bttv_calc_geo_old()
362 geo->comb = (width < 769) ? 1 : 0; in bttv_calc_geo_old()
364 geo->vtc = 0; in bttv_calc_geo_old()
365 geo->comb = 0; in bttv_calc_geo_old()
371 struct bttv_geometry * geo, in bttv_calc_geo() argument
388 bttv_calc_geo_old(btv, geo, width, height, in bttv_calc_geo()
398 geo->width = width; in bttv_calc_geo()
399 geo->hscale = (c_width * 4096U + (width >> 1)) / width - 4096; in bttv_calc_geo()
401 geo->hdelay = ((crop->left * width + c_width) / c_width) & ~1; in bttv_calc_geo()
403 geo->sheight = c_height; in bttv_calc_geo()
404 geo->vdelay = crop->top - tvnorm->cropcap.bounds.top + MIN_VDELAY; in bttv_calc_geo()
407 geo->vscale = (0x10000UL - sr) & 0x1fff; in bttv_calc_geo()
408 geo->vscale |= both_fields ? (BT848_VSCALE_INT << 8) : 0; in bttv_calc_geo()
409 geo->vtotal = tvnorm->vtotal; in bttv_calc_geo()
411 geo->crop = (((geo->width >> 8) & 0x03) | in bttv_calc_geo()
412 ((geo->hdelay >> 6) & 0x0c) | in bttv_calc_geo()
413 ((geo->sheight >> 4) & 0x30) | in bttv_calc_geo()
414 ((geo->vdelay >> 2) & 0xc0)); in bttv_calc_geo()
417 geo->vtc = (width < 193) ? 2 : ((width < 385) ? 1 : 0); in bttv_calc_geo()
418 geo->comb = (width < 769) ? 1 : 0; in bttv_calc_geo()
420 geo->vtc = 0; in bttv_calc_geo()
421 geo->comb = 0; in bttv_calc_geo()
426 bttv_apply_geo(struct bttv *btv, struct bttv_geometry *geo, int odd) in bttv_apply_geo() argument
430 if (geo->comb) in bttv_apply_geo()
435 btwrite(geo->vtc, BT848_E_VTC+off); in bttv_apply_geo()
436 btwrite(geo->hscale >> 8, BT848_E_HSCALE_HI+off); in bttv_apply_geo()
437 btwrite(geo->hscale & 0xff, BT848_E_HSCALE_LO+off); in bttv_apply_geo()
438 btaor((geo->vscale>>8), 0xe0, BT848_E_VSCALE_HI+off); in bttv_apply_geo()
439 btwrite(geo->vscale & 0xff, BT848_E_VSCALE_LO+off); in bttv_apply_geo()
440 btwrite(geo->width & 0xff, BT848_E_HACTIVE_LO+off); in bttv_apply_geo()
441 btwrite(geo->hdelay & 0xff, BT848_E_HDELAY_LO+off); in bttv_apply_geo()
442 btwrite(geo->sheight & 0xff, BT848_E_VACTIVE_LO+off); in bttv_apply_geo()
443 btwrite(geo->vdelay & 0xff, BT848_E_VDELAY_LO+off); in bttv_apply_geo()
444 btwrite(geo->crop, BT848_E_CROP+off); in bttv_apply_geo()
445 btwrite(geo->vtotal>>8, BT848_VTOTAL_HI); in bttv_apply_geo()
446 btwrite(geo->vtotal & 0xff, BT848_VTOTAL_LO); in bttv_apply_geo()
608 if (vbi->geo.vdelay > vdelay) { in bttv_buffer_activate_vbi()
609 vdelay = vbi->geo.vdelay & 0xfe; in bttv_buffer_activate_vbi()
610 crop = (crop & 0x3f) | ((vbi->geo.vdelay >> 2) & 0xc0); in bttv_buffer_activate_vbi()
654 bttv_apply_geo(btv, &set->top->geo, 1); in bttv_buffer_activate_video()
655 bttv_apply_geo(btv, &set->bottom->geo,0); in bttv_buffer_activate_video()
668 bttv_apply_geo(btv, &set->top->geo,1); in bttv_buffer_activate_video()
669 bttv_apply_geo(btv, &set->top->geo,0); in bttv_buffer_activate_video()
679 bttv_apply_geo(btv, &set->bottom->geo,1); in bttv_buffer_activate_video()
680 bttv_apply_geo(btv, &set->bottom->geo,0); in bttv_buffer_activate_video()
711 bttv_calc_geo(btv,&buf->geo,buf->vb.width,buf->vb.height, in bttv_buffer_risc()
765 bttv_calc_geo(btv,&buf->geo,buf->vb.width, in bttv_buffer_risc()
774 bttv_calc_geo(btv,&buf->geo,buf->vb.width, in bttv_buffer_risc()
783 bttv_calc_geo(btv,&buf->geo,buf->vb.width, in bttv_buffer_risc()
806 bttv_calc_geo(btv,&buf->geo,buf->vb.width, in bttv_buffer_risc()
838 bttv_calc_geo(btv,&buf->geo,tvnorm->swidth,tvnorm->sheight, in bttv_buffer_risc()
868 bttv_calc_geo(btv,&buf->geo,ov->w.width,ov->w.height, in bttv_overlay_risc()