Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions patch/ros-lyrical-rtabmap-conversions.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 4dc4190..ed08e21 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -9,8 +9,7 @@ if(CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64")
# issues #1285 #1288
find_library(
builtin_interfaces__rosidl_generator_c_LIB NAMES builtin_interfaces__rosidl_generator_c
- PATHS "/opt/ros/$ENV{ROS_DISTRO}/lib"
- NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH REQUIRED
+ REQUIRED
)
endif()

diff --git a/include/rtabmap_conversions/MsgConversion.h b/include/rtabmap_conversions/MsgConversion.h
index 4e82e38..6f657f3 100644
--- a/include/rtabmap_conversions/MsgConversion.h
+++ b/include/rtabmap_conversions/MsgConversion.h
@@ -39,7 +39,11 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include <sensor_msgs/msg/point_cloud2.hpp>

#include <opencv2/opencv.hpp>
+#if CV_MAJOR_VERSION < 5
#include <opencv2/features2d/features2d.hpp>
+#else
+#include <opencv2/features.hpp>
+#endif
#ifdef PRE_ROS_IRON
#include <cv_bridge/cv_bridge.h>
#else
14 changes: 14 additions & 0 deletions patch/ros-lyrical-rtabmap-msgs.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 01e7ceb..f97a796 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -14,8 +14,7 @@ if(CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64")
# issues #1285 #1288
find_library(
rcutils_LIB NAMES rcutils
- PATHS "/opt/ros/$ENV{ROS_DISTRO}/lib"
- NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH REQUIRED
+ REQUIRED
)
endif()

14 changes: 14 additions & 0 deletions patch/ros-lyrical-rtabmap-odom.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 7b10ad2..6ef5020 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -14,8 +14,7 @@ if(CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64")
# issues #1285 #1288
find_library(
builtin_interfaces__rosidl_generator_c_LIB NAMES builtin_interfaces__rosidl_generator_c
- PATHS "/opt/ros/$ENV{ROS_DISTRO}/lib"
- NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH REQUIRED
+ REQUIRED
)
endif()

14 changes: 14 additions & 0 deletions patch/ros-lyrical-rtabmap-rviz-plugins.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 4e47a68..c8eb361 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -9,8 +9,7 @@ if(CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64")
# issues #1285 #1288
find_library(
message_filters_LIB NAMES message_filters
- PATHS "/opt/ros/$ENV{ROS_DISTRO}/lib"
- NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH REQUIRED
+ REQUIRED
)
endif()

27 changes: 27 additions & 0 deletions patch/ros-lyrical-rtabmap-slam.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 6107b23..97ea89f 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -14,8 +14,7 @@ if(CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64")
# issues #1285 #1288
find_library(
builtin_interfaces__rosidl_generator_c_LIB NAMES builtin_interfaces__rosidl_generator_c
- PATHS "/opt/ros/$ENV{ROS_DISTRO}/lib"
- NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH REQUIRED
+ REQUIRED
)
endif()

diff --git a/src/CoreWrapper.cpp b/src/CoreWrapper.cpp
index c1fb75b..bb732d6 100644
--- a/src/CoreWrapper.cpp
+++ b/src/CoreWrapper.cpp
@@ -1474,7 +1474,7 @@ void CoreWrapper::commonMultiCameraCallbackImpl(
cv::Mat leftMono;
if(rgb.channels() == 3)
{
- cv::cvtColor(rgb, leftMono, CV_BGR2GRAY);
+ cv::cvtColor(rgb, leftMono, cv::COLOR_BGR2GRAY);
}
else
{
20 changes: 20 additions & 0 deletions patch/ros-lyrical-rtabmap-sync.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 106d23c..70eaa47 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -5,13 +5,11 @@ if(CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64")
# issues #1285 #1288
find_library(
builtin_interfaces__rosidl_generator_c_LIB NAMES builtin_interfaces__rosidl_generator_c
- PATHS "/opt/ros/$ENV{ROS_DISTRO}/lib"
- NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH REQUIRED
+ REQUIRED
)
find_library(
crypto_LIB NAMES crypto
- PATHS "/usr/lib/${CMAKE_SYSTEM_PROCESSOR}-linux-gnu"
- NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH REQUIRED
+ REQUIRED
)
endif()

56 changes: 56 additions & 0 deletions patch/ros-lyrical-rtabmap-viz.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index add21b0..371140e 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -9,18 +9,15 @@ if(CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64")
# issues #1285 #1288
find_library(
builtin_interfaces__rosidl_generator_c_LIB NAMES builtin_interfaces__rosidl_generator_c
- PATHS "/opt/ros/$ENV{ROS_DISTRO}/lib"
- NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH REQUIRED
+ REQUIRED
)
find_library(
rcutils_LIB NAMES rcutils
- PATHS "/opt/ros/$ENV{ROS_DISTRO}/lib"
- NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH REQUIRED
+ REQUIRED
)
find_library(
crypto_LIB NAMES crypto
- PATHS "/usr/lib/${CMAKE_SYSTEM_PROCESSOR}-linux-gnu"
- NO_DEFAULT_PATH NO_CMAKE_FIND_ROOT_PATH REQUIRED
+ REQUIRED
)
endif()

diff --git a/src/GuiNode.cpp b/src/GuiNode.cpp
index 88895ed..e62af21 100644
--- a/src/GuiNode.cpp
+++ b/src/GuiNode.cpp
@@ -32,6 +32,11 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
#include <rtabmap/gui/MainWindow.h>
#include <rtabmap/utilite/ULogger.h>
#include <signal.h>
+#include <QSurfaceFormat>
+#include <vtkVersionMacros.h>
+#if VTK_MAJOR_VERSION > 9 || (VTK_MAJOR_VERSION==9 && VTK_MINOR_VERSION >= 1)
+#include <QVTKRenderWidget.h>
+#endif

QApplication * app = 0;

@@ -49,6 +54,13 @@ int main(int argc, char** argv)

rclcpp::init(argc, argv);

+#if VTK_MAJOR_VERSION > 9 || (VTK_MAJOR_VERSION==9 && VTK_MINOR_VERSION >= 1)
+ // needed to ensure appropriate OpenGL context is created for VTK rendering
+ // (without it, macOS creates a legacy OpenGL 2.1 context and VTK crashes).
+ QSurfaceFormat::setDefaultFormat(QVTKRenderWidget::defaultFormat());
+#endif
+ QApplication::setAttribute(Qt::AA_ShareOpenGLContexts);
+
app = new QApplication(argc, argv);
app->connect( app, SIGNAL( lastWindowClosed() ), app, SLOT( quit() ) );

1 change: 1 addition & 0 deletions vinca.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -431,6 +431,7 @@ packages_select_by_deps:
- rqt_reconfigure
- rqt_tf_tree
- rslidar_sdk
- rtabmap_ros
- rviz_2d_overlay_plugins
- rviz_satellite
- serial_driver
Expand Down
Loading