aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/media/video/em28xx/em28xx-core.c
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <mchehab@redhat.com>2009-08-08 03:14:55 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2009-08-13 20:39:09 -0300
commitc2a6b54a9cf08d4ffeb75d70603c4a5d03ac97ad (patch)
tree3f263afdb14fb8226b0d0f60b026f8e3fc29bf85 /drivers/media/video/em28xx/em28xx-core.c
parentd594317bdc716ccd8c8cf711e3827f9b6e0b766b (diff)
downloadkernel_samsung_smdk4412-c2a6b54a9cf08d4ffeb75d70603c4a5d03ac97ad.zip
kernel_samsung_smdk4412-c2a6b54a9cf08d4ffeb75d70603c4a5d03ac97ad.tar.gz
kernel_samsung_smdk4412-c2a6b54a9cf08d4ffeb75d70603c4a5d03ac97ad.tar.bz2
V4L/DVB (12406): em28xx: fix: don't do image interlacing on webcams
Due to historical reasons, em28xx driver gets two consecutive frames and fold them into an unique framing, doing interlacing. While this works fine for TV images, this produces two bad effects with webcams: 1) webcam images are progressive. Merging two consecutive images produce interlacing artifacts on the image; 2) since the driver needs to get two frames, it reduces the maximum frame rate by two. Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/video/em28xx/em28xx-core.c')
-rw-r--r--drivers/media/video/em28xx/em28xx-core.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/media/video/em28xx/em28xx-core.c b/drivers/media/video/em28xx/em28xx-core.c
index 5b78e19..339fffd 100644
--- a/drivers/media/video/em28xx/em28xx-core.c
+++ b/drivers/media/video/em28xx/em28xx-core.c
@@ -720,7 +720,10 @@ int em28xx_resolution_set(struct em28xx *dev)
{
int width, height;
width = norm_maxw(dev);
- height = norm_maxh(dev) >> 1;
+ height = norm_maxh(dev);
+
+ if (!dev->progressive)
+ height >>= norm_maxh(dev);
em28xx_set_outfmt(dev);