diff --git a/CMakeLists.txt b/CMakeLists.txt index dbb39538..5a90d739 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -113,9 +113,9 @@ if(OPENCV_HAVE_OPTFLOW) endif() ## Macro to add nodelets -macro(opencv_apps_add_nodelet node_name nodelet_name nodelet_cppfile) +macro(opencv_apps_add_nodelet node_name nodelet_cppfile) set(NODE_NAME ${node_name}) - set(NODELET_NAME ${nodelet_name}) + set(NODELET_NAME opencv_apps/${node_name}) configure_file(src/node/standalone_nodelet_exec.cpp.in ${node_name}.cpp @ONLY) add_executable(${node_name}_exe ${node_name}.cpp) SET_TARGET_PROPERTIES(${node_name}_exe PROPERTIES OUTPUT_NAME ${node_name}) @@ -133,8 +133,8 @@ endmacro() # ./tutorial_code/calib3d/stereoBM/SBM_Sample.cpp # core -opencv_apps_add_nodelet(adding_images adding_images/adding_images src/nodelet/adding_images_nodelet.cpp) # ./tutorial_code/core/AddingImages/AddingImages.cpp -opencv_apps_add_nodelet(discrete_fourier_transform discrete_fourier_transform/discrete_fourier_transform src/nodelet/discrete_fourier_transform_nodelet.cpp) # ./tutorial_code/core/discrete_fourier_transform/discrete_fourier_transform.cpp +opencv_apps_add_nodelet(adding_images src/nodelet/adding_images_nodelet.cpp) # ./tutorial_code/core/AddingImages/AddingImages.cpp +opencv_apps_add_nodelet(discrete_fourier_transform src/nodelet/discrete_fourier_transform_nodelet.cpp) # ./tutorial_code/core/discrete_fourier_transform/discrete_fourier_transform.cpp # ./tutorial_code/core/file_input_output/file_input_output.cpp # ./tutorial_code/core/how_to_scan_images/how_to_scan_images.cpp # ./tutorial_code/core/interoperability_with_OpenCV_1/interoperability_with_OpenCV_1.cpp @@ -169,19 +169,19 @@ opencv_apps_add_nodelet(discrete_fourier_transform discrete_fourier_transform/di # ./tutorial_code/ImgProc/Morphology_1.cpp # ./tutorial_code/ImgProc/Morphology_2.cpp # ./tutorial_code/ImgProc/Morphology_3.cpp -opencv_apps_add_nodelet(pyramids pyramids/pyramids src/nodelet/pyramids_nodelet.cpp) # ./tutorial_code/ImgProc/Pyramids.cpp -opencv_apps_add_nodelet(smoothing smoothing/smoothing src/nodelet/smoothing_nodelet.cpp) # ./tutorial_code/ImgProc/Smoothing.cpp -opencv_apps_add_nodelet(threshold threshold/threshold src/nodelet/threshold_nodelet.cpp) # ./tutorial_code/ImgProc/Threshold.cpp -opencv_apps_add_nodelet(rgb_color_filter rgb_color_filter/rgb_color_filter src/nodelet/color_filter_nodelet.cpp) # ./tutorial_code/ImgProc/Threshold_inRange.cpp -opencv_apps_add_nodelet(hls_color_filter hls_color_filter/hls_color_filter src/nodelet/color_filter_nodelet.cpp) # ./tutorial_code/ImgProc/Threshold_inRange.cpp -opencv_apps_add_nodelet(hsv_color_filter hsv_color_filter/hsv_color_filter src/nodelet/color_filter_nodelet.cpp) # ./tutorial_code/ImgProc/Threshold_inRange.cpp +opencv_apps_add_nodelet(pyramids src/nodelet/pyramids_nodelet.cpp) # ./tutorial_code/ImgProc/Pyramids.cpp +opencv_apps_add_nodelet(smoothing src/nodelet/smoothing_nodelet.cpp) # ./tutorial_code/ImgProc/Smoothing.cpp +opencv_apps_add_nodelet(threshold src/nodelet/threshold_nodelet.cpp) # ./tutorial_code/ImgProc/Threshold.cpp +opencv_apps_add_nodelet(rgb_color_filter src/nodelet/color_filter_nodelet.cpp) # ./tutorial_code/ImgProc/Threshold_inRange.cpp +opencv_apps_add_nodelet(hls_color_filter src/nodelet/color_filter_nodelet.cpp) # ./tutorial_code/ImgProc/Threshold_inRange.cpp +opencv_apps_add_nodelet(hsv_color_filter src/nodelet/color_filter_nodelet.cpp) # ./tutorial_code/ImgProc/Threshold_inRange.cpp # ImgTrans -opencv_apps_add_nodelet(edge_detection edge_detection/edge_detection src/nodelet/edge_detection_nodelet.cpp) # ./tutorial_code/ImgTrans/CannyDetector_Demo.cpp +opencv_apps_add_nodelet(edge_detection src/nodelet/edge_detection_nodelet.cpp) # ./tutorial_code/ImgTrans/CannyDetector_Demo.cpp # ./tutorial_code/ImgTrans/Laplace_Demo.cpp # ./tutorial_code/ImgTrans/Sobel_Demo.cpp -opencv_apps_add_nodelet(hough_lines hough_lines/hough_lines src/nodelet/hough_lines_nodelet.cpp) # ./tutorial_code/ImgTrans/HoughLines_Demo.cpp -opencv_apps_add_nodelet(hough_circles hough_circles/hough_circles src/nodelet/hough_circles_nodelet.cpp) # ./tutorial_code/ImgTrans/HoughCircle_Demo.cpp +opencv_apps_add_nodelet(hough_lines src/nodelet/hough_lines_nodelet.cpp) # ./tutorial_code/ImgTrans/HoughLines_Demo.cpp +opencv_apps_add_nodelet(hough_circles src/nodelet/hough_circles_nodelet.cpp) # ./tutorial_code/ImgTrans/HoughCircle_Demo.cpp # ./tutorial_code/ImgTrans/copyMakeBorder_demo.cpp # ./tutorial_code/ImgTrans/filter2D_demo.cpp # ./tutorial_code/ImgTrans/Geometric_Transforms_Demo.cpp @@ -209,17 +209,17 @@ opencv_apps_add_nodelet(hough_circles hough_circles/hough_circles src/nodelet/ho # ./tutorial_code/photo/seamless_cloning/cloning_gui.cpp # ShapeDescriptors -opencv_apps_add_nodelet(find_contours find_contours/find_contours src/nodelet/find_contours_nodelet.cpp) # ./tutorial_code/ShapeDescriptors/findContours_demo.cpp -opencv_apps_add_nodelet(convex_hull convex_hull/convex_hull src/nodelet/convex_hull_nodelet.cpp) # ./tutorial_code/ShapeDescriptors/hull_demo.cpp -opencv_apps_add_nodelet(general_contours general_contours/general_contours src/nodelet/general_contours_nodelet.cpp) # ./tutorial_code/ShapeDescriptors/generalContours_demo2.cpp -opencv_apps_add_nodelet(contour_moments contour_moments/contour_moments src/nodelet/contour_moments_nodelet.cpp) # ./tutorial_code/ShapeDescriptors/moments_demo.cpp +opencv_apps_add_nodelet(find_contours src/nodelet/find_contours_nodelet.cpp) # ./tutorial_code/ShapeDescriptors/findContours_demo.cpp +opencv_apps_add_nodelet(convex_hull src/nodelet/convex_hull_nodelet.cpp) # ./tutorial_code/ShapeDescriptors/hull_demo.cpp +opencv_apps_add_nodelet(general_contours src/nodelet/general_contours_nodelet.cpp) # ./tutorial_code/ShapeDescriptors/generalContours_demo2.cpp +opencv_apps_add_nodelet(contour_moments src/nodelet/contour_moments_nodelet.cpp) # ./tutorial_code/ShapeDescriptors/moments_demo.cpp # ./tutorial_code/ShapeDescriptors/generalContours_demo1.cpp # ./tutorial_code/ShapeDescriptors/pointPolygonTest_demo.cpp # TrackingMotion -opencv_apps_add_nodelet(goodfeature_track goodfeature_track/goodfeature_track src/nodelet/goodfeature_track_nodelet.cpp) # ./tutorial_code/TrackingMotion/goodFeaturesToTrack_Demo.cpp +opencv_apps_add_nodelet(goodfeature_track src/nodelet/goodfeature_track_nodelet.cpp) # ./tutorial_code/TrackingMotion/goodFeaturesToTrack_Demo.cpp # ./tutorial_code/TrackingMotion/cornerDetector_Demo.cpp -opencv_apps_add_nodelet(corner_harris corner_harris/corner_harris src/nodelet/corner_harris_nodelet.cpp) # ./tutorial_code/TrackingMotion/cornerHarris_Demo.cpp +opencv_apps_add_nodelet(corner_harris src/nodelet/corner_harris_nodelet.cpp) # ./tutorial_code/TrackingMotion/cornerHarris_Demo.cpp # ./tutorial_code/TrackingMotion/cornerSubPix_Demo.cpp # videoio @@ -240,7 +240,7 @@ opencv_apps_add_nodelet(corner_harris corner_harris/corner_harris src/nodelet/co # ./autofocus.cpp # ./bgfg_segm.cpp # ./calibration.cpp -opencv_apps_add_nodelet(camshift camshift/camshift src/nodelet/camshift_nodelet.cpp) # ./camshiftdemo.cpp +opencv_apps_add_nodelet(camshift src/nodelet/camshift_nodelet.cpp) # ./camshiftdemo.cpp # ./cloning_demo.cpp # ./cloning_gui.cpp # ./connected_components.cpp @@ -259,10 +259,10 @@ opencv_apps_add_nodelet(camshift camshift/camshift src/nodelet/camshift_nodelet. # ./edge.cpp # ./em.cpp # ./example_cmake/example.cpp -opencv_apps_add_nodelet(face_detection face_detection/face_detection src/nodelet/face_detection_nodelet.cpp) # ./facedetect.cpp -opencv_apps_add_nodelet(face_recognition face_recognition/face_recognition src/nodelet/face_recognition_nodelet.cpp) +opencv_apps_add_nodelet(face_detection src/nodelet/face_detection_nodelet.cpp) # ./facedetect.cpp +opencv_apps_add_nodelet(face_recognition src/nodelet/face_recognition_nodelet.cpp) # ./facial_features.cpp -opencv_apps_add_nodelet(fback_flow fback_flow/fback_flow src/nodelet/fback_flow_nodelet.cpp) # ./fback.cpp +opencv_apps_add_nodelet(fback_flow src/nodelet/fback_flow_nodelet.cpp) # ./fback.cpp # ./ffilldemo.cpp # ./filestorage_base64.cpp # ./filestorage.cpp @@ -280,7 +280,7 @@ opencv_apps_add_nodelet(fback_flow fback_flow/fback_flow src/nodelet/fback_flow_ # ./kmeans.cpp # ./laplace.cpp # ./letter_recog.cpp -opencv_apps_add_nodelet(lk_flow lk_flow/lk_flow src/nodelet/lk_flow_nodelet.cpp) # ./lkdemo.cpp +opencv_apps_add_nodelet(lk_flow src/nodelet/lk_flow_nodelet.cpp) # ./lkdemo.cpp # ./logistic_regression.cpp # ./lsd_lines.cpp # ./mask_tmpl.cpp @@ -292,11 +292,11 @@ opencv_apps_add_nodelet(lk_flow lk_flow/lk_flow src/nodelet/lk_flow_nodelet.cpp) # ./opencv_version.cpp # ./openni_capture.cpp # ./pca.cpp -opencv_apps_add_nodelet(people_detect people_detect/people_detect src/nodelet/people_detect_nodelet.cpp) # ./peopledetect.cpp -opencv_apps_add_nodelet(phase_corr phase_corr/phase_corr src/nodelet/phase_corr_nodelet.cpp) # ./phase_corr.cpp +opencv_apps_add_nodelet(people_detect src/nodelet/people_detect_nodelet.cpp) # ./peopledetect.cpp +opencv_apps_add_nodelet(phase_corr src/nodelet/phase_corr_nodelet.cpp) # ./phase_corr.cpp # ./points_classifier.cpp # ./polar_transforms.cpp -opencv_apps_add_nodelet(segment_objects segment_objects/segment_objects src/nodelet/segment_objects_nodelet.cpp) # ./segment_objects.cpp +opencv_apps_add_nodelet(segment_objects src/nodelet/segment_objects_nodelet.cpp) # ./segment_objects.cpp # ./select3dobj.cpp # ./shape_example.cpp # ./smiledetect.cpp @@ -312,16 +312,16 @@ opencv_apps_add_nodelet(segment_objects segment_objects/segment_objects src/node # ./tree_engine.cpp # ./tvl1_optical_flow.cpp # ./videostab.cpp -opencv_apps_add_nodelet(watershed_segmentation watershed_segmentation/watershed_segmentation src/nodelet/watershed_segmentation_nodelet.cpp) # ./watershed.cpp +opencv_apps_add_nodelet(watershed_segmentation src/nodelet/watershed_segmentation_nodelet.cpp) # ./watershed.cpp # ros examples -opencv_apps_add_nodelet(simple_example simple_example/simple_example src/nodelet/simple_example_nodelet.cpp) -opencv_apps_add_nodelet(simple_compressed_example simple_compressed_example/simple_compressed_example src/nodelet/simple_compressed_example_nodelet.cpp) +opencv_apps_add_nodelet(simple_example src/nodelet/simple_example_nodelet.cpp) +opencv_apps_add_nodelet(simple_compressed_example src/nodelet/simple_compressed_example_nodelet.cpp) # https://github.com/Itseez/opencv/blob/2.4/samples/cpp/simpleflow_demo.cpp # simple flow requires opencv-contrib https://github.com/ros-perception/vision_opencv/issues/108 if(OPENCV_HAVE_OPTFLOW) - opencv_apps_add_nodelet(simple_flow simple_flow/simple_flow src/nodelet/simple_flow_nodelet.cpp) + opencv_apps_add_nodelet(simple_flow src/nodelet/simple_flow_nodelet.cpp) endif() # https://github.com/opencv/opencv/blob/2.4/samples/cpp/bgfg_gmg.cpp # https://github.com/opencv/opencv/blob/2.4/samples/cpp/hybridtrackingsample.cpp diff --git a/cfg/AddingImages.cfg b/cfg/AddingImages.cfg index a5fd7712..f7a8c053 100755 --- a/cfg/AddingImages.cfg +++ b/cfg/AddingImages.cfg @@ -1,6 +1,6 @@ #! /usr/bin/env python -PACKAGE='adding_images' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/CamShift.cfg b/cfg/CamShift.cfg index 863f9050..b7b2b9ad 100755 --- a/cfg/CamShift.cfg +++ b/cfg/CamShift.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='camshift' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/ContourMoments.cfg b/cfg/ContourMoments.cfg index 22401190..1921746b 100755 --- a/cfg/ContourMoments.cfg +++ b/cfg/ContourMoments.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='contour_moments' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/ConvexHull.cfg b/cfg/ConvexHull.cfg index 04258b8e..a8fed5cc 100755 --- a/cfg/ConvexHull.cfg +++ b/cfg/ConvexHull.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='convex_hull' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/CornerHarris.cfg b/cfg/CornerHarris.cfg index 8afa456b..6c03285b 100755 --- a/cfg/CornerHarris.cfg +++ b/cfg/CornerHarris.cfg @@ -1,6 +1,6 @@ #!/usr/bin/env python -PACKAGE='corner_harris' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/DiscreteFourierTransform.cfg b/cfg/DiscreteFourierTransform.cfg index 216ce697..d73852bd 100755 --- a/cfg/DiscreteFourierTransform.cfg +++ b/cfg/DiscreteFourierTransform.cfg @@ -1,6 +1,6 @@ #! /usr/bin/env python -PACKAGE='discrete_fourier_transform' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/EdgeDetection.cfg b/cfg/EdgeDetection.cfg index c27aeb7e..f6d41e39 100755 --- a/cfg/EdgeDetection.cfg +++ b/cfg/EdgeDetection.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='edge_detection' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/FBackFlow.cfg b/cfg/FBackFlow.cfg index 6c5a1fe3..43dee850 100755 --- a/cfg/FBackFlow.cfg +++ b/cfg/FBackFlow.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='fback_flow' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/FaceDetection.cfg b/cfg/FaceDetection.cfg index f263819c..498297c3 100755 --- a/cfg/FaceDetection.cfg +++ b/cfg/FaceDetection.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='face_detection' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/FaceRecognition.cfg b/cfg/FaceRecognition.cfg index bdff7139..5950f4ed 100755 --- a/cfg/FaceRecognition.cfg +++ b/cfg/FaceRecognition.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='face_recognition' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/FindContours.cfg b/cfg/FindContours.cfg index 9b8b9d5d..59e1c92b 100755 --- a/cfg/FindContours.cfg +++ b/cfg/FindContours.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='find_contours' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/GeneralContours.cfg b/cfg/GeneralContours.cfg index 50d4c7f2..8648384f 100755 --- a/cfg/GeneralContours.cfg +++ b/cfg/GeneralContours.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='general_contours' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/GoodfeatureTrack.cfg b/cfg/GoodfeatureTrack.cfg index d3ccdc98..aac9c81b 100755 --- a/cfg/GoodfeatureTrack.cfg +++ b/cfg/GoodfeatureTrack.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='goodfeature_track' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/HLSColorFilter.cfg b/cfg/HLSColorFilter.cfg index ed173cd9..0e5e56a4 100755 --- a/cfg/HLSColorFilter.cfg +++ b/cfg/HLSColorFilter.cfg @@ -1,6 +1,6 @@ #!/usr/bin/env python -PACKAGE='color_filter' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/HSIColorFilter.cfg b/cfg/HSIColorFilter.cfg index 4176e161..3cf30969 100755 --- a/cfg/HSIColorFilter.cfg +++ b/cfg/HSIColorFilter.cfg @@ -1,6 +1,6 @@ #!/usr/bin/env python -PACKAGE='color_filter' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/HSVColorFilter.cfg b/cfg/HSVColorFilter.cfg index 15d359c1..2df971bb 100755 --- a/cfg/HSVColorFilter.cfg +++ b/cfg/HSVColorFilter.cfg @@ -1,6 +1,6 @@ #!/usr/bin/env python -PACKAGE='color_filter' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/HoughCircles.cfg b/cfg/HoughCircles.cfg index d77edca3..269b4759 100755 --- a/cfg/HoughCircles.cfg +++ b/cfg/HoughCircles.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='hough_circles' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/HoughLines.cfg b/cfg/HoughLines.cfg index 99b026f2..18890830 100755 --- a/cfg/HoughLines.cfg +++ b/cfg/HoughLines.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='hough_lines' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/LKFlow.cfg b/cfg/LKFlow.cfg index cdbc9d3d..dca7c9a9 100755 --- a/cfg/LKFlow.cfg +++ b/cfg/LKFlow.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='lk_flow' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/PeopleDetect.cfg b/cfg/PeopleDetect.cfg index 3ef16d15..b0a0be08 100755 --- a/cfg/PeopleDetect.cfg +++ b/cfg/PeopleDetect.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='people_detect' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/PhaseCorr.cfg b/cfg/PhaseCorr.cfg index 94480822..956ced28 100755 --- a/cfg/PhaseCorr.cfg +++ b/cfg/PhaseCorr.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='phase_corr' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/Pyramids.cfg b/cfg/Pyramids.cfg index 906475d1..57ccfa5b 100755 --- a/cfg/Pyramids.cfg +++ b/cfg/Pyramids.cfg @@ -1,6 +1,6 @@ #! /usr/bin/env python -PACKAGE='pyramids' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/RGBColorFilter.cfg b/cfg/RGBColorFilter.cfg index b574c379..f76c5360 100755 --- a/cfg/RGBColorFilter.cfg +++ b/cfg/RGBColorFilter.cfg @@ -1,6 +1,6 @@ #!/usr/bin/env python -PACKAGE='color_filter' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/SegmentObjects.cfg b/cfg/SegmentObjects.cfg index c0c604eb..6bb3d9b3 100755 --- a/cfg/SegmentObjects.cfg +++ b/cfg/SegmentObjects.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='segment_objects' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/SimpleFlow.cfg b/cfg/SimpleFlow.cfg index 9bf9baf2..a7f06aad 100755 --- a/cfg/SimpleFlow.cfg +++ b/cfg/SimpleFlow.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='simple_flow' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/Smoothing.cfg b/cfg/Smoothing.cfg index 489a242b..bb09ac89 100755 --- a/cfg/Smoothing.cfg +++ b/cfg/Smoothing.cfg @@ -1,6 +1,6 @@ #!/usr/bin/env python -PACKAGE = 'smoothing' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import *; diff --git a/cfg/Threshold.cfg b/cfg/Threshold.cfg index 232b6f25..f7e335b1 100755 --- a/cfg/Threshold.cfg +++ b/cfg/Threshold.cfg @@ -1,6 +1,6 @@ #! /usr/bin/env python -PACKAGE='threshold' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/cfg/WatershedSegmentation.cfg b/cfg/WatershedSegmentation.cfg index db9d638f..79dda9ab 100755 --- a/cfg/WatershedSegmentation.cfg +++ b/cfg/WatershedSegmentation.cfg @@ -32,7 +32,7 @@ # POSSIBILITY OF SUCH DAMAGE. -PACKAGE='watershed_segmentation' +PACKAGE = "opencv_apps" from dynamic_reconfigure.parameter_generator_catkin import * diff --git a/nodelet_plugins.xml b/nodelet_plugins.xml index 1de89dfd..8c473265 100644 --- a/nodelet_plugins.xml +++ b/nodelet_plugins.xml @@ -1,118 +1,150 @@ - + Nodelet to combine two images - + Nodelet to fourier transform - + Nodelet to smoothing by homogeneous filter, bilateral filter, gaussian filter, median filter - + Nodelet to process image pyramids - + Nodelet to find edges - + Nodelet to find lines - + Nodelet to find circles - + Nodelet to find contours - + Nodelet to find convex hulls - + Nodelet to creating bounding boxes and circles for contours - + Nodelet to find image moments - + Nodelet to find faces - + Nodelet to identify faces - + Nodelet for detecting corners using Shi-Tomasi method - + Nodelet for detecting corners using Harris method - + Nodelet to show mean-shift based tracking - + Nodelet to demonstrates dense optical flow algorithm by Gunnar Farneback - + Nodelet to calculate Lukas-Kanade optical flow - + Nodelet to demonstrate the use of the HoG descriptor - + Nodelet to demonstrate the use of phaseCorrelate - + Nodelet to demonstrate a simple method of connected components clean up of background subtraction - + Nodelet of SimpleFlow optical flow algorithm - + Nodelet of Simple Example from wiki - + Nodelet of Simple Example from wiki - + Nodelet of threshold - + Nodelet of rgb color filter - + Nodelet of hls color filter - + Nodelet of hsv color filter - + Nodelet to demonstrate the famous watershed segmentation algorithm in OpenCV: watershed() + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/src/nodelet/adding_images_nodelet.cpp b/src/nodelet/adding_images_nodelet.cpp index 7b47af7d..e2f5cddd 100644 --- a/src/nodelet/adding_images_nodelet.cpp +++ b/src/nodelet/adding_images_nodelet.cpp @@ -55,7 +55,7 @@ #include "opencv_apps/AddingImagesConfig.h" #include "opencv_apps/nodelet.h" -namespace adding_images { +namespace opencv_apps { class AddingImagesNodelet : public opencv_apps::Nodelet { private: boost::shared_ptr it_; @@ -72,7 +72,7 @@ namespace adding_images { //////////////////////////////////////////////////////// // Dynamic Reconfigure //////////////////////////////////////////////////////// - typedef adding_images::AddingImagesConfig Config; + typedef opencv_apps::AddingImagesConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -255,7 +255,20 @@ namespace adding_images { onInitPostProcess(); } }; -} +} // namespace opencv_apps + +namespace adding_images { +class AddingImagesNodelet : public opencv_apps::AddingImagesNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet adding_images/adding_images is deprecated, " + "and renamed to opencv_apps/adding_images."); + opencv_apps::AddingImagesNodelet::onInit(); + } +}; +} // namespace adding_images + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::AddingImagesNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(adding_images::AddingImagesNodelet, nodelet::Nodelet); diff --git a/src/nodelet/camshift_nodelet.cpp b/src/nodelet/camshift_nodelet.cpp index 7c3223c5..0b88ddb5 100644 --- a/src/nodelet/camshift_nodelet.cpp +++ b/src/nodelet/camshift_nodelet.cpp @@ -56,7 +56,7 @@ #include "opencv_apps/CamShiftConfig.h" #include "opencv_apps/RotatedRectStamped.h" -namespace camshift { +namespace opencv_apps { class CamShiftNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_, bproj_pub_; @@ -66,7 +66,7 @@ class CamShiftNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef camshift::CamShiftConfig Config; + typedef opencv_apps::CamShiftConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -427,7 +427,20 @@ bool CamShiftNodelet::on_mouse_update_ = false; int CamShiftNodelet::on_mouse_event_ = 0; int CamShiftNodelet::on_mouse_x_ = 0; int CamShiftNodelet::on_mouse_y_ = 0; -} +} // namespace opencv_apps + +namespace camshift { +class CamShiftNodelet : public opencv_apps::CamShiftNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet camshift/camshift is deprecated, " + "and renamed to opencv_apps/camshift."); + opencv_apps::CamShiftNodelet::onInit(); + } +}; +} // namespace camshift + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::CamShiftNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(camshift::CamShiftNodelet, nodelet::Nodelet); diff --git a/src/nodelet/color_filter_nodelet.cpp b/src/nodelet/color_filter_nodelet.cpp index a64e94d4..891c9328 100644 --- a/src/nodelet/color_filter_nodelet.cpp +++ b/src/nodelet/color_filter_nodelet.cpp @@ -47,6 +47,12 @@ #include "opencv_apps/HSVColorFilterConfig.h" namespace color_filter { +class RGBColorFilterNodelet; +class HLSColorFilterNodelet; +class HSVColorFilterNodelet; +} + +namespace opencv_apps { class RGBColorFilter; class HLSColorFilter; class HSVColorFilter; @@ -177,7 +183,7 @@ class ColorFilterNodelet : public opencv_apps::Nodelet }; class RGBColorFilterNodelet - : public ColorFilterNodelet { + : public ColorFilterNodelet { protected: int r_min_; int r_max_; @@ -186,7 +192,7 @@ class RGBColorFilterNodelet int g_min_; int g_max_; - virtual void reconfigureCallback(color_filter::RGBColorFilterConfig& config, + virtual void reconfigureCallback(opencv_apps::RGBColorFilterConfig& config, uint32_t level) { boost::mutex::scoped_lock lock(mutex_); config_ = config; @@ -212,7 +218,7 @@ class RGBColorFilterNodelet output_image); } -private: +protected: virtual void onInit() { r_max_ = 255; r_min_ = 0; @@ -223,10 +229,13 @@ class RGBColorFilterNodelet ColorFilterNodelet::onInit(); } + friend class color_filter::RGBColorFilterNodelet; + friend class color_filter::HLSColorFilterNodelet; + friend class color_filter::HSVColorFilterNodelet; }; class HLSColorFilterNodelet - : public ColorFilterNodelet { + : public ColorFilterNodelet { protected: int h_min_; int h_max_; @@ -235,7 +244,7 @@ class HLSColorFilterNodelet int l_min_; int l_max_; - virtual void reconfigureCallback(color_filter::HLSColorFilterConfig& config, + virtual void reconfigureCallback(opencv_apps::HLSColorFilterConfig& config, uint32_t level) { boost::mutex::scoped_lock lock(mutex_); config_ = config; @@ -287,7 +296,7 @@ class HLSColorFilterNodelet }; class HSVColorFilterNodelet - : public ColorFilterNodelet { + : public ColorFilterNodelet { protected: int h_min_; int h_max_; @@ -296,7 +305,7 @@ class HSVColorFilterNodelet int v_min_; int v_max_; - virtual void reconfigureCallback(color_filter::HSVColorFilterConfig& config, + virtual void reconfigureCallback(opencv_apps::HSVColorFilterConfig& config, uint32_t level) { boost::mutex::scoped_lock lock(mutex_); config_ = config; @@ -347,12 +356,40 @@ class HSVColorFilterNodelet } }; -} +} // namespace opencv_apps + +namespace color_filter { +class RGBColorFilterNodelet : public opencv_apps::RGBColorFilterNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet rgb_color_filter/rgb_color_filter is deprecated, " + "and renamed to opencv_apps/rgb_color_filter."); + opencv_apps::RGBColorFilterNodelet::onInit(); + } +}; +class HLSColorFilterNodelet : public opencv_apps::HLSColorFilterNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet hls_color_filter/hls_color_filter is deprecated, " + "and renamed to opencv_apps/hls_color_filter."); + opencv_apps::HLSColorFilterNodelet::onInit(); + } +}; +class HSVColorFilterNodelet : public opencv_apps::HSVColorFilterNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet hsv_color_filter/hsv_color_filter is deprecated, " + "and renamed to opencv_apps/hsv_color_filter."); + opencv_apps::HSVColorFilterNodelet::onInit(); + } +}; +} // namespace color_filter + #include -typedef color_filter::RGBColorFilterNodelet RGBColorFilterNodelet; -typedef color_filter::HLSColorFilterNodelet HLSColorFilterNodelet; -typedef color_filter::HSVColorFilterNodelet HSVColorFilterNodelet; PLUGINLIB_EXPORT_CLASS(color_filter::RGBColorFilterNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(color_filter::HLSColorFilterNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(color_filter::HSVColorFilterNodelet, nodelet::Nodelet); +PLUGINLIB_EXPORT_CLASS(opencv_apps::RGBColorFilterNodelet, nodelet::Nodelet); +PLUGINLIB_EXPORT_CLASS(opencv_apps::HLSColorFilterNodelet, nodelet::Nodelet); +PLUGINLIB_EXPORT_CLASS(opencv_apps::HSVColorFilterNodelet, nodelet::Nodelet); diff --git a/src/nodelet/contour_moments_nodelet.cpp b/src/nodelet/contour_moments_nodelet.cpp index a957d163..a8d463b1 100644 --- a/src/nodelet/contour_moments_nodelet.cpp +++ b/src/nodelet/contour_moments_nodelet.cpp @@ -54,7 +54,7 @@ #include "opencv_apps/MomentArray.h" #include "opencv_apps/MomentArrayStamped.h" -namespace contour_moments { +namespace opencv_apps { // https://stackoverflow.com/questions/13495207/opencv-c-sorting-contours-by-their-contourarea // comparison function object @@ -73,7 +73,7 @@ class ContourMomentsNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef contour_moments::ContourMomentsConfig Config; + typedef opencv_apps::ContourMomentsConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -276,7 +276,20 @@ class ContourMomentsNodelet : public opencv_apps::Nodelet } }; bool ContourMomentsNodelet::need_config_update_ = false; -} +} // namespace opencv_apps + +namespace contour_moments { +class ContourMomentsNodelet : public opencv_apps::ContourMomentsNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet contour_moments/contour_moments is deprecated, " + "and renamed to opencv_apps/contour_moments."); + opencv_apps::ContourMomentsNodelet::onInit(); + } +}; +} // namespace contour_moments + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::ContourMomentsNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(contour_moments::ContourMomentsNodelet, nodelet::Nodelet); diff --git a/src/nodelet/convex_hull_nodelet.cpp b/src/nodelet/convex_hull_nodelet.cpp index e2d0d23b..2a1b8ec9 100644 --- a/src/nodelet/convex_hull_nodelet.cpp +++ b/src/nodelet/convex_hull_nodelet.cpp @@ -55,7 +55,7 @@ #include "opencv_apps/ContourArray.h" #include "opencv_apps/ContourArrayStamped.h" -namespace convex_hull { +namespace opencv_apps { class ConvexHullNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; @@ -65,7 +65,7 @@ class ConvexHullNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef convex_hull::ConvexHullConfig Config; + typedef opencv_apps::ConvexHullConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -238,7 +238,20 @@ class ConvexHullNodelet : public opencv_apps::Nodelet } }; bool ConvexHullNodelet::need_config_update_ = false; -} +} // namespace opencv_apps + +namespace convex_hull { +class ConvexHullNodelet : public opencv_apps::ConvexHullNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet convex_hull/convex_hull is deprecated, " + "and renamed to opencv_apps/convex_hull."); + opencv_apps::ConvexHullNodelet::onInit(); + } +}; +} // namespace convex_hull + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::ConvexHullNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(convex_hull::ConvexHullNodelet, nodelet::Nodelet); diff --git a/src/nodelet/corner_harris_nodelet.cpp b/src/nodelet/corner_harris_nodelet.cpp index d4f75434..d881648b 100644 --- a/src/nodelet/corner_harris_nodelet.cpp +++ b/src/nodelet/corner_harris_nodelet.cpp @@ -51,7 +51,7 @@ * @author OpenCV team */ -namespace corner_harris { +namespace opencv_apps { class CornerHarrisNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; @@ -61,7 +61,7 @@ class CornerHarrisNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef corner_harris::CornerHarrisConfig Config; + typedef opencv_apps::CornerHarrisConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -211,7 +211,20 @@ class CornerHarrisNodelet : public opencv_apps::Nodelet } }; bool CornerHarrisNodelet::need_config_update_ = false; -} +} // namespace opencv_apps + +namespace corner_harris { +class CornerHarrisNodelet : public opencv_apps::CornerHarrisNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet corner_harris/corner_harris is deprecated, " + "and renamed to opencv_apps/corner_harris."); + opencv_apps::CornerHarrisNodelet::onInit(); + } +}; +} // namespace corner_harris + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::CornerHarrisNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(corner_harris::CornerHarrisNodelet, nodelet::Nodelet); diff --git a/src/nodelet/discrete_fourier_transform_nodelet.cpp b/src/nodelet/discrete_fourier_transform_nodelet.cpp index 53dc1a83..740f70a4 100644 --- a/src/nodelet/discrete_fourier_transform_nodelet.cpp +++ b/src/nodelet/discrete_fourier_transform_nodelet.cpp @@ -50,7 +50,7 @@ #include -namespace discrete_fourier_transform { +namespace opencv_apps { class DiscreteFourierTransformNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; image_transport::Subscriber img_sub_; @@ -58,7 +58,7 @@ class DiscreteFourierTransformNodelet : public opencv_apps::Nodelet { boost::shared_ptr it_; - typedef discrete_fourier_transform::DiscreteFourierTransformConfig Config; + typedef opencv_apps::DiscreteFourierTransformConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -196,7 +196,20 @@ class DiscreteFourierTransformNodelet : public opencv_apps::Nodelet { onInitPostProcess(); } }; -} +} // namespace opencv_apps + +namespace discrete_fourier_transform { +class DiscreteFourierTransformNodelet : public opencv_apps::DiscreteFourierTransformNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet discrete_fourier_transform/discrete_fourier_transform is deprecated, " + "and renamed to opencv_apps/discrete_fourier_transform."); + opencv_apps::DiscreteFourierTransformNodelet::onInit(); + } +}; +} // namespace discrete_fourier_transform + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::DiscreteFourierTransformNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(discrete_fourier_transform::DiscreteFourierTransformNodelet, nodelet::Nodelet); diff --git a/src/nodelet/edge_detection_nodelet.cpp b/src/nodelet/edge_detection_nodelet.cpp index 4bd5525f..7bb3eb93 100644 --- a/src/nodelet/edge_detection_nodelet.cpp +++ b/src/nodelet/edge_detection_nodelet.cpp @@ -62,7 +62,7 @@ #include #include "opencv_apps/EdgeDetectionConfig.h" -namespace edge_detection { +namespace opencv_apps { class EdgeDetectionNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; @@ -72,7 +72,7 @@ class EdgeDetectionNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef edge_detection::EdgeDetectionConfig Config; + typedef opencv_apps::EdgeDetectionConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -155,7 +155,7 @@ class EdgeDetectionNodelet : public opencv_apps::Nodelet std::string new_window_name; cv::Mat grad; switch (config_.edge_type) { - case edge_detection::EdgeDetection_Sobel: + case opencv_apps::EdgeDetection_Sobel: { /// Generate grad_x and grad_y cv::Mat grad_x, grad_y; @@ -181,7 +181,7 @@ class EdgeDetectionNodelet : public opencv_apps::Nodelet new_window_name = "Sobel Edge Detection Demo"; break; } - case edge_detection::EdgeDetection_Laplace: + case opencv_apps::EdgeDetection_Laplace: { cv::Mat dst; int kernel_size = 3; @@ -196,7 +196,7 @@ class EdgeDetectionNodelet : public opencv_apps::Nodelet new_window_name = "Laplace Edge Detection Demo"; break; } - case edge_detection::EdgeDetection_Canny: + case opencv_apps::EdgeDetection_Canny: { int edgeThresh = 1; int kernel_size = 3; @@ -302,7 +302,20 @@ class EdgeDetectionNodelet : public opencv_apps::Nodelet } }; bool EdgeDetectionNodelet::need_config_update_ = false; -} +} // namespace opencv_apps + +namespace edge_detection { +class EdgeDetectionNodelet : public opencv_apps::EdgeDetectionNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet edge_detection/edge_detection is deprecated, " + "and renamed to opencv_apps/edge_detection."); + opencv_apps::EdgeDetectionNodelet::onInit(); + } +}; +} // namespace edge_detection + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::EdgeDetectionNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(edge_detection::EdgeDetectionNodelet, nodelet::Nodelet); diff --git a/src/nodelet/face_detection_nodelet.cpp b/src/nodelet/face_detection_nodelet.cpp index 432516b0..faff76ca 100644 --- a/src/nodelet/face_detection_nodelet.cpp +++ b/src/nodelet/face_detection_nodelet.cpp @@ -55,7 +55,7 @@ #include "opencv_apps/FaceArray.h" #include "opencv_apps/FaceArrayStamped.h" -namespace face_detection { +namespace opencv_apps { class FaceDetectionNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; @@ -66,7 +66,7 @@ class FaceDetectionNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef face_detection::FaceDetectionConfig Config; + typedef opencv_apps::FaceDetectionConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -245,7 +245,20 @@ class FaceDetectionNodelet : public opencv_apps::Nodelet onInitPostProcess(); } }; -} +} // namespace opencv_apps + +namespace face_detection { +class FaceDetectionNodelet : public opencv_apps::FaceDetectionNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet face_detection/face_detection is deprecated, " + "and renamed to opencv_apps/face_detection."); + opencv_apps::FaceDetectionNodelet::onInit(); + } +}; +} // namespace face_detection + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::FaceDetectionNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(face_detection::FaceDetectionNodelet, nodelet::Nodelet); diff --git a/src/nodelet/face_recognition_nodelet.cpp b/src/nodelet/face_recognition_nodelet.cpp index 487d6d77..38858dc3 100644 --- a/src/nodelet/face_recognition_nodelet.cpp +++ b/src/nodelet/face_recognition_nodelet.cpp @@ -111,7 +111,7 @@ namespace filesystem { } }} // end of utility for resolving paths -namespace face_recognition { +namespace opencv_apps { class LabelMapper { std::map m_; @@ -234,7 +234,7 @@ namespace face_recognition { class FaceRecognitionNodelet: public opencv_apps::Nodelet { - typedef face_recognition::FaceRecognitionConfig Config; + typedef opencv_apps::FaceRecognitionConfig Config; typedef dynamic_reconfigure::Server Server; typedef message_filters::sync_policies::ExactTime< sensor_msgs::Image, opencv_apps::FaceArrayStamped> SyncPolicy; @@ -571,7 +571,20 @@ namespace face_recognition { onInitPostProcess(); } }; -} +} // namespace opencv_apps + +namespace face_recognition { +class FaceRecognitionNodelet : public opencv_apps::FaceRecognitionNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet face_recognition/face_recognition is deprecated, " + "and renamed to opencv_apps/face_recognition."); + opencv_apps::FaceRecognitionNodelet::onInit(); + } +}; +} // namespace face_recognition + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::FaceRecognitionNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(face_recognition::FaceRecognitionNodelet, nodelet::Nodelet); diff --git a/src/nodelet/fback_flow_nodelet.cpp b/src/nodelet/fback_flow_nodelet.cpp index a1ac0ae9..5b5143d0 100644 --- a/src/nodelet/fback_flow_nodelet.cpp +++ b/src/nodelet/fback_flow_nodelet.cpp @@ -52,7 +52,7 @@ #include "opencv_apps/FBackFlowConfig.h" #include "opencv_apps/FlowArrayStamped.h" -namespace fback_flow { +namespace opencv_apps { class FBackFlowNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; @@ -62,7 +62,7 @@ class FBackFlowNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef fback_flow::FBackFlowConfig Config; + typedef opencv_apps::FBackFlowConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -220,7 +220,20 @@ class FBackFlowNodelet : public opencv_apps::Nodelet } }; bool FBackFlowNodelet::need_config_update_ = false; -} +} // namespace opencv_apps + +namespace fback_flow { +class FBackFlowNodelet : public opencv_apps::FBackFlowNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet fback_flow/fback_flow is deprecated, " + "and renamed to opencv_apps/fback_flow."); + opencv_apps::FBackFlowNodelet::onInit(); + } +}; +} // namespace fback_flow + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::FBackFlowNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(fback_flow::FBackFlowNodelet, nodelet::Nodelet); diff --git a/src/nodelet/find_contours_nodelet.cpp b/src/nodelet/find_contours_nodelet.cpp index 58cfbdd4..99dcbef9 100644 --- a/src/nodelet/find_contours_nodelet.cpp +++ b/src/nodelet/find_contours_nodelet.cpp @@ -55,7 +55,7 @@ #include "opencv_apps/ContourArray.h" #include "opencv_apps/ContourArrayStamped.h" -namespace find_contours { +namespace opencv_apps { class FindContoursNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; @@ -65,7 +65,7 @@ class FindContoursNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef find_contours::FindContoursConfig Config; + typedef opencv_apps::FindContoursConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -235,7 +235,20 @@ class FindContoursNodelet : public opencv_apps::Nodelet } }; bool FindContoursNodelet::need_config_update_ = false; -} +} // namespace opencv_apps + +namespace find_contours { +class FindContoursNodelet : public opencv_apps::FindContoursNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet find_contours/find_contours is deprecated, " + "and renamed to opencv_apps/find_contours."); + opencv_apps::FindContoursNodelet::onInit(); + } +}; +} // namespace find_contours + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::FindContoursNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(find_contours::FindContoursNodelet, nodelet::Nodelet); diff --git a/src/nodelet/general_contours_nodelet.cpp b/src/nodelet/general_contours_nodelet.cpp index 3355bcb2..70ffa4bb 100644 --- a/src/nodelet/general_contours_nodelet.cpp +++ b/src/nodelet/general_contours_nodelet.cpp @@ -55,7 +55,7 @@ #include "opencv_apps/RotatedRectArray.h" #include "opencv_apps/RotatedRectArrayStamped.h" -namespace general_contours { +namespace opencv_apps { class GeneralContoursNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; @@ -65,7 +65,7 @@ class GeneralContoursNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef general_contours::GeneralContoursConfig Config; + typedef opencv_apps::GeneralContoursConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -267,7 +267,20 @@ class GeneralContoursNodelet : public opencv_apps::Nodelet } }; bool GeneralContoursNodelet::need_config_update_ = false; -} +} // namespace opencv_apps + +namespace general_contours { +class GeneralContoursNodelet : public opencv_apps::GeneralContoursNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet general_contours/general_contours is deprecated, " + "and renamed to opencv_apps/general_contours."); + opencv_apps::GeneralContoursNodelet::onInit(); + } +}; +} // namespace general_contours + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::GeneralContoursNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(general_contours::GeneralContoursNodelet, nodelet::Nodelet); diff --git a/src/nodelet/goodfeature_track_nodelet.cpp b/src/nodelet/goodfeature_track_nodelet.cpp index 9a3d4677..00e33970 100644 --- a/src/nodelet/goodfeature_track_nodelet.cpp +++ b/src/nodelet/goodfeature_track_nodelet.cpp @@ -53,7 +53,7 @@ #include "opencv_apps/Point2D.h" #include "opencv_apps/Point2DArrayStamped.h" -namespace goodfeature_track { +namespace opencv_apps { class GoodfeatureTrackNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; @@ -63,7 +63,7 @@ class GoodfeatureTrackNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef goodfeature_track::GoodfeatureTrackConfig Config; + typedef opencv_apps::GoodfeatureTrackConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -238,7 +238,20 @@ class GoodfeatureTrackNodelet : public opencv_apps::Nodelet } }; bool GoodfeatureTrackNodelet::need_config_update_ = false; -} +} // namespace opencv_apps + +namespace goodfeature_track { +class GoodfeatureTrackNodelet : public opencv_apps::GoodfeatureTrackNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet goodfeature_track/goodfeature_track is deprecated, " + "and renamed to opencv_apps/goodfeature_track."); + opencv_apps::GoodfeatureTrackNodelet::onInit(); + } +}; +} // namespace goodfeature_track + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::GoodfeatureTrackNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(goodfeature_track::GoodfeatureTrackNodelet, nodelet::Nodelet); diff --git a/src/nodelet/hough_circles_nodelet.cpp b/src/nodelet/hough_circles_nodelet.cpp index d68974ba..48b4f32a 100644 --- a/src/nodelet/hough_circles_nodelet.cpp +++ b/src/nodelet/hough_circles_nodelet.cpp @@ -55,7 +55,7 @@ #include "opencv_apps/CircleArray.h" #include "opencv_apps/CircleArrayStamped.h" -namespace hough_circles { +namespace opencv_apps { class HoughCirclesNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; @@ -65,7 +65,7 @@ class HoughCirclesNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef hough_circles::HoughCirclesConfig Config; + typedef opencv_apps::HoughCirclesConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -345,7 +345,20 @@ class HoughCirclesNodelet : public opencv_apps::Nodelet } }; bool HoughCirclesNodelet::need_config_update_ = false; -} +} // namespace opencv_apps + +namespace hough_circles { +class HoughCirclesNodelet : public opencv_apps::HoughCirclesNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet hough_circles/hough_circles is deprecated, " + "and renamed to opencv_apps/hough_circles."); + opencv_apps::HoughCirclesNodelet::onInit(); + } +}; +} // namespace hough_circles + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::HoughCirclesNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(hough_circles::HoughCirclesNodelet, nodelet::Nodelet); diff --git a/src/nodelet/hough_lines_nodelet.cpp b/src/nodelet/hough_lines_nodelet.cpp index dd8f390a..e94ef2ae 100644 --- a/src/nodelet/hough_lines_nodelet.cpp +++ b/src/nodelet/hough_lines_nodelet.cpp @@ -55,7 +55,7 @@ #include "opencv_apps/LineArray.h" #include "opencv_apps/LineArrayStamped.h" -namespace hough_lines { +namespace opencv_apps { class HoughLinesNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; @@ -65,7 +65,7 @@ class HoughLinesNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef hough_lines::HoughLinesConfig Config; + typedef opencv_apps::HoughLinesConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -176,7 +176,7 @@ class HoughLinesNodelet : public opencv_apps::Nodelet } switch (config_.hough_type) { - case hough_lines::HoughLines_Standard_Hough_Transform: + case opencv_apps::HoughLines_Standard_Hough_Transform: { std::vector s_lines; @@ -208,7 +208,7 @@ class HoughLinesNodelet : public opencv_apps::Nodelet break; } - case hough_lines::HoughLines_Probabilistic_Hough_Transform: + case opencv_apps::HoughLines_Probabilistic_Hough_Transform: default: { std::vector p_lines; @@ -301,7 +301,20 @@ class HoughLinesNodelet : public opencv_apps::Nodelet } }; bool HoughLinesNodelet::need_config_update_ = false; -} +} // namespace opencv_apps + +namespace hough_lines { +class HoughLinesNodelet : public opencv_apps::HoughLinesNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet hough_lines/hough_lines is deprecated, " + "and renamed to opencv_apps/hough_lines."); + opencv_apps::HoughLinesNodelet::onInit(); + } +}; +} // namespace hough_lines + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::HoughLinesNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(hough_lines::HoughLinesNodelet, nodelet::Nodelet); diff --git a/src/nodelet/lk_flow_nodelet.cpp b/src/nodelet/lk_flow_nodelet.cpp index 533e5ab8..e9fb5105 100644 --- a/src/nodelet/lk_flow_nodelet.cpp +++ b/src/nodelet/lk_flow_nodelet.cpp @@ -53,7 +53,7 @@ #include "opencv_apps/LKFlowConfig.h" #include "opencv_apps/FlowArrayStamped.h" -namespace lk_flow { +namespace opencv_apps { class LKFlowNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; @@ -66,7 +66,7 @@ class LKFlowNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef lk_flow::LKFlowConfig Config; + typedef opencv_apps::LKFlowConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -324,7 +324,20 @@ class LKFlowNodelet : public opencv_apps::Nodelet } }; bool LKFlowNodelet::need_config_update_ = false; -} +} // namespace opencv_apps + +namespace lk_flow { +class LKFlowNodelet : public opencv_apps::LKFlowNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet lk_flow/lk_flow is deprecated, " + "and renamed to opencv_apps/lk_flow."); + opencv_apps::LKFlowNodelet::onInit(); + } +}; +} // namespace lk_flow + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::LKFlowNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(lk_flow::LKFlowNodelet, nodelet::Nodelet); diff --git a/src/nodelet/people_detect_nodelet.cpp b/src/nodelet/people_detect_nodelet.cpp index a9814660..e1af18fb 100644 --- a/src/nodelet/people_detect_nodelet.cpp +++ b/src/nodelet/people_detect_nodelet.cpp @@ -53,7 +53,7 @@ #include "opencv_apps/Rect.h" #include "opencv_apps/RectArrayStamped.h" -namespace people_detect { +namespace opencv_apps { class PeopleDetectNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; @@ -63,7 +63,7 @@ class PeopleDetectNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef people_detect::PeopleDetectConfig Config; + typedef opencv_apps::PeopleDetectConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -231,7 +231,20 @@ class PeopleDetectNodelet : public opencv_apps::Nodelet } }; bool PeopleDetectNodelet::need_config_update_ = false; -} +} // namespace opencv_apps + +namespace people_detect { +class PeopleDetectNodelet : public opencv_apps::PeopleDetectNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet people_detect/people_detect is deprecated, " + "and renamed to opencv_apps/people_detect."); + opencv_apps::PeopleDetectNodelet::onInit(); + } +}; +} // namespace people_detect + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::PeopleDetectNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(people_detect::PeopleDetectNodelet, nodelet::Nodelet); diff --git a/src/nodelet/phase_corr_nodelet.cpp b/src/nodelet/phase_corr_nodelet.cpp index 5ab095d6..4843b9a2 100644 --- a/src/nodelet/phase_corr_nodelet.cpp +++ b/src/nodelet/phase_corr_nodelet.cpp @@ -47,7 +47,7 @@ #include "opencv_apps/PhaseCorrConfig.h" #include "opencv_apps/Point2DStamped.h" -namespace phase_corr { +namespace opencv_apps { class PhaseCorrNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; @@ -57,7 +57,7 @@ class PhaseCorrNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef phase_corr::PhaseCorrConfig Config; + typedef opencv_apps::PhaseCorrConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -217,7 +217,20 @@ class PhaseCorrNodelet : public opencv_apps::Nodelet } }; bool PhaseCorrNodelet::need_config_update_ = false; -} +} // namespace opencv_apps + +namespace phase_corr { +class PhaseCorrNodelet : public opencv_apps::PhaseCorrNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet phase_corr/phase_corr is deprecated, " + "and renamed to opencv_apps/phase_corr."); + opencv_apps::PhaseCorrNodelet::onInit(); + } +}; +} // namespace phase_corr + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::PhaseCorrNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(phase_corr::PhaseCorrNodelet, nodelet::Nodelet); diff --git a/src/nodelet/pyramids_nodelet.cpp b/src/nodelet/pyramids_nodelet.cpp index edd8b00c..9840fd06 100644 --- a/src/nodelet/pyramids_nodelet.cpp +++ b/src/nodelet/pyramids_nodelet.cpp @@ -53,7 +53,7 @@ #include "opencv_apps/PyramidsConfig.h" #include -namespace pyramids { +namespace opencv_apps { class PyramidsNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; image_transport::Subscriber img_sub_; @@ -62,7 +62,7 @@ class PyramidsNodelet : public opencv_apps::Nodelet { boost::shared_ptr it_; - typedef pyramids::PyramidsConfig Config; + typedef opencv_apps::PyramidsConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -107,14 +107,14 @@ class PyramidsNodelet : public opencv_apps::Nodelet { // Do the work int num = num_of_pyramids_; switch (config_.pyramids_type) { - case pyramids::Pyramids_Up: { + case opencv_apps::Pyramids_Up: { while(num) { num--; cv::pyrUp(src_image, src_image, cv::Size(src_image.cols * 2, src_image.rows * 2)); } break; } - case pyramids::Pyramids_Down: { + case opencv_apps::Pyramids_Down: { while(num) { num--; cv::pyrDown(src_image, src_image, cv::Size(src_image.cols / 2, src_image.rows / 2)); @@ -179,7 +179,20 @@ class PyramidsNodelet : public opencv_apps::Nodelet { onInitPostProcess(); } }; -} +} // namespace opencv_apps + +namespace pyramids { +class PyramidsNodelet : public opencv_apps::PyramidsNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet pyramids/pyramids is deprecated, " + "and renamed to opencv_apps/pyramids."); + opencv_apps::PyramidsNodelet::onInit(); + } +}; +} // namespace pyramids + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::PyramidsNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(pyramids::PyramidsNodelet, nodelet::Nodelet); diff --git a/src/nodelet/segment_objects_nodelet.cpp b/src/nodelet/segment_objects_nodelet.cpp index 82e9a5cf..ba7c19b8 100644 --- a/src/nodelet/segment_objects_nodelet.cpp +++ b/src/nodelet/segment_objects_nodelet.cpp @@ -55,7 +55,7 @@ #include "opencv_apps/ContourArray.h" #include "opencv_apps/ContourArrayStamped.h" -namespace segment_objects { +namespace opencv_apps { class SegmentObjectsNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; @@ -66,7 +66,7 @@ class SegmentObjectsNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef segment_objects::SegmentObjectsConfig Config; + typedef opencv_apps::SegmentObjectsConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -274,7 +274,20 @@ class SegmentObjectsNodelet : public opencv_apps::Nodelet } }; bool SegmentObjectsNodelet::need_config_update_ = false; -} +} // namespace opencv_apps + +namespace segment_objects { +class SegmentObjectsNodelet : public opencv_apps::SegmentObjectsNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet segment_objects/segment_objects is deprecated, " + "and renamed to opencv_apps/segment_objects."); + opencv_apps::SegmentObjectsNodelet::onInit(); + } +}; +} // namespace segment_objects + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::SegmentObjectsNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(segment_objects::SegmentObjectsNodelet, nodelet::Nodelet); diff --git a/src/nodelet/simple_compressed_example_nodelet.cpp b/src/nodelet/simple_compressed_example_nodelet.cpp index cb235e9a..6dffda89 100644 --- a/src/nodelet/simple_compressed_example_nodelet.cpp +++ b/src/nodelet/simple_compressed_example_nodelet.cpp @@ -51,6 +51,7 @@ #include +namespace opencv_apps { namespace simple_compressed_example { @@ -214,6 +215,7 @@ class ImageConverter #endif }; +} // namespace simple_compressed_example class SimpleCompressedExampleNodelet : public nodelet::Nodelet { @@ -227,7 +229,19 @@ class SimpleCompressedExampleNodelet : public nodelet::Nodelet } }; -} +} // namespace opencv_apps + +namespace simple_compressed_example { +class SimpleCompressedExampleNodelet : public opencv_apps::SimpleCompressedExampleNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet simple_compressed_example/simple_compressed_example is deprecated, " + "and renamed to opencv_apps/simple_compressed_example."); + opencv_apps::SimpleCompressedExampleNodelet::onInit(); + } +}; +} // namespace simple_compressed_example #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::SimpleCompressedExampleNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(simple_compressed_example::SimpleCompressedExampleNodelet, nodelet::Nodelet); diff --git a/src/nodelet/simple_example_nodelet.cpp b/src/nodelet/simple_example_nodelet.cpp index d5bb3730..fe85e37f 100644 --- a/src/nodelet/simple_example_nodelet.cpp +++ b/src/nodelet/simple_example_nodelet.cpp @@ -48,6 +48,7 @@ #include +namespace opencv_apps { namespace simple_example { @@ -112,6 +113,7 @@ class ImageConverter } }; +} // namesapce simple_example class SimpleExampleNodelet : public nodelet::Nodelet { @@ -125,7 +127,20 @@ class SimpleExampleNodelet : public nodelet::Nodelet } }; -} +} // namespace opencv_apps + +namespace simple_example { +class SimpleExampleNodelet : public opencv_apps::SimpleExampleNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet simple_example/simple_example is deprecated, " + "and renamed to opencv_apps/simple_example."); + opencv_apps::SimpleExampleNodelet::onInit(); + } +}; +} // namespace simple_example + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::SimpleExampleNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(simple_example::SimpleExampleNodelet, nodelet::Nodelet); diff --git a/src/nodelet/simple_flow_nodelet.cpp b/src/nodelet/simple_flow_nodelet.cpp index c5d20d5e..0594f557 100644 --- a/src/nodelet/simple_flow_nodelet.cpp +++ b/src/nodelet/simple_flow_nodelet.cpp @@ -54,7 +54,7 @@ #include "opencv_apps/SimpleFlowConfig.h" #include "opencv_apps/FlowArrayStamped.h" -namespace simple_flow { +namespace opencv_apps { class SimpleFlowNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; @@ -64,7 +64,7 @@ class SimpleFlowNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef simple_flow::SimpleFlowConfig Config; + typedef opencv_apps::SimpleFlowConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -254,7 +254,19 @@ class SimpleFlowNodelet : public opencv_apps::Nodelet } }; bool SimpleFlowNodelet::need_config_update_ = false; -} +} // namespace opencv_apps + +namespace simple_flow { +class SimpleFlowNodelet : public opencv_apps::SimpleFlowNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet simple_flow/simple_flow is deprecated, " + "and renamed to opencv_apps/simple_flow."); + opencv_apps::SimpleFlowNodelet::onInit(); + } +}; +} // namespace simple_flow #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::SimpleFlowNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(simple_flow::SimpleFlowNodelet, nodelet::Nodelet); diff --git a/src/nodelet/smoothing_nodelet.cpp b/src/nodelet/smoothing_nodelet.cpp index 8709207a..84115809 100644 --- a/src/nodelet/smoothing_nodelet.cpp +++ b/src/nodelet/smoothing_nodelet.cpp @@ -59,7 +59,7 @@ /// Global Variables int MAX_KERNEL_LENGTH = 31; -namespace smoothing { +namespace opencv_apps { class SmoothingNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; @@ -69,7 +69,7 @@ class SmoothingNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef smoothing::SmoothingConfig Config; + typedef opencv_apps::SmoothingConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -136,28 +136,28 @@ class SmoothingNodelet : public opencv_apps::Nodelet cv::Mat out_image = in_image.clone(); int i = kernel_size_; switch (config_.filter_type) { - case smoothing::Smoothing_Homogeneous_Blur: + case opencv_apps::Smoothing_Homogeneous_Blur: { /// Applying Homogeneous blur ROS_DEBUG_STREAM("Applying Homogeneous blur with kernel size " << i ); cv::blur( in_image, out_image, cv::Size( i, i ), cv::Point(-1,-1) ); break; } - case smoothing::Smoothing_Gaussian_Blur: + case opencv_apps::Smoothing_Gaussian_Blur: { /// Applying Gaussian blur ROS_DEBUG_STREAM("Applying Gaussian blur with kernel size " << i ); cv::GaussianBlur( in_image, out_image, cv::Size( i, i ), 0, 0 ); break; } - case smoothing::Smoothing_Median_Blur: + case opencv_apps::Smoothing_Median_Blur: { /// Applying Median blur ROS_DEBUG_STREAM("Applying Median blur with kernel size " << i ); cv::medianBlur ( in_image, out_image, i ); break; } - case smoothing::Smoothing_Bilateral_Filter: + case opencv_apps::Smoothing_Bilateral_Filter: { /// Applying Bilateral Filter ROS_DEBUG_STREAM("Applying Bilateral blur with kernel size " << i ); @@ -226,7 +226,19 @@ class SmoothingNodelet : public opencv_apps::Nodelet } }; bool SmoothingNodelet::need_config_update_ = false; -} +} // namespace opencv_apps + +namespace smoothing { +class SmoothingNodelet : public opencv_apps::SmoothingNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet smoothing/smoothing is deprecated, " + "and renamed to opencv_apps/smoothing."); + opencv_apps::SmoothingNodelet::onInit(); + } +}; +} // namespace smoothing #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::SmoothingNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(smoothing::SmoothingNodelet, nodelet::Nodelet); diff --git a/src/nodelet/threshold_nodelet.cpp b/src/nodelet/threshold_nodelet.cpp index cc1b6b62..6593153d 100644 --- a/src/nodelet/threshold_nodelet.cpp +++ b/src/nodelet/threshold_nodelet.cpp @@ -51,12 +51,12 @@ #include -namespace threshold { +namespace opencv_apps { class ThresholdNodelet : public opencv_apps::Nodelet { //////////////////////////////////////////////////////// // Dynamic Reconfigure //////////////////////////////////////////////////////// - typedef threshold::ThresholdConfig Config; + typedef opencv_apps::ThresholdConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -165,7 +165,20 @@ namespace threshold { onInitPostProcess(); } }; -} +} // namespace opencv_apps + +namespace threshold { +class ThresholdNodelet : public opencv_apps::ThresholdNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet threshold/threshold is deprecated, " + "and renamed to opencv_apps/threshold."); + opencv_apps::ThresholdNodelet::onInit(); + } +}; +} // namespace threshold + #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::ThresholdNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(threshold::ThresholdNodelet, nodelet::Nodelet); diff --git a/src/nodelet/watershed_segmentation_nodelet.cpp b/src/nodelet/watershed_segmentation_nodelet.cpp index aebc45bc..787d5f15 100644 --- a/src/nodelet/watershed_segmentation_nodelet.cpp +++ b/src/nodelet/watershed_segmentation_nodelet.cpp @@ -53,7 +53,7 @@ #include "opencv_apps/ContourArrayStamped.h" #include "opencv_apps/Point2DArray.h" -namespace watershed_segmentation { +namespace opencv_apps { class WatershedSegmentationNodelet : public opencv_apps::Nodelet { image_transport::Publisher img_pub_; @@ -64,7 +64,7 @@ class WatershedSegmentationNodelet : public opencv_apps::Nodelet boost::shared_ptr it_; - typedef watershed_segmentation::WatershedSegmentationConfig Config; + typedef opencv_apps::WatershedSegmentationConfig Config; typedef dynamic_reconfigure::Server ReconfigureServer; Config config_; boost::shared_ptr reconfigure_server_; @@ -92,7 +92,7 @@ class WatershedSegmentationNodelet : public opencv_apps::Nodelet on_mouse_flags_ = flags; } - void reconfigureCallback(watershed_segmentation::WatershedSegmentationConfig &new_config, uint32_t level) + void reconfigureCallback(opencv_apps::WatershedSegmentationConfig &new_config, uint32_t level) { config_ = new_config; } @@ -337,7 +337,19 @@ int WatershedSegmentationNodelet::on_mouse_event_ = 0; int WatershedSegmentationNodelet::on_mouse_x_ = 0; int WatershedSegmentationNodelet::on_mouse_y_ = 0; int WatershedSegmentationNodelet::on_mouse_flags_ = 0; -} +} // namespace opencv_apps + +namespace watershed_segmentation { +class WatershedSegmentationNodelet : public opencv_apps::WatershedSegmentationNodelet { +public: + virtual void onInit() { + ROS_WARN("DeprecationWarning: Nodelet watershed_segmentation/watershed_segmentation is deprecated, " + "and renamed to opencv_apps/watershed_segmentation."); + opencv_apps::WatershedSegmentationNodelet::onInit(); + } +}; +} // namespace watershed_segmentation #include +PLUGINLIB_EXPORT_CLASS(opencv_apps::WatershedSegmentationNodelet, nodelet::Nodelet); PLUGINLIB_EXPORT_CLASS(watershed_segmentation::WatershedSegmentationNodelet, nodelet::Nodelet);