introlab / rtabmap

RTAB-Map library and standalone application
https://introlab.github.io/rtabmap
Other
2.83k stars 787 forks source link

Ouster SDK integration #1328

Open matlabbe opened 3 months ago

matlabbe commented 3 months ago

Install https://github.com/ouster-lidar/ouster-sdk

Verify rtabmap is detecting it at the end of cmake output:

--  LiDAR Drivers:
--   With Velodyne VLP16       = YES
--   With Ouster SDK 20231031  = YES            <------

Ouster sample data to try on: https://static.ouster.dev/sensor-docs/#sample-data

Integrated to tools:

Integrated to standalone UI: 2024-08-18_21-25 image

Peek 2024-08-18 21-02

Presets for convenience to use indoor or outdoor: image

matlabbe commented 2 months ago

On Windows, use OusterSDK DLL version: https://github.com/ouster-lidar/ouster-sdk/pull/608 to avoid "silent crash" (in this function) with the static library (still not sure what is causing this, rtabmap includes a bunch of dependencies that may clash with the static library).

For convenience, apply this patch:

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 9994531..4986fc6 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -13,7 +13,7 @@ include(DefaultBuildType)
 include(VcpkgEnv)

 # ==== Project Name ====
-project(ouster_example VERSION 20231031)
+project(OusterSDK VERSION 20231031)

so that OusterSDK library installed in Program Files can be detected automatically with cmake, otherwise we need to do:

cmake -DOusterSDK_DIR="C:/Program Files (x86)/ouster_example/lib/cmake/OusterSDK ..

Well, if C:\Program Files (x86)\OusterSDK\bin is on the PATH, that may work even if we don't change project name (not tested).