introlab / rtabmap

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

Segmentation Fault with 3D map view #1385

Open jared-cormier opened 3 days ago

jared-cormier commented 3 days ago

Any interaction or change in the 3D Map window causes a segmentation fault. I suspect this has something to do with VTK9.1, but I haven't worked with C++ in about 10 years, so I'm a little rusty. Logging was pretty useless unless there's a logging flag not in the main preferences screen. Haven't had time to build all the dependencies from source to really nail down where the issue is occurring, but figured I'd log this until I can get more time to dive into it.

Configuration:

-- Info : -- RTAB-Map Version = 0.21.8 -- CMAKE_VERSION = 3.25.1 -- CMAKE_INSTALL_PREFIX = /usr/local -- CMAKE_BUILD_TYPE = Release -- CMAKE_INSTALL_LIBDIR = lib -- BUILD_APP = ON -- BUILD_TOOLS = ON -- BUILD_EXAMPLES = ON -- BUILD_SHARED_LIBS = ON -- CMAKE_CXX_FLAGS = -fmessage-length=0 -fopenmp -std=c++17 -- FLANN_KDTREE_MEM_OPT = OFF -- PCL_DEFINITIONS = -DEIGEN_HAS_CXX17_OVERALIGN=0 -- PCL_VERSION = 1.14.1

-- Optional dependencies ('' affects some default parameters) : -- With OpenCV 4.6.0 xfeatures2d = NO, nonfree = NO (License: Apache 2) -- With Qt 5.15.8 = YES (License: Open Source or Commercial) -- With VTK 9.1 = YES (License: BSD) -- With external SQLite3 = YES (License: Public Domain) -- With ORB OcTree = YES (License: GPLv3) -- With SupertPoint = NO (WITH_TORCH=OFF) -- With Python3 = NO (WITH_PYTHON=OFF) -- With Madgwick = YES (License: GPL) -- With FastCV = NO (FastCV not found) -- With PDAL = NO (PDAL not found) -- With libLAS = NO (WITH_LIBLAS=OFF) -- With CudaSift = NO (WITH_CUDASIFT=OFF)

-- Solvers: -- With TORO = YES (License: Creative Commons [Attribution-NonCommercial-ShareAlike]) -- With g2o 1.0.0 = YES (License: BSD) -- With GTSAM = NO (GTSAM not found) -- With Ceres = NO (WITH_CERES=OFF) -- With MRPT = NO (MRPT not found) -- With VERTIGO = YES (License: GPLv3) -- With cvsba = NO (WITH_CVSBA=OFF) -- With libpointmatcher = NO (libpointmatcher not found) -- With CCCoreLib = NO (WITH_CCCORELIB=OFF) -- With Open3D = NO (WITH_OPEN3D=OFF) -- With OpenGV = NO (OpenGV not found)

-- Reconstruction Approaches: -- With OctoMap = NO (octomap not found) -- With GridMap = NO (grid_map_core not found) -- With CPUTSDF = NO (WITH_CPUTSDF=OFF) -- With OpenChisel = NO (WITH_OPENCHISEL=OFF) -- With AliceVision = NO (WITH_ALICE_VISION=OFF)

-- Camera Drivers: -- With Freenect = YES (License: Apache v2 and/or GPLv2) -- With OpenNI = NO (OpenNI not found) -- With OpenNI2 = YES (License: Apache v2) -- With Freenect2 = NO (libfreenect2 not found) -- With Kinect for Windows 2 = NO (Kinect for Windows 2 SDK not found) -- With Kinect for Azure = NO (Kinect for Azure SDK not found) -- With dc1394 = YES (License: LGPL) -- With FlyCapture2/Triclops = NO (Point Grey SDK not found) -- With ZED = NO (ZED sdk and/or cuda not found) -- With ZEDOC = NO (ZED Open Capture not found) -- With RealSense = NO (librealsense not found) -- With RealSense2 = NO (librealsense2 not found) -- With MyntEyeS = NO (mynteye s sdk not found) -- With DepthAI = NO (WITH_DEPTHAI=OFF) -- With XVisio SDK = NO (WITH_XVSDK=OFF)

-- Odometry Approaches: -- With loam_velodyne = NO (WITH_LOAM=OFF) -- With floam = NO (WITH_FLOAM=OFF) -- With libfovis = NO (WITH_FOVIS=OFF) -- With libviso2 = NO (WITH_VISO2=OFF) -- With dvo_core = NO (WITH_DVO=OFF) -- With okvis = NO (WITH_OKVIS=OFF) -- With msckf_vio = NO (WITH_MSCKF_VIO=OFF) -- With VINS-Fusion = NO (WITH_VINS=OFF) -- With OpenVINS = NO (WITH_OPENVINS=OFF) -- With ORB_SLAM = NO (WITH_ORBSLAM=OFF) -- Show all options with: cmake -LA | grep WITH

-- Configuring done -- Generating done

jared-cormier commented 2 days ago

Update: added OctoMap as that looks like a conditional dependency, no change; next steps: build older VTK versions and recompile.

jared-cormier commented 2 days ago

https://github.com/introlab/rtabmap/blob/b2e26e81c14bd7a1394da10998d0264968089cbe/guilib/src/CloudViewer.cpp#L3808 One of the failing lines. I did discover, as part of my spamming of log messages, I did find there were other locations which I shall try to identify the exact locations of prior to attempting fixes.