mirror of
https://gitlab.freedesktop.org/gstreamer/gstreamer.git
synced 2025-02-22 22:16:22 +00:00
v4l2bufferpool: don't block when resurecting a buffer
When we are resurecting a buffer, don't block. instead let us copy a buffer.
This commit is contained in:
parent
5e00c012d2
commit
b208ae72ee
1 changed files with 3 additions and 1 deletions
|
@ -676,7 +676,8 @@ gst_v4l2_buffer_pool_resurect_buffer (GstV4l2BufferPool * pool)
|
|||
GST_DEBUG_OBJECT (pool, "A buffer was lost, reallocating it");
|
||||
|
||||
params.flags =
|
||||
(GstBufferPoolAcquireFlags) GST_V4L2_BUFFER_POOL_ACQUIRE_FLAG_RESURRECT;
|
||||
(GstBufferPoolAcquireFlags) GST_V4L2_BUFFER_POOL_ACQUIRE_FLAG_RESURRECT |
|
||||
GST_BUFFER_POOL_ACQUIRE_FLAG_DONTWAIT;
|
||||
ret =
|
||||
gst_buffer_pool_acquire_buffer (GST_BUFFER_POOL (pool), &buffer, ¶ms);
|
||||
|
||||
|
@ -1765,6 +1766,7 @@ gst_v4l2_buffer_pool_process (GstV4l2BufferPool * pool, GstBuffer ** buf)
|
|||
*buf = copy;
|
||||
}
|
||||
|
||||
ret = GST_FLOW_OK;
|
||||
/* nothing, data was inside the buffer when we did _acquire() */
|
||||
goto done;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue