Select input on a v4l2 device

classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Select input on a v4l2 device

José Luis Segura Lucas
Good morning from Spain!

I'm using Gstreamer with some v4l2 devices. Most of them only have one
input and I have no problem with them, but I need to use a video
capture card and this hardware has 2 inputs at least (S-Video and a
composite analogical video).

If I use this device, by default it uses the composite analogical
input, but I need to be able to select the input I want.

I inspect the properties of the v4l2src element and I didn't find
anything related. Do you know any way to select the input of my v4l2src
using the Gstreamer properties?

Regards and thanks in advance.

------------------------------------------------------------------------------
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Select input on a v4l2 device

Michael Joachimiak
device parameter.
device=/dev/video0 and so on.

2010/12/10 José Luis Segura Lucas <[hidden email]>
Good morning from Spain!

I'm using Gstreamer with some v4l2 devices. Most of them only have one
input and I have no problem with them, but I need to use a video
capture card and this hardware has 2 inputs at least (S-Video and a
composite analogical video).

If I use this device, by default it uses the composite analogical
input, but I need to be able to select the input I want.

I inspect the properties of the v4l2src element and I didn't find
anything related. Do you know any way to select the input of my v4l2src
using the Gstreamer properties?

Regards and thanks in advance.

------------------------------------------------------------------------------
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel



--
Your Sincerely
Michael Joachimiak

------------------------------------------------------------------------------

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Select input on a v4l2 device

José Luis Segura Lucas
El Fri, 10 Dec 2010 13:06:16 +0200
Michael Joachimiak <[hidden email]> escribió:
> device parameter.
> device=/dev/video0 and so on.

No, that's the problem. It's only one device (/dev/video0). I want to
select the input on that device, no using another device...


------------------------------------------------------------------------------
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Select input on a v4l2 device

Tim-Philipp Müller-2
On Fri, 2010-12-10 at 12:09 +0100, José Luis Segura Lucas wrote:

> No, that's the problem. It's only one device (/dev/video0). I want to
> select the input on that device, no using another device...

Have you tried the GstTuner interface? (Can't use it from gst-launch)

Set v4l2src to READY state, then you should be able to use the tuner
interface on it.

Cheers
 -Tim



------------------------------------------------------------------------------
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Select input on a v4l2 device

Tristan Matthews-2
Otherwise you can always use v4l2-ctl, i.e.
v4l2-ctl --set-input 1

v4l2-ctl is part of the ivtv-utils package.

-t

2010/12/10 Tim-Philipp Müller <[hidden email]>
On Fri, 2010-12-10 at 12:09 +0100, José Luis Segura Lucas wrote:

> No, that's the problem. It's only one device (/dev/video0). I want to
> select the input on that device, no using another device...

Have you tried the GstTuner interface? (Can't use it from gst-launch)

Set v4l2src to READY state, then you should be able to use the tuner
interface on it.

Cheers
 -Tim



------------------------------------------------------------------------------
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel



--
Tristan Matthews
email: [hidden email]
web: http://tristanswork.blogspot.com

------------------------------------------------------------------------------

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Select input on a v4l2 device

wally_bkg
In reply to this post by Tim-Philipp Müller-2
Tim-Philipp Müller-2 wrote
On Fri, 2010-12-10 at 12:09 +0100, José Luis Segura Lucas wrote:

> No, that's the problem. It's only one device (/dev/video0). I want to
> select the input on that device, no using another device...

Have you tried the GstTuner interface? (Can't use it from gst-launch)

Set v4l2src to READY state, then you should be able to use the tuner
interface on it.

Cheers
 -Tim
Some sample code of how to do this can be found here:

A sample can be found here:

http://gstreamer-devel.966125.n4.nabble.com/Problem-Trying-To-Use-v4l2src-td973410.html#a973414


Just be aware that it sets the pipeline to READY instead of PAUSED which worked for an older version of gstreamer.  

The ugliness of v4l2 is exposed GST_TUNER and I pretty much have had to add a new string to look for every time I've gotten a new capture card to test.


Reply | Threaded
Open this post in threaded view
|

Re: Select input on a v4l2 device

José Luis Segura Lucas
Thanks for all your answers, there are very helpful :-)

I will try Monday, at work :-)

Regards

El Fri, 10 Dec 2010 09:00:55 -0800 (PST)
wally_bkg <[hidden email]> escribió:

>
>
> Tim-Philipp Müller-2 wrote:
> >
> > On Fri, 2010-12-10 at 12:09 +0100, José Luis Segura Lucas wrote:
> >
> >> No, that's the problem. It's only one device (/dev/video0). I want
> >> to select the input on that device, no using another device...
> >
> > Have you tried the GstTuner interface? (Can't use it from
> > gst-launch)
> >
> > Set v4l2src to READY state, then you should be able to use the tuner
> > interface on it.
> >
> > Cheers
> >  -Tim
> >
> >
>
> Some sample code of how to do this can be found here:
>
> A sample can be found here:
>
> http://gstreamer-devel.966125.n4.nabble.com/Problem-Trying-To-Use-v4l2src-td973410.html#a973414
>
>
> Just be aware that it sets the pipeline to READY instead of PAUSED
> which worked for an older version of gstreamer.  
>
> The ugliness of v4l2 is exposed GST_TUNER and I pretty much have had
> to add a new string to look for every time I've gotten a new capture
> card to test.
>
>
>


------------------------------------------------------------------------------
Oracle to DB2 Conversion Guide: Learn learn about native support for PL/SQL,
new data types, scalar functions, improved concurrency, built-in packages,
OCI, SQL*Plus, data movement tools, best practices and more.
http://p.sf.net/sfu/oracle-sfdev2dev 
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel