diff --git a/CMakeLists.txt b/CMakeLists.txt index 86e5e79bfbeca59453a0bc25e04f96439d7e6acd..d0982431ad90eca826646f8a7697d9191073f37a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -83,8 +83,10 @@ option(_WOLF_TRACE "Enable wolf tracing macro" ON) # ============ DEPENDENCIES ================== FIND_PACKAGE(wolfcore REQUIRED) -SET(PRINT_INFO_VU false) -FIND_PACKAGE(OpenCV REQUIRED) +FIND_PACKAGE(OpenCV REQUIRED + COMPONENTS core imgcodecs highgui features2d calib3d video +) + # ============ config.h ================== string(TOUPPER ${PROJECT_NAME} UPPER_NAME) @@ -184,10 +186,29 @@ elseif (CMAKE_CXX_COMPILER_ID STREQUAL "GNU") # using GCC endif() -#Link the created libraries +# Link the created libraries #===============EXAMPLE========================= TARGET_LINK_LIBRARIES(${PLUGIN_NAME} wolfcore) -TARGET_LINK_LIBRARIES(${PLUGIN_NAME} OpenCV) +# For OpenCV, link with respect to each required components, found in the find_package command +# The required components have the same name as the include files e.g. <opencv2/core.hpp> +# or the opencv2 subdirectory in which they are found, e.g. <opencv2/video/tracking.hpp> +TARGET_LINK_LIBRARIES(${PLUGIN_NAME} + opencv_core + opencv_imgcodecs + opencv_highgui + opencv_features2d + opencv_calib3d + opencv_video +) + + +# # TARGET_LINK_LIBRARIES(${PLUGIN_NAME} opencv) +# get_target_property(toto wolfcore INCLUDE_DIRECTORIES) +# message(WARNING ${toto}) +# get_target_property(toto wolfcore INTERFACE_INCLUDE_DIRECTORIES) +# message(WARNING ${toto}) +# get_target_property(toto wolfcore INTERFACE_SYSTEM_INCLUDE_DIRECTORIES) +# message(WARNING ${toto}) #Build demos #===============EXAMPLE========================= diff --git a/include/vision/factor/factor_pixel_hp.h b/include/vision/factor/factor_pixel_hp.h index 8693b5f7262e29c61ffaab3c573fa8b19ff33cd9..fc92af152cc27febafca51d42c16c36fd58aad0a 100644 --- a/include/vision/factor/factor_pixel_hp.h +++ b/include/vision/factor/factor_pixel_hp.h @@ -99,15 +99,9 @@ inline FactorPixelHp::FactorPixelHp(const FeatureBasePtr& _ftr_ptr, inline Eigen::VectorXd FactorPixelHp::expectation() const { -<<<<<<< HEAD - FrameBasePtr frm = getFeature()->getCapture()->getFrame(); - SensorBasePtr sen = getFeature()->getCapture()->getSensor(); - LandmarkBasePtr lmk = getLandmarkOther(); -======= auto frm = getFeature()->getCapture()->getFrame(); auto sen = getFeature()->getCapture()->getSensor(); auto lmk = getLandmarkOther(); ->>>>>>> devel const Eigen::MatrixXd frame_pos = frm->getP()->getState(); const Eigen::MatrixXd frame_ori = frm->getO()->getState();