在ros中运行rviz时不断刷出错误
0x29a0920 void QWindowPrivate::setTopLevelScreen(QScreen*, bool) ( QScreen(0x1e857b0) ): Attempt to set a screen on a child window.
该错误会在多显示器的环境下报出,并不是使用上的错误而是rviz本身与Qt的一个bug
Finally, I understood what happens:
The warning messages occur whenever setMinimumWidth() / setMinimumHeight() are called on a QGLWidget under Linux with a dual screen display.
This is probably a bug in Qt. It will probably be not fixed, since it is recommended in the documentation to use the new QOpenGLWidget instead, that appeared in Qt 5.4 (note: "OpenGL" instead of "GL"), which I did and the warning messages disappeared.
Edit: I saw a message from someone that had problems with text not rendering properly with the new QOpenGLWidget which I answer here: When using the new QOpenGLWidget, one needs to take care that it no longer has an independent OpenGL context, it shares the OpenGL context with Qt (therefore, OpenGL states modified in the rendering function needs to be restored after exiting the rendering function, for instance blending mode).
rviz作者暂时没有解决这个问题
在ROS环境中使用RVIZ时,在多显示器配置下会遇到与Qt相关的错误,这并非操作失误,而是RVIZ与Qt在特定环境下的已知问题。错误源自对QGLWidget的尺寸限制调用,此问题在切换到Qt5.4的QOpenGLWidget后消失。
923

被折叠的 条评论
为什么被折叠?



