[gst-devel] Problem selecting input on tuner with v4l2src
Fredrik Persson
frepe at bredband.net
Sun Apr 30 14:29:04 CEST 2006
I think this question is irrelevant and "wrong", please look at my email with
subject "About using the tuner interface in python" instead.
Sorry about spamming like this.
/Fredrik
On Sunday 30 April 2006 21:14, Fredrik Persson wrote:
> Hi!
>
> I'm writing a small Python app where I use a Pinnacle USB tuner with
> v4l2src. The hardware have three different inputs; "Television",
> "Composite1" and "S-video". I found those using the command "v4l-info".
> That gave me this output:
>
> /.../
> channels
> VIDIOCGCHAN(0)
> channel : 0
> name : "Television"
> tuners : 1
> flags : 0x1 [TUNER]
> type : TV
> norm : 0
> VIDIOCGCHAN(1)
> channel : 1
> name : "Composite1"
> tuners : 0
> flags : 0x0 []
> type : CAMERA
> norm : 0
> VIDIOCGCHAN(2)
> channel : 2
> name : "S-Video"
> tuners : 0
> flags : 0x0 []
> type : CAMERA
> norm : 0
> /.../
>
> "gst-inspect v4l2src" gives me this:
>
> /.../
> input : input/output (channel) to switch to
> flags: readable, writable
> String. Default: null Current: null
> frequency : frequency to tune to (in Hz)
> flags: readable, writable
> Unsigned Long. Range: 0 - 18446744073709551615
> Default: 0 Current: 0
> /.../
>
> So I assumed that "input" corresponds to the three input methods described
> above.
>
> This is what I did in python:
>
> source = gst.element_factory_make("v4l2src",name="Pinnacle PCTV USB2.0")
> source.set_property("input","Composite1")
>
> ... and then I build a pipeline using that source element. This does not
> work, I don't get the signal from the composite input. (And I know it's
> there, because when I run xawtv and select "Composite1", I can see the
> video stream.)
>
> So my question is; how do I make it so that the v4l2src element properly
> tells the v4l2 driver to select the composite (or S-video) input? (In
> python, preferably.)
>
> Thank you in advance!
>
> /Fredrik Persson
More information about the gstreamer-devel
mailing list