}
if (resuscitated) {
- /* FIXME: check that the caps didn't change */
GST_LOG_OBJECT (pool->v4l2elem, "reviving buffer %p, %d", buffer, index);
gst_buffer_ref (buffer);
pool->buffers[index] = buffer;
}
static GstBuffer *
-gst_v4l2_buffer_new (GstV4l2BufferPool * pool, guint index, GstCaps * caps)
+gst_v4l2_buffer_new (GstV4l2BufferPool * pool, guint index)
{
GstBuffer *ret;
GstMetaV4l2 *meta;
* @v4l2elem: the v4l2 element (src or sink) that owns this pool
* @fd: the video device file descriptor
* @num_buffers: the requested number of buffers in the pool
- * @caps: the caps to set on the buffer
* @requeuebuf: if %TRUE, and if the pool is still in the running state, a
* buffer with no remaining references is immediately passed back to v4l2
* (VIDIOC_QBUF), otherwise it is returned to the pool of available buffers
*/
GstV4l2BufferPool *
gst_v4l2_buffer_pool_new (GstElement * v4l2elem, gint fd, gint num_buffers,
- GstCaps * caps, gboolean requeuebuf, enum v4l2_buf_type type)
+ gboolean requeuebuf, enum v4l2_buf_type type)
{
GstV4l2BufferPool *pool;
gint n;
/* now, map the buffers: */
for (n = 0; n < num_buffers; n++) {
- pool->buffers[n] = gst_v4l2_buffer_new (pool, n, caps);
+ pool->buffers[n] = gst_v4l2_buffer_new (pool, n);
if (!pool->buffers[n])
goto buffer_new_failed;
pool->num_live_buffers++;
#define GST_META_V4L2_ADD(buf) ((GstMetaV4l2 *)gst_buffer_add_meta(buf,gst_meta_v4l2_get_info(),NULL))
void gst_v4l2_buffer_pool_destroy (GstV4l2BufferPool * pool);
-GstV4l2BufferPool *gst_v4l2_buffer_pool_new (GstElement *v4l2elem, gint fd, gint num_buffers, GstCaps * caps, gboolean requeuebuf, enum v4l2_buf_type type);
+GstV4l2BufferPool *gst_v4l2_buffer_pool_new (GstElement *v4l2elem, gint fd, gint num_buffers, gboolean requeuebuf, enum v4l2_buf_type type);
GstBuffer *gst_v4l2_buffer_pool_get (GstV4l2BufferPool *pool, gboolean blocking);
newpool = gst_v4l2_buffer_pool_new (GST_ELEMENT (v4l2sink),
v4l2sink->v4l2object->video_fd,
- v4l2sink->num_buffers, caps, FALSE, V4L2_BUF_TYPE_VIDEO_OUTPUT);
+ v4l2sink->num_buffers, FALSE, V4L2_BUF_TYPE_VIDEO_OUTPUT);
if (newpool == NULL)
goto no_pool;
if (!(v4l2src->pool = gst_v4l2_buffer_pool_new (GST_ELEMENT (v4l2src),
v4l2src->v4l2object->video_fd,
- v4l2src->num_buffers, caps, TRUE, V4L2_BUF_TYPE_VIDEO_CAPTURE)))
+ v4l2src->num_buffers, TRUE, V4L2_BUF_TYPE_VIDEO_CAPTURE)))
goto buffer_pool_new_failed;
GST_INFO_OBJECT (v4l2src, "capturing buffers via mmap()");