summaryrefslogtreecommitdiff
path: root/src/gstreamer/gstlibcamera.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/gstreamer/gstlibcamera.c')
-rw-r--r--src/gstreamer/gstlibcamera.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/src/gstreamer/gstlibcamera.c b/src/gstreamer/gstlibcamera.c
index 7dd94ca0..81c7bb19 100644
--- a/src/gstreamer/gstlibcamera.c
+++ b/src/gstreamer/gstlibcamera.c
@@ -6,13 +6,19 @@
* gstlibcamera.c - GStreamer plugin
*/
+#include "gstlibcameraprovider.h"
#include "gstlibcamerasrc.h"
static gboolean
plugin_init(GstPlugin *plugin)
{
- return gst_element_register(plugin, "libcamerasrc", GST_RANK_PRIMARY,
- GST_TYPE_LIBCAMERA_SRC);
+ if (!gst_element_register(plugin, "libcamerasrc", GST_RANK_PRIMARY,
+ GST_TYPE_LIBCAMERA_SRC) ||
+ !gst_device_provider_register(plugin, "libcameraprovider",
+ GST_RANK_PRIMARY,
+ GST_TYPE_LIBCAMERA_PROVIDER))
+ return FALSE;
+
return TRUE;
}