Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 115594
b: refs/heads/master
c: 962d699
h: refs/heads/master
v: v3
  • Loading branch information
Hans Verkuil authored and Mauro Carvalho Chehab committed Oct 17, 2008
1 parent 8a9106c commit 7b4d2d2
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 2e668962a54b64f3daffb8eef3ca538e25324d1a
refs/heads/master: 962d699e5d12952c43d7316bc72a527a8aa134b7
18 changes: 16 additions & 2 deletions trunk/drivers/media/video/ivtv/ivtv-ioctl.c
Original file line number Diff line number Diff line change
Expand Up @@ -509,15 +509,29 @@ static int ivtv_try_fmt_sliced_vbi_cap(struct file *file, void *fh, struct v4l2_
static int ivtv_try_fmt_vid_out(struct file *file, void *fh, struct v4l2_format *fmt)
{
struct ivtv_open_id *id = fh;
struct ivtv *itv = id->itv;
s32 w = fmt->fmt.pix.width;
s32 h = fmt->fmt.pix.height;
int field = fmt->fmt.pix.field;
int ret = ivtv_g_fmt_vid_out(file, fh, fmt);

w = min(w, 720);
w = max(w, 2);
h = min(h, itv->is_out_50hz ? 576 : 480);
/* Why can the height be 576 even when the output is NTSC?
Internally the buffers of the PVR350 are always set to 720x576. The
decoded video frame will always be placed in the top left corner of
this buffer. For any video which is not 720x576, the buffer will
then be cropped to remove the unused right and lower areas, with
the remaining image being scaled by the hardware to fit the display
area. The video can be scaled both up and down, so a 720x480 video
can be displayed full-screen on PAL and a 720x576 video can be
displayed without cropping on NTSC.
Note that the scaling only occurs on the video stream, the osd
resolution is locked to the broadcast standard and not scaled.
Thanks to Ian Armstrong for this explanation. */
h = min(h, 576);
h = max(h, 2);
if (id->type == IVTV_DEC_STREAM_TYPE_YUV)
fmt->fmt.pix.field = field;
Expand Down

0 comments on commit 7b4d2d2

Please sign in to comment.