diff options
author | Hans Verkuil <hverkuil@xs4all.nl> | 2006-03-25 15:09:02 +0100 |
---|---|---|
committer | Hans Verkuil <hverkuil@xs4all.nl> | 2006-03-25 15:09:02 +0100 |
commit | 2dd9a10d75bd07d0ef1527794e256fc9186c1ab6 (patch) | |
tree | d1514842480eeecb4980185ef37791be7d89e533 /linux/drivers/media | |
parent | 4a94881e9a2c8ffb02472f3727e88c108a3b1acf (diff) | |
download | mediapointer-dvb-s2-2dd9a10d75bd07d0ef1527794e256fc9186c1ab6.tar.gz mediapointer-dvb-s2-2dd9a10d75bd07d0ef1527794e256fc9186c1ab6.tar.bz2 |
Added video routing support to pvrusb2
From: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Diffstat (limited to 'linux/drivers/media')
-rw-r--r-- | linux/drivers/media/video/pvrusb2/pvrusb2-video-v4l.c | 13 |
1 files changed, 8 insertions, 5 deletions
diff --git a/linux/drivers/media/video/pvrusb2/pvrusb2-video-v4l.c b/linux/drivers/media/video/pvrusb2/pvrusb2-video-v4l.c index d0bc3682b..97c3e2c38 100644 --- a/linux/drivers/media/video/pvrusb2/pvrusb2-video-v4l.c +++ b/linux/drivers/media/video/pvrusb2/pvrusb2-video-v4l.c @@ -35,6 +35,7 @@ #include "pvrusb2-debug.h" #include <linux/videodev.h> #include <media/v4l2-common.h> +#include <media/saa7115.h> #include <linux/errno.h> #include <linux/slab.h> @@ -50,25 +51,27 @@ struct pvr2_v4l_decoder { static void set_input(struct pvr2_v4l_decoder *ctxt) { struct pvr2_hdw *hdw = ctxt->hdw; - int v = 0; + struct v4l2_routing route; + pvr2_trace(PVR2_TRACE_CHIPS,"i2c v4l2 set_input(%d)", hdw->controls[PVR2_CID_INPUT].value); switch(hdw->controls[PVR2_CID_INPUT].value){ case PVR2_CVAL_INPUT_TV: - v = 4; + route.input = SAA7115_COMPOSITE4; break; case PVR2_CVAL_INPUT_COMPOSITE: - v = 5; + route.input = SAA7115_COMPOSITE5; break; case PVR2_CVAL_INPUT_SVIDEO: - v = 8; + route.input = SAA7115_SVIDEO2; break; case PVR2_CVAL_INPUT_RADIO: // ????? No idea yet what to do here default: return; } - pvr2_i2c_client_cmd(ctxt->client,VIDIOC_S_INPUT,&v); + route.output = 0; + pvr2_i2c_client_cmd(ctxt->client,VIDIOC_INT_S_VIDEO_ROUTING,&route); } |