Sophus安装:
git clone https://github.com/strasdat/sophus.git
cd sophus
mkdir build
cmake ..
make
这时候系统报错
error: lvalue required as left operand of assignment
32 | unit_complex_.real() = 1.;
| ~~~~~~~~~~~~~~~~~~^~
error: lvalue required as left operand of assignment
32 | unit_complex_.real() = 1.;
| ~~~~~~~~~~~~~~~~~~^~
这是因为实例unit_complex_的方法real()和imag()不能用=直接赋值:
SO2::SO2()
{
// unit_complex_.real() = 1.;
unit_complex_.real(1.);
// unit_complex_.imag() = 0.;
unit_complex_.imag(0.);
}
具体步骤:
cd ./sophus/sophus
sudo nano so2.cpp
保存后退出,再进入build文件夹中进行cmake
sudo make
本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)