v4l2sink plugin erroneously submitting the same buffer again

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

v4l2sink plugin erroneously submitting the same buffer again

Guennadi Liakhovetski
Hi Rob, all

I'm trying to use the v4l2sink plugin with my video-output driver.
Currently I'm blocked by the following problem: I observe, that the
VIDIOC_Q_BUF ioctl is issued by gstreamer twice in a row for the same
buffer without a VIDIOC_DQ_BUF between them. This triggers an error in the
kernel in drivers/media/video/videobuf-core.c::videobuf_qbuf() - the
buffer-state test fails. Am I doing anything wrong? The command line used
is

gst-launch -v filesrc location=/home/default/r0010854.avi ! decodebin ! ffmpegcolorspace ! v4l2sink device=/dev/video0

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer
http://www.open-technology.de/

------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: v4l2sink plugin erroneously submitting the same buffer again

Clark, Rob
Hi Guennadi,

Could you send me a log w/ GST_DEBUG="*v4l2*:5"?


BR,
-R


On Mar 8, 2010, at 4:43 AM, Guennadi Liakhovetski wrote:

> Hi Rob, all
>
> I'm trying to use the v4l2sink plugin with my video-output driver.
> Currently I'm blocked by the following problem: I observe, that the
> VIDIOC_Q_BUF ioctl is issued by gstreamer twice in a row for the same
> buffer without a VIDIOC_DQ_BUF between them. This triggers an error in the
> kernel in drivers/media/video/videobuf-core.c::videobuf_qbuf() - the
> buffer-state test fails. Am I doing anything wrong? The command line used
> is
>
> gst-launch -v filesrc location=/home/default/r0010854.avi ! decodebin ! ffmpegcolorspace ! v4l2sink device=/dev/video0
>
> Thanks
> Guennadi
> ---
> Guennadi Liakhovetski, Ph.D.
> Freelance Open-Source Software Developer
> http://www.open-technology.de/


------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: v4l2sink plugin erroneously submitting the same buffer again

Guennadi Liakhovetski
On Mon, 8 Mar 2010, Clark, Rob wrote:

> Hi Guennadi,
>
> Could you send me a log w/ GST_DEBUG="*v4l2*:5"?

Attached compressed. ASAIU, these two lines are interesting:

0:00:03.630077728 4m 10350m   0x43ed50 mLOG    0m 0m                v4l2 gstv4l2bufferpool.c:484:gst_v4l2_buffer_pool_qbuf:<v4l2sink0>0m enqueue pool buffer 0

0:00:03.737993377 4m 10350m   0x43ed50 mLOG    0m 0m                v4l2 gstv4l2bufferpool.c:484:gst_v4l2_buffer_pool_qbuf:<v4l2sink0>0m enqueue pool buffer 0

in both cases buffer +0 is queued and the second one returns an error.

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer
http://www.open-technology.de/
------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel

