}
if (buf) {
+ GST_V4L2_BUFFER_POOL_LOCK (pool);
GST_BUFFER_SIZE (buf) = buf->vbuffer.length;
GST_BUFFER_FLAG_UNSET (buf, 0xffffffff);
+ GST_V4L2_BUFFER_POOL_UNLOCK (pool);
}
pool->running = TRUE;
GST_DEBUG_OBJECT (pool->v4l2elem, "num_live_buffers++: %d",
pool->num_live_buffers);
- GST_V4L2_BUFFER_POOL_UNLOCK (pool);
-
/* set top/bottom field first if v4l2_buffer has the information */
if (buffer.field == V4L2_FIELD_INTERLACED_TB)
GST_BUFFER_FLAG_SET (pool_buffer, GST_VIDEO_BUFFER_TFF);
/* this can change at every frame, esp. with jpeg */
GST_BUFFER_SIZE (pool_buffer) = buffer.bytesused;
+ GST_V4L2_BUFFER_POOL_UNLOCK (pool);
+
return pool_buffer;
}