-
Notifications
You must be signed in to change notification settings - Fork 191
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
26 changed files
with
669 additions
and
1,326 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,59 @@ | ||
if(NOT USE_ROSBUILD) | ||
include(catkin.cmake) | ||
return() | ||
# http://ros.org/doc/groovy/api/catkin/html/user_guide/supposed.html | ||
cmake_minimum_required(VERSION 2.8.3) | ||
project(checkerboard_detector) | ||
|
||
find_package(catkin REQUIRED COMPONENTS roscpp rosconsole cv_bridge sensor_msgs image_geometry | ||
posedetection_msgs eigen_conversions message_filters tf tf2 jsk_recognition_msgs jsk_recognition_msgs) | ||
find_package(OpenCV REQUIRED) | ||
find_package(OpenMP) | ||
find_package(posedetection_msgs) | ||
|
||
catkin_package( | ||
CATKIN_DEPENDS roscpp rosconsole cv_bridge sensor_msgs posedetection_msgs image_geometry jsk_recognition_msgs | ||
DEPENDS OpenCV2 | ||
INCLUDE_DIRS # TODO include | ||
LIBRARIES # TODO | ||
) | ||
|
||
if (OPENMP_FOUND) | ||
set (CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${OpenMP_C_FLAGS}") | ||
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${OpenMP_CXX_FLAGS}") | ||
endif() | ||
cmake_minimum_required(VERSION 2.4.6) | ||
#set( CMAKE_ALLOW_LOOSE_LOOP_CONSTRUCTS TRUE ) | ||
include($ENV{ROS_ROOT}/core/rosbuild/rosbuild.cmake) | ||
|
||
rosbuild_init() | ||
rosbuild_add_boost_directories() | ||
include_directories(SYSTEM ${catkin_INCLUDE_DIRS} | ||
${OpenCV_INCLUDE_DIRS}) | ||
|
||
#set the default path for built executables to the "bin" directory | ||
set(EXECUTABLE_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/bin) | ||
# set(EXECUTABLE_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/bin) | ||
#set the default path for built libraries to the "lib" directory | ||
set(LIBRARY_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/lib) | ||
# set(LIBRARY_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/lib) | ||
|
||
add_executable(checkerboard_detector src/checkerboard_detector.cpp) | ||
target_link_libraries(checkerboard_detector ${catkin_LIBRARIES} ${OpenCV_LIBRARIES}) | ||
add_executable(objectdetection_transform_echo src/objectdetection_transform_echo.cpp) | ||
target_link_libraries(objectdetection_transform_echo ${catkin_LIBRARIES} ${OpenCV_LIBRARIES}) | ||
add_executable(checkerboard_calibration src/checkerboard_calibration.cpp) | ||
target_link_libraries(checkerboard_calibration ${catkin_LIBRARIES} ${OpenCV_LIBRARIES}) | ||
add_dependencies(checkerboard_detector posedetection_msgs_gencpp) | ||
add_dependencies(checkerboard_calibration posedetection_msgs_gencpp) | ||
add_dependencies(objectdetection_transform_echo posedetection_msgs_gencpp) | ||
add_dependencies(checkerboard_detector jsk_recognition_msgs_gencpp) | ||
add_dependencies(checkerboard_calibration jsk_recognition_msgs_gencpp) | ||
add_dependencies(objectdetection_transform_echo jsk_recognition_msgs_gencpp) | ||
|
||
install(TARGETS checkerboard_detector checkerboard_calibration | ||
objectdetection_transform_echo | ||
ARCHIVE DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION} | ||
LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION} | ||
RUNTIME DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION} | ||
) | ||
|
||
install(PROGRAMS src/objectdetection_tf_publisher.py | ||
DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION} | ||
) | ||
|
||
add_subdirectory(src) | ||
file(GLOB _launch *.launch) | ||
file(GLOB _pdf *.pdf) | ||
install(FILES ${_launch} ${_pdf} | ||
DESTINATION ${CATKIN_PACKAGE_SHARE_DESTINATION} | ||
) |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,34 +1,56 @@ | ||
if(NOT USE_ROSBUILD) | ||
include(catkin.cmake) | ||
return() | ||
endif() | ||
cmake_minimum_required(VERSION 2.8.3) | ||
project(imagesift) | ||
|
||
cmake_minimum_required(VERSION 2.4.6) | ||
include($ENV{ROS_ROOT}/core/rosbuild/rosbuild.cmake) | ||
#set(ROS_BUILD_TYPE RelWithDebInfo) | ||
rosbuild_init() | ||
find_package(catkin REQUIRED COMPONENTS roscpp sensor_msgs posedetection_msgs image_transport cv_bridge | ||
jsk_perception) | ||
|
||
find_package(OpenCV) | ||
|
||
catkin_package( | ||
CATKIN_DEPENDS roscpp sensor_msgs posedetection_msgs image_transport cv_bridge | ||
LIBRARIES | ||
INCLUDE_DIRS | ||
DEPENDS OpenCV libsiftfast | ||
) | ||
|
||
|
||
set(ENV{PKG_CONFIG_PATH} ${CATKIN_DEVEL_PREFIX}/lib/pkgconfig:$ENV{PKG_CONFIG_PATH}) | ||
find_package(PkgConfig REQUIRED) | ||
pkg_check_modules(siftfast libsiftfast REQUIRED) | ||
|
||
include_directories(${catkin_INCLUDE_DIRS} ${OpenCV_INCLUDE_DIRS} ${siftfast_INCLUDE_DIRS}) | ||
link_directories(${siftfast_LIBRARY_DIRS}) | ||
link_libraries(${catkin_LIBRARIES} ${OpenCV_LIBRARIES} ${siftfast_LIBRARIES}) | ||
|
||
set(EXECUTABLE_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/bin) | ||
set(LIBRARY_OUTPUT_PATH ${PROJECT_SOURCE_DIR}/lib) | ||
|
||
find_package(OpenCV REQUIRED) | ||
|
||
macro(jsk_feature detector extractor exec_name) | ||
set(DETECTOR ${detector}) | ||
set(EXTRACTOR ${extractor}) | ||
configure_file(${PROJECT_SOURCE_DIR}/imagefeatures.cpp.in ${exec_name}.cpp) #${CMAKE_CURRENT_BINARY_DIR}/ | ||
rosbuild_add_executable(${exec_name} build/${exec_name}.cpp) | ||
list(APPEND jsk_exec ${exec_name}) | ||
set(DETECTOR ${detector}) | ||
set(EXTRACTOR ${extractor}) | ||
configure_file(imagefeatures.cpp.in ${exec_name}.cpp) #${CMAKE_CURRENT_BINARY_DIR}/ | ||
add_executable(${exec_name} ${exec_name}.cpp) | ||
set_target_properties(${exec_name} PROPERTIES COMPILE_FLAGS "-msse2 -O3" LINK_FLAGS "-msse2 -O3") | ||
target_link_libraries(${exec_name} ${OpenCV_LIBRARIES}) | ||
if($ENV{ROS_DISTRO} STREQUAL "groovy" OR $ENV{ROS_DISTRO} STREQUAL "hydro") | ||
set_target_properties(${exec_name} PROPERTIES COMPILE_FLAGS "-DOPENCV_NON_FREE") | ||
endif() | ||
add_dependencies(${exec_name} posedetection_msgs_generate_messages_cpp libsiftfast) | ||
endmacro(jsk_feature detector extractor exec_name) | ||
|
||
jsk_feature("SURF" "SURF" "imagesurf") | ||
jsk_feature("STAR" "SURF" "imagestar") | ||
jsk_feature("BRISK" "BRISK" "imagebrisk") | ||
jsk_feature("SIFT" "SIFT" "imagesift_sift") | ||
jsk_feature("SIFT" "SURF" "imagesift_surf") | ||
jsk_feature("SIFT" "SIFT" "imagesift_sift") | ||
|
||
|
||
rosbuild_add_executable(imagesift imagesift.cpp) | ||
add_executable(imagesift imagesift.cpp) | ||
set_target_properties(imagesift PROPERTIES COMPILE_FLAGS "-msse2 -O3" LINK_FLAGS "-msse2 -O3") | ||
target_link_libraries(imagesift ${OpenCV_LIBRARIES}) | ||
add_dependencies(imagesift libsiftfast) | ||
add_dependencies(imagesift posedetection_msgs_generate_messages_cpp libsiftfast) | ||
|
||
|
||
install(TARGETS imagesift ${jsk_exec} | ||
ARCHIVE DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION} | ||
LIBRARY DESTINATION ${CATKIN_PACKAGE_LIB_DESTINATION} | ||
RUNTIME DESTINATION ${CATKIN_PACKAGE_BIN_DESTINATION} | ||
) |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.