Skip to content

Commit

Permalink
catkinization, WIP
Browse files Browse the repository at this point in the history
  • Loading branch information
Dejan Pangercic committed Jun 25, 2014
1 parent b0535a1 commit 7316394
Show file tree
Hide file tree
Showing 4 changed files with 58 additions and 49 deletions.
51 changes: 21 additions & 30 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,37 +1,28 @@
cmake_minimum_required(VERSION 2.4.6)
include($ENV{ROS_ROOT}/core/rosbuild/rosbuild.cmake)
cmake_minimum_required(VERSION 2.8.3)
project(snap_map_icp)

# Set the build type. Options are:
# Coverage : w/ debug symbols, w/o optimization, w/ code-coverage
# Debug : w/ debug symbols, w/o optimization
# Release : w/o debug symbols, w/ optimization
# RelWithDebInfo : w/ debug symbols, w/ optimization
# MinSizeRel : w/o debug symbols, w/ optimization, stripped binaries
#set(ROS_BUILD_TYPE RelWithDebInfo)

rosbuild_init()

#set the default path for built executables to the "bin" directory
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)

#uncomment if you have defined messages
#rosbuild_genmsg()
#uncomment if you have defined services
#rosbuild_gensrv()
find_package(catkin REQUIRED std_msgs nav_msgs laser_geometry sensor_msgs geometry_msgs tf)

find_package(Eigen REQUIRED)
include_directories(${EIGEN_INCLUDE_DIRS})
add_definitions(${EIGEN_DEFINITIONS})

#common commands for building c++ executables and libraries
#rosbuild_add_library(${PROJECT_NAME} src/example.cpp)
#target_link_libraries(${PROJECT_NAME} another_library)
#rosbuild_add_boost_directories()
#rosbuild_link_boost(${PROJECT_NAME} thread)
rosbuild_add_executable(SnapMapICP src/SnapMapICP.cpp)
rosbuild_add_executable(TFpub src/TFpub.cpp)
rosbuild_add_executable(FreezeCloud2 src/FreezeCloud2.cpp)
find_package(PCL REQUIRED)
include_directories(${PCL_INCLUDE_DIRS})
link_directories(${PCL_LIBRARY_DIRS})


catkin_package(
CATKIN_DEPENDS std_msgs nav_msgs laser_geometry sensor_msgs geometry_msgs tf
)

include_directories(${catkin_INCLUDE_DIRS}
)

add_executable(SnapMapICP src/SnapMapICP.cpp)
add_executable(TFpub src/TFpub.cpp)
add_executable(FreezeCloud2 src/FreezeCloud2.cpp)

#target_link_libraries(example ${PROJECT_NAME})
target_link_libraries(SnapMapICP ${catkin_LIBRARIES} ${PCL_LIBRARIES})
target_link_libraries(TFpub ${catkin_LIBRARIES})
target_link_libraries(FreezeCloud2 ${catkin_LIBRARIES})
18 changes: 0 additions & 18 deletions manifest.xml

This file was deleted.

35 changes: 35 additions & 0 deletions package.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
<?xml version="1.0"?>
<package>
<name>snap_map_icp</name>
<version>0.0.0</version>
<description>The snap_map_icp package</description>

<maintainer email="[email protected]">Thomas Ruehr</maintainer>

<license>BSD</license>


<buildtool_depend>catkin</buildtool_depend>
<build_depend>std_msgs</build_depend>
<build_depend>nav_msgs</build_depend>
<build_depend>sensor_msgs</build_depend>
<build_depend>geometry_msgs</build_depend>
<build_depend>laser_geometry</build_depend>
<build_depend>tf</build_depend>
<build_depend>bullet</build_depend>
<build_depend version_gte="1.7.0">libpcl-all</build_depend>

<run_depend>std_msgs</run_depend>
<run_depend>nav_msgs</run_depend>
<run_depend>sensor_msgs</run_depend>
<run_depend>geometry_msgs</run_depend>
<run_depend>laser_geometry</run_depend>
<run_depend>tf</run_depend>
<run_depend>bullet</run_depend>
<run_depend version_gte="1.7.0">libpcl-all</run_depend>

<export>
</export>
</package>


3 changes: 2 additions & 1 deletion src/SnapMapICP.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@
#include <geometry_msgs/PoseWithCovarianceStamped.h>

#include <boost/thread/mutex.hpp>
//#include <bullet/LinearMath/btMatrix3x3.h>>

boost::mutex scan_callback_mutex;

Expand Down Expand Up @@ -137,7 +138,7 @@ matrixAsTransfrom (const Eigen::Matrix4f &out_mat, tf::Transform& bt)
mv[6] = out_mat (2, 1);
mv[10] = out_mat (2, 2);

btMatrix3x3 basis;
tf::Matrix3x3 basis;
basis.setFromOpenGLSubMatrix(mv);
tf::Vector3 origin(out_mat (0, 3),out_mat (1, 3),out_mat (2, 3));

Expand Down

0 comments on commit 7316394

Please sign in to comment.