Gitweb:     
http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=12b896e436a3b1bc83856962388ae1ab154742a6
Commit:     12b896e436a3b1bc83856962388ae1ab154742a6
Parent:     b331def2d382d7a51c379f336fe80ef87d6674e3
Author:     Hans Verkuil <[EMAIL PROTECTED]>
AuthorDate: Mon Dec 18 13:37:50 2006 -0300
Committer:  Mauro Carvalho Chehab <[EMAIL PROTECTED]>
CommitDate: Wed Dec 27 14:19:38 2006 -0200

    V4L/DVB (4983): Force temporal filter to 0 when scaling to prevent ghosting.
    
    Change the code to unconditionally turn off the temporal filter when 
scaling.
    If the window is not full screen the filter will introduce a nasty ghosting
    effect.
    
    Signed-off-by: Hans Verkuil <[EMAIL PROTECTED]>
    Signed-off-by: Mauro Carvalho Chehab <[EMAIL PROTECTED]>
---
 drivers/media/video/cx2341x.c |   15 ++++++---------
 1 files changed, 6 insertions(+), 9 deletions(-)

diff --git a/drivers/media/video/cx2341x.c b/drivers/media/video/cx2341x.c
index 657e0b9..e796afd 100644
--- a/drivers/media/video/cx2341x.c
+++ b/drivers/media/video/cx2341x.c
@@ -742,7 +742,6 @@ int cx2341x_update(void *priv, cx2341x_mbox_func func,
 
        if (old == NULL || old->width != new->width || old->height != 
new->height ||
                        old->video_encoding != new->video_encoding) {
-               int is_scaling;
                u16 w = new->width;
                u16 h = new->height;
 
@@ -752,20 +751,18 @@ int cx2341x_update(void *priv, cx2341x_mbox_func func,
                }
                err = cx2341x_api(priv, func, CX2341X_ENC_SET_FRAME_SIZE, 2, h, 
w);
                if (err) return err;
+       }
 
+       if (new->width != 720 || new->height != (new->is_50hz ? 576 : 480)) {
                /* Adjust temporal filter if necessary. The problem with the 
temporal
                   filter is that it works well with full resolution capturing, 
but
                   not when the capture window is scaled (the filter introduces
-                  a ghosting effect). So if the capture window changed, and 
there is
-                  no updated filter value, then the filter is set depending on 
whether
-                  the new window is full resolution or not.
+                  a ghosting effect). So if the capture window is scaled, then
+                  force the filter to 0.
 
-                  For full resolution a setting of 8 really improves the video
+                  For full resolution the filter really improves the video
                   quality, especially if the original video quality is 
suboptimal. */
-               is_scaling = new->width != 720 || new->height != (new->is_50hz 
? 576 : 480);
-               if (old && old->video_temporal_filter == temporal) {
-                       temporal = is_scaling ? 0 : 8;
-               }
+               temporal = 0;
        }
 
        if (old == NULL || old->stream_type != new->stream_type) {
-
To unsubscribe from this list: send the line "unsubscribe git-commits-head" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to