gst_buffer_pool_config_has_option (config,
GST_BUFFER_POOL_OPTION_VIDEO_META);
+ pool->add_cropmeta =
+ gst_buffer_pool_config_has_option (config,
+ GST_V4L2_BUFFER_POOL_OPTION_CROP_META);
+
if (!pool->add_videometa && obj->need_video_meta)
goto missing_video_api;
+ if (!pool->add_cropmeta && obj->need_crop_meta)
+ goto missing_crop_api;
+
/* parse the config and keep around */
if (!gst_buffer_pool_config_get_params (config, &caps, &size, &min_buffers,
&max_buffers))
/* ERRORS */
missing_video_api:
{
- GST_ERROR_OBJECT (pool, "missing GstMetaVideo API in config");
+ GST_ERROR_OBJECT (pool, "missing GstVideoMeta API in config");
+ return FALSE;
+ }
+missing_crop_api:
+ {
+ GST_ERROR_OBJECT (pool, "missing GstVideoCropMeta API");
return FALSE;
}
wrong_config:
#define GST_V4L2_BUFFER_POOL(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), GST_TYPE_V4L2_BUFFER_POOL, GstV4l2BufferPool))
#define GST_V4L2_BUFFER_POOL_CAST(obj) ((GstV4l2BufferPool*)(obj))
+#define GST_V4L2_BUFFER_POOL_OPTION_CROP_META "GstV4l2BufferPoolOptionCropMeta"
+
struct _GstV4l2BufferPool
{
GstBufferPool parent;