<br><br><div class="gmail_quote">On Wed, Sep 30, 2009 at 2:52 PM, thiagoss <span dir="ltr">&lt;<a href="mailto:thiagossantos@gmail.com" target="_blank">thiagossantos@gmail.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">


<br><br><div class="gmail_quote"><div>On Wed, Sep 30, 2009 at 1:17 PM, Dick Marinus <span dir="ltr">&lt;<a href="mailto:dick@mrns.nl" target="_blank">dick@mrns.nl</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">



Hi all,<br>
<br>
At April 30, 2006 Fredrik posted a message about using the tuner<br>
interface from Python and I&#39;m experiencing the same issue:<br>
<br>
$ python<br>
&gt;&gt;&gt; import gst<br>
&gt;&gt;&gt; source = gst.element_factory_make(&quot;v4l2src&quot;,name=&quot;Pinnacle PCTV<br>
USB2.0&quot;)<br>
&gt;&gt;&gt; print source.get_channel()<br>
<br>
(.:13363): GStreamer-CRITICAL **: gst_implements_interface_cast:<br>
assertion `gst_element_implements_interface (GST_ELEMENT (from),<br>
iface_type)&#39; failed<br>
<br>
** (.:13363): CRITICAL **: gst_tuner_get_channel: assertion<br>
`GST_IS_TUNER (tuner)&#39; failed<br>
<br>
I&#39;ve tried to set the pipeline queue to STATE_PLAYING but I still have<br>
the same error.<br>
<br>
I guess something is broken at the Python bindings. Could someone please<br>
help me?<br></blockquote></div><div><br>I had this same problem this week on a toy project and thaytan sent me a python script that uses GstTuner interface from
v4l2src, but I still haven&#39;t looked deeply at it. I&#39;ll do it tonight and
I&#39;ll update here with my findings.<br><br>One thing I noticed, though, is that GstV4l2Src is using a subclass of GstTunerChannel that is not mapped/exported in the python bindings (but I don&#39;t know much about bindings and thaytan said it worked for him, so I believe I&#39;m doing something wrong in my code).<br>



<br></div></div></blockquote><div><br>Found what was wrong:<br><br>1) It will not work on NULL state, I don&#39;t know if works on READY, tested only with it PLAYING and I&#39;m assuming it also works for PAUSED<br><br>2) You&#39;re not supposed to create your own gst.TunerChannel objects and set them, you have to do src.list_channels() and pick one to set.<br>


<br>Works perfectly here. Maybe the docs could be updated to clarify this.<br> </div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div class="gmail_quote">


<div> </div><div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>
I&#39;m using:<br>
gst-python=0.10.16<br>
gstreamer=0.10.24<br>
gst-plugins-good=0.10.16<br>
gst-plugins-base=0.10.24<br>
<br>
Thanks in advance,<br>
Dick<br>
<br>
<br>
------------------------------------------------------------------------------<br>
Come build with us! The BlackBerry&amp;reg; Developer Conference in SF, CA<br>
is the only developer event you need to attend this year. Jumpstart your<br>
developing skills, take BlackBerry mobile applications to market and stay<br>
ahead of the curve. Join us from November 9&amp;#45;12, 2009. Register now&amp;#33;<br>
<a href="http://p.sf.net/sfu/devconf" target="_blank">http://p.sf.net/sfu/devconf</a><br>
_______________________________________________<br>
gstreamer-devel mailing list<br>
<a href="mailto:gstreamer-devel@lists.sourceforge.net" target="_blank">gstreamer-devel@lists.sourceforge.net</a><br>
<a href="https://lists.sourceforge.net/lists/listinfo/gstreamer-devel" target="_blank">https://lists.sourceforge.net/lists/listinfo/gstreamer-devel</a><br>
</blockquote></div></div><font color="#888888"><br><br clear="all"><br>-- <br>Thiago Sousa Santos<br>
</font></blockquote></div><br><br clear="all"><br>-- <br>Thiago Sousa Santos<br>