1 /* GStreamer
2  * Copyright (C) <2009> Kapil Agrawal <kapil@mediamagictechnologies.com>
3  *
4  * gstopencv.cpp: plugin registering
5  *
6  * This library is free software; you can redistribute it and/or
7  * modify it under the terms of the GNU Library General Public
8  * License as published by the Free Software Foundation; either
9  * version 2 of the License, or (at your option) any later version.
10  *
11  * This library is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14  * Library General Public License for more details.
15  *
16  * You should have received a copy of the GNU Library General Public
17  * License along with this library; if not, write to the
18  * Free Software Foundation, Inc., 51 Franklin St, Fifth Floor,
19  * Boston, MA 02110-1301, USA.
20  */
21 
22 #ifdef HAVE_CONFIG_H
23 #include "config.h"
24 #endif
25 
26 #include "gstcvdilate.h"
27 #include "gstcvequalizehist.h"
28 #include "gstcverode.h"
29 #include "gstcvlaplace.h"
30 #include "gstcvsmooth.h"
31 #include "gstcvsobel.h"
32 #include "gstedgedetect.h"
33 #include "gstfaceblur.h"
34 #include "gstfacedetect.h"
35 #include "gstmotioncells.h"
36 #include "gsttemplatematch.h"
37 #include "gsttextoverlay.h"
38 #include "gsthanddetect.h"
39 #include "gstskindetect.h"
40 #include "gstretinex.h"
41 #include "gstsegmentation.h"
42 #include "gstgrabcut.h"
43 #include "gstdisparity.h"
44 #include "gstdewarp.h"
45 #include "gstcameracalibrate.h"
46 #include "gstcameraundistort.h"
47 
48 static gboolean
plugin_init(GstPlugin * plugin)49 plugin_init (GstPlugin * plugin)
50 {
51   if (!gst_cv_dilate_plugin_init (plugin))
52     return FALSE;
53 
54   if (!gst_cv_equalize_hist_plugin_init (plugin))
55     return FALSE;
56 
57   if (!gst_cv_erode_plugin_init (plugin))
58     return FALSE;
59 
60   if (!gst_cv_laplace_plugin_init (plugin))
61     return FALSE;
62 
63   if (!gst_cv_smooth_plugin_init (plugin))
64     return FALSE;
65 
66   if (!gst_cv_sobel_plugin_init (plugin))
67     return FALSE;
68 
69   if (!gst_edge_detect_plugin_init (plugin))
70     return FALSE;
71 
72   if (!gst_face_blur_plugin_init (plugin))
73     return FALSE;
74 
75   if (!gst_face_detect_plugin_init (plugin))
76     return FALSE;
77 
78   if (!gst_motion_cells_plugin_init (plugin))
79     return FALSE;
80 
81   if (!gst_template_match_plugin_init (plugin))
82     return FALSE;
83 
84   if (!gst_opencv_text_overlay_plugin_init (plugin))
85     return FALSE;
86 
87   if (!gst_handdetect_plugin_init (plugin))
88     return FALSE;
89 
90   if (!gst_skin_detect_plugin_init (plugin))
91     return FALSE;
92 
93   if (!gst_retinex_plugin_init (plugin))
94     return FALSE;
95 
96   if (!gst_segmentation_plugin_init (plugin))
97     return FALSE;
98 
99   if (!gst_grabcut_plugin_init (plugin))
100     return FALSE;
101 
102   if (!gst_disparity_plugin_init (plugin))
103     return FALSE;
104 
105   if (!gst_dewarp_plugin_init (plugin))
106     return FALSE;
107 
108   if (!gst_camera_calibrate_plugin_init (plugin))
109     return FALSE;
110 
111   if (!gst_camera_undistort_plugin_init (plugin))
112     return FALSE;
113 
114   return TRUE;
115 }
116 
117 GST_PLUGIN_DEFINE (GST_VERSION_MAJOR,
118     GST_VERSION_MINOR,
119     opencv,
120     "GStreamer OpenCV Plugins",
121     plugin_init, VERSION, "LGPL", GST_PACKAGE_NAME, GST_PACKAGE_ORIGIN)
122