Skip to content
Snippets Groups Projects
Commit 3423becf authored by Joan Solà Ortega's avatar Joan Solà Ortega
Browse files

Merge branch 'fix_compilation_nopencv' into 'master'

fix compilation without opencv

See merge request !121
parents 0bc5a9a1 aaa40960
No related branches found
No related tags found
1 merge request!121fix compilation without opencv
...@@ -199,7 +199,6 @@ SET(HDRS ...@@ -199,7 +199,6 @@ SET(HDRS
constraint_container.h constraint_container.h
constraint_corner_2D.h constraint_corner_2D.h
constraint_epipolar.h constraint_epipolar.h
constraint_AHP.h
constraint_imu.h constraint_imu.h
constraint_fix.h constraint_fix.h
constraint_fix_3D.h constraint_fix_3D.h
...@@ -222,7 +221,6 @@ SET(HDRS ...@@ -222,7 +221,6 @@ SET(HDRS
frame_imu.h frame_imu.h
landmark_corner_2D.h landmark_corner_2D.h
landmark_container.h landmark_container.h
landmark_point_3d.h
landmark_line_2D.h landmark_line_2D.h
landmark_polyline_2D.h landmark_polyline_2D.h
local_parametrization_polyline_extreme.h local_parametrization_polyline_extreme.h
...@@ -291,7 +289,6 @@ SET(SRCS ...@@ -291,7 +289,6 @@ SET(SRCS
frame_imu.cpp frame_imu.cpp
landmark_corner_2D.cpp landmark_corner_2D.cpp
landmark_container.cpp landmark_container.cpp
landmark_point_3d.cpp
landmark_line_2D.cpp landmark_line_2D.cpp
landmark_polyline_2D.cpp landmark_polyline_2D.cpp
local_parametrization_polyline_extreme.cpp local_parametrization_polyline_extreme.cpp
...@@ -373,8 +370,10 @@ IF (OpenCV_FOUND) ...@@ -373,8 +370,10 @@ IF (OpenCV_FOUND)
SET(HDRS ${HDRS} SET(HDRS ${HDRS}
active_search.h active_search.h
capture_image.h capture_image.h
constraint_AHP.h
feature_point_image.h feature_point_image.h
landmark_AHP.h landmark_AHP.h
landmark_point_3d.h
processor_image_feature.h processor_image_feature.h
processor_image_landmark.h processor_image_landmark.h
) )
...@@ -383,6 +382,7 @@ IF (OpenCV_FOUND) ...@@ -383,6 +382,7 @@ IF (OpenCV_FOUND)
capture_image.cpp capture_image.cpp
feature_point_image.cpp feature_point_image.cpp
landmark_AHP.cpp landmark_AHP.cpp
landmark_point_3d.cpp
processor_image_feature.cpp processor_image_feature.cpp
processor_image_landmark.cpp processor_image_landmark.cpp
) )
...@@ -401,7 +401,6 @@ IF(YAMLCPP_FOUND) ...@@ -401,7 +401,6 @@ IF(YAMLCPP_FOUND)
# sources # sources
SET(SRCS ${SRCS} SET(SRCS ${SRCS}
yaml/processor_image_yaml.cpp
yaml/processor_odom_3D_yaml.cpp yaml/processor_odom_3D_yaml.cpp
yaml/sensor_camera_yaml.cpp yaml/sensor_camera_yaml.cpp
yaml/sensor_odom_3D_yaml.cpp yaml/sensor_odom_3D_yaml.cpp
...@@ -411,6 +410,11 @@ IF(YAMLCPP_FOUND) ...@@ -411,6 +410,11 @@ IF(YAMLCPP_FOUND)
yaml/sensor_laser_2D_yaml.cpp yaml/sensor_laser_2D_yaml.cpp
) )
ENDIF(laser_scan_utils_FOUND) ENDIF(laser_scan_utils_FOUND)
IF(OpenCV_FOUND)
SET(SRCS ${SRCS}
yaml/processor_image_yaml.cpp
)
ENDIF(OpenCV_FOUND)
ENDIF(YAMLCPP_FOUND) ENDIF(YAMLCPP_FOUND)
# create the shared library # create the shared library
......
...@@ -20,7 +20,11 @@ ...@@ -20,7 +20,11 @@
#include "../constraint_point_2D.h" #include "../constraint_point_2D.h"
#include "../constraint_point_to_line_2D.h" #include "../constraint_point_to_line_2D.h"
#include "../constraint_container.h" #include "../constraint_container.h"
#include "../constraint_AHP.h"
#ifdef CV_VERSION
#include "../constraint_AHP.h"
#endif
#include "../constraint_imu.h" #include "../constraint_imu.h"
// Wolf and ceres auto_diff creators // Wolf and ceres auto_diff creators
...@@ -98,7 +102,7 @@ ceres::CostFunction* createAutoDiffCostFunction(ConstraintBasePtr _ctr_ptr, bool ...@@ -98,7 +102,7 @@ ceres::CostFunction* createAutoDiffCostFunction(ConstraintBasePtr _ctr_ptr, bool
return createAutoDiffCostFunctionWrapper<ConstraintPointToLine2D>(_ctr_ptr); return createAutoDiffCostFunctionWrapper<ConstraintPointToLine2D>(_ctr_ptr);
else else
return createAutoDiffCostFunctionCeres<ConstraintPointToLine2D>(_ctr_ptr); return createAutoDiffCostFunctionCeres<ConstraintPointToLine2D>(_ctr_ptr);
#ifdef CV_VERSION
case CTR_EPIPOLAR: case CTR_EPIPOLAR:
if (_use_wolf_autodiff) if (_use_wolf_autodiff)
return createAutoDiffCostFunctionWrapper<ConstraintAHP>(_ctr_ptr); return createAutoDiffCostFunctionWrapper<ConstraintAHP>(_ctr_ptr);
...@@ -110,7 +114,7 @@ ceres::CostFunction* createAutoDiffCostFunction(ConstraintBasePtr _ctr_ptr, bool ...@@ -110,7 +114,7 @@ ceres::CostFunction* createAutoDiffCostFunction(ConstraintBasePtr _ctr_ptr, bool
return createAutoDiffCostFunctionWrapper<ConstraintAHP>(_ctr_ptr); return createAutoDiffCostFunctionWrapper<ConstraintAHP>(_ctr_ptr);
else else
return createAutoDiffCostFunctionCeres<ConstraintAHP>(_ctr_ptr); return createAutoDiffCostFunctionCeres<ConstraintAHP>(_ctr_ptr);
#endif
case CTR_IMU: case CTR_IMU:
if (_use_wolf_autodiff) if (_use_wolf_autodiff)
return createAutoDiffCostFunctionWrapper<ConstraintIMU>(_ctr_ptr); return createAutoDiffCostFunctionWrapper<ConstraintIMU>(_ctr_ptr);
......
...@@ -137,8 +137,10 @@ ENDIF(OpenCV_FOUND) ...@@ -137,8 +137,10 @@ ENDIF(OpenCV_FOUND)
IF(Ceres_FOUND) IF(Ceres_FOUND)
# Simple AHP test # Simple AHP test
ADD_EXECUTABLE(test_simple_AHP test_simple_AHP.cpp) IF(OpenCV_FOUND)
TARGET_LINK_LIBRARIES(test_simple_AHP ${PROJECT_NAME}) ADD_EXECUTABLE(test_simple_AHP test_simple_AHP.cpp)
TARGET_LINK_LIBRARIES(test_simple_AHP ${PROJECT_NAME})
ENDIF(OpenCV_FOUND)
ENDIF(Ceres_FOUND) ENDIF(Ceres_FOUND)
# Processor Tracker Feature test # Processor Tracker Feature test
......
...@@ -111,6 +111,7 @@ wolf_add_gtest(gtest_odom_3D gtest_odom_3D.cpp) ...@@ -111,6 +111,7 @@ wolf_add_gtest(gtest_odom_3D gtest_odom_3D.cpp)
target_link_libraries(gtest_odom_3D ${PROJECT_NAME}) target_link_libraries(gtest_odom_3D ${PROJECT_NAME})
# ROI test # ROI test
wolf_add_gtest(gtest_roi_ORB gtest_roi_ORB.cpp) IF(OpenCV_FOUND)
target_link_libraries(gtest_roi_ORB ${PROJECT_NAME}) wolf_add_gtest(gtest_roi_ORB gtest_roi_ORB.cpp)
target_link_libraries(gtest_roi_ORB ${PROJECT_NAME})
ENDIF(OpenCV_FOUND)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment