一、下载realsense安装包
mkdir -p librealsense_install
cd librealsense_install/
git clone -b v2.31.0 https://github.com/IntelRealSense/librealsense.git
cd librealsense_install
二、安装一些依赖(拔掉相机)
%若安装不上,检查源
sudo apt-get install git libssl-dev libusb-1.0-0-dev pkg-config libgtk-3-dev
sudo apt-get install libglfw3-dev
三、编译安装
cd librealsense_install/librealsense
mkdir build
cd build
cmake ../ -DCMAKE_BUILD_TYPE=Release -DBUILD_EXAMPLES=true // 开流量
sudo make uninstall
make clean && make -j8
四、测试
sudo make install
cd librealsense_install/librealsense/build/examples/capture
./rs-capture
realsense-viewer
注意须使用usb3.0以上数据线