V4L/DVB (6716): ivtv: yuv interlace mode change
Interlace mode selection code moved into the frame setup phase, so it's now
run before the frame is loaded into a hardware buffer. Given that it can
affect how a new frame is displayed, it was a bit stupid running it after the
frame was already visible.
A few stray interlace related variables which were linked to individual frames
have now been moved into the yuv_frame_info struct. This means that all
variables linked to a specific frame are in the same place & not scattered.
Minor code reformatting in areas touched by the above changes.
Signed-off-by: Ian Armstrong <ian@iarmst.demon.co.uk>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
diff --git a/drivers/media/video/ivtv/ivtv-driver.h b/drivers/media/video/ivtv/ivtv-driver.h
index 12ff938..0e4ad29 100644
--- a/drivers/media/video/ivtv/ivtv-driver.h
+++ b/drivers/media/video/ivtv/ivtv-driver.h
@@ -392,6 +392,9 @@
u32 tru_h;
u32 offset_y;
s32 lace_mode;
+ u32 sync_field;
+ u32 delay;
+ u32 interlaced;
};
#define IVTV_YUV_MODE_INTERLACED 0x00
@@ -465,8 +468,6 @@
int decode_height;
- int frame_interlaced;
-
int lace_mode;
int lace_threshold;
int lace_sync_field;
@@ -477,8 +478,6 @@
u32 yuv_forced_update;
int update_frame;
- int sync_field[IVTV_YUV_BUFFERS]; /* Field to sync on */
- int field_delay[IVTV_YUV_BUFFERS]; /* Flag to extend duration of previous frame */
u8 fields_lapsed; /* Counter used when delaying a frame */
struct yuv_frame_info new_frame_info[IVTV_YUV_BUFFERS];