gst.dbg.bz2 (5K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

gst_parse_launch question

Roland Peffer-2
I have a strange problem:


If I call 
pipeline = gst_parse_launch("playbin2  uri='file:://[filepath]' ", &error); 
gst_parse_launch does not return an error, but setting the pipeline state later to paused or playing returns GST_STATE_CHANGE_FAILURE.

The same command in the shell 
gst-launch playbin2  uri='file:://[filepath]' 

works fine.

I do not understand the difference. Any hints?

Thanks 
Roland




------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: v4l2sink plugin erroneously submitting the same buffer again

Clark, Rob
In reply to this post by Guennadi Liakhovetski

On Mar 8, 2010, at 8:18 AM, Guennadi Liakhovetski wrote:

> On Mon, 8 Mar 2010, Clark, Rob wrote:
>
>> Hi Guennadi,
>>
>> Could you send me a log w/ GST_DEBUG="*v4l2*:5"?
>
> Attached compressed. ASAIU, these two lines are interesting:
>
> 0:00:03.630077728 4m 10350m   0x43ed50 mLOG    0m 0m                v4l2 gstv4l2bufferpool.c:484:gst_v4l2_buffer_pool_qbuf:<v4l2sink0>0m enqueue pool buffer 0
>
> 0:00:03.737993377 4m 10350m   0x43ed50 mLOG    0m 0m                v4l2 gstv4l2bufferpool.c:484:gst_v4l2_buffer_pool_qbuf:<v4l2sink0>0m enqueue pool buffer 0
>
> in both cases buffer +0 is queued and the second one returns an error.


Hmm, could you delete this line in gstv4l2sink.c:

  basesink_class->preroll = GST_DEBUG_FUNCPTR (gst_v4l2sink_show_frame);

should be something like line 257

I've made this change, and a few other patches... but I guess I'm getting a bit behind on submitting those patches


BR,
-R


------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: v4l2sink plugin erroneously submitting the same buffer again

Guennadi Liakhovetski
On Mon, 8 Mar 2010, Clark, Rob wrote:

>
> On Mar 8, 2010, at 8:18 AM, Guennadi Liakhovetski wrote:
>
> > On Mon, 8 Mar 2010, Clark, Rob wrote:
> >
> >> Hi Guennadi,
> >>
> >> Could you send me a log w/ GST_DEBUG="*v4l2*:5"?
> >
> > Attached compressed. ASAIU, these two lines are interesting:
> >
> > 0:00:03.630077728 4m 10350m   0x43ed50 mLOG    0m 0m                v4l2 gstv4l2bufferpool.c:484:gst_v4l2_buffer_pool_qbuf:<v4l2sink0>0m enqueue pool buffer 0
> >
> > 0:00:03.737993377 4m 10350m   0x43ed50 mLOG    0m 0m                v4l2 gstv4l2bufferpool.c:484:gst_v4l2_buffer_pool_qbuf:<v4l2sink0>0m enqueue pool buffer 0
> >
> > in both cases buffer +0 is queued and the second one returns an error.
>
>
> Hmm, could you delete this line in gstv4l2sink.c:
>
>   basesink_class->preroll = GST_DEBUG_FUNCPTR (gst_v4l2sink_show_frame);
>
> should be something like line 257

Yes, the error is gone, and I see some blinking on the TV... Thanks!

> I've made this change, and a few other patches... but I guess I'm
> getting a bit behind on submitting those patches

Maybe you could find some time and submit those patches, or at least send
them to me for testing? Is there anything relevant for image-format
configuration in them?

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer
http://www.open-technology.de/

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: v4l2sink plugin erroneously submitting the same buffer again

Guennadi Liakhovetski
In reply to this post by Clark, Rob
Next question to v4l2sink: I observe, that the buffer queue in my driver
gets drained permanently. I.e., no new buffers get queued until all of the
existing ones are returned to the user. Is it a (gstreamer) design flaw or
just a lack of performance?

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer
http://www.open-technology.de/

------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: v4l2sink plugin erroneously submitting the same buffer again

Clark, Rob

On Mar 9, 2010, at 3:47 AM, Guennadi Liakhovetski wrote:

> Next question to v4l2sink: I observe, that the buffer queue in my driver
> gets drained permanently. I.e., no new buffers get queued until all of the
> existing ones are returned to the user. Is it a (gstreamer) design flaw or
> just a lack of performance?


hmm, as a sanity check, make clean in v4l2 directory.  A new field was added in GstV4l2Sink which controls when buffers get dequeued.. and some corruption because something wasn't recompiled could, I suppose, cause strange problems like this.

But if that isn't the issue, then please send a log.

BR,
-R


------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: v4l2sink plugin erroneously submitting the same buffer again

Guennadi Liakhovetski
On Tue, 9 Mar 2010, Rob Clark wrote:

>
> On Mar 9, 2010, at 3:47 AM, Guennadi Liakhovetski wrote:
>
> > Next question to v4l2sink: I observe, that the buffer queue in my driver
> > gets drained permanently. I.e., no new buffers get queued until all of the
> > existing ones are returned to the user. Is it a (gstreamer) design flaw or
> > just a lack of performance?
>
>
> hmm, as a sanity check, make clean in v4l2 directory.  A new field was
> added in GstV4l2Sink which controls when buffers get dequeued.. and some
> corruption because something wasn't recompiled could, I suppose, cause
> strange problems like this.
No, it's not that.

> But if that isn't the issue, then please send a log.

Log attached.

Thanks
Guennadi
---
Guennadi Liakhovetski, Ph.D.
Freelance Open-Source Software Developer
http://www.open-technology.de/
------------------------------------------------------------------------------
Download Intel&#174; Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/gstreamer-devel

gst.log.bz2 (10K) Download Attachment