深度参考:
Ubuntu16.04系统运行vins mono(完整版环境配置及编译)_keeperhr的博客-CSDN博客
Ubuntu16.04系统运行VINS-Mono(安装、环境配置)_小家伙还不放假的博客-CSDN博客
环境都配置好以后,git clone了代码,但是这三步走只运行了第一步:
roslaunch vins_estimator euroc.launch
roslaunch vins_estimator vins_rviz.launch
rosbag play YOUR_PATH_TO_DATASET/MH_01_easy.bag
第二步中,rviz启动一闪而过, 报错exit code -11:
process[rvizvisualisation-1]: started with pid [1641]
[rvizvisualisation-1] process has died [pid 1641, exit code -11, cmd /opt/ros/kinetic/lib/rviz/rviz -d /home/nianh/catkin_ws/src/VINS-Mono/vins_estimator/../config/vins_rviz_config.rviz __name:=rvizvisualisation __log:=/home/nianh/.ros/log/5de19c9e-0726-11ed-b07a-e0d55eb736d6/rvizvisualisation-1.log].
log file: /home/nianh/.ros/log/5de19c9e-0726-11ed-b07a-e0d55eb736d6/rvizvisualisation-1*.log
all processes on machine have died, roslaunch will exit
shutting down processing monitor...
... shutting down processing monitor complete
done
整整一天各种查,试,找不到原因,找了一些apt-get update的方法没有起作用。又去查找了wsl下ros启动rviz的问题,运行了小乌龟测试ok。再执行了
rosrun rviz rviz
很神奇,rviz直接启动成功!再重新尝试三步走的第二步,成功调起rviz。不确定是不是下面这类设置起的作用。因为前面试过好几次了。
export LIBGL_ALWAYS_INDIRECT=0
或者
export LIBGL_ALWAYS_SOFTWARE=1