本文记录一个古老的error,仅供参考。

出现error时的配置:ubuntu 16.04,GeForce GTX 1070
OGRE是gazebo使用的三维图形渲染引擎(直到现在的ignition仍在使用),我曾经在某次使用roslaunch启动gazebo时遇到过一个相关error:

(非本机原始error信息,以下摘自网络相同错误的信息)

gzserver: /build/ogre-1.9-mqY1wq/ogre-1.9-1.9.0+dfsg1/OgreMain/src/OgreRenderSystem.cpp:546: virtual void Ogre::RenderSystem::setDepthBufferFor(Ogre::RenderTarget*): Assertion `bAttached && "A new DepthBuffer for a RenderTarget was created, but after creation" "it says it's incompatible with that RT"' failed.
Aborted (core dumped)

[gazebo-1] process has died [pid 21624, exit code 134, cmd /opt/ros/kinetic/lib/gazebo_ros/gzserver -e ode /opt/ros/kinetic/share/turtlebot_gazebo/worlds/playground.world __name:=gazebo __log:=/home/pranav/.ros/log/f18cc0fc-ccc2-11e7-9a30-9cb6d0e527e7/gazebo-1.log].

解决方式:

在离线安装gazebo的时候可能在运行turtlebot_gazebo的时候会出现问题

gzclient throwing Ogre::InvalidParametersException

核心意思很简单:在我这种有独立显卡的情况下,更新一下最新的nvidia图形驱动即可。

更新显卡驱动的方法很多,在此放一些链接:

Ubuntu16.04安装NVIDIA显卡驱动

Ubuntu 16.04 禁用 nouveau 安装 nvidia显卡驱动

更具体地,在HP-Pavilion-Gaming-Desktop-790中切换到纯文本终端的方法为:
sudo init 3
然后按下ctl+alt+f9
然后在login处输入账号密码,进入纯文本终端;
切回图形终端的方法:sudo init 6或ctl+alt+delete重启

最终,更新nvidia-3XX以上版本驱动即可解决这一问题。