
Code: Select all
void CMyLoopFunctions::PostStep() {
CQTOpenGLUserFunctions& cUF = dynamic_cast<CQTOpenGLRender&>(GetSimulator().GetVisualization()).GetMainWindow().GetUserFunctions();
// find the robot you want to select (cMyRobot)
cUF.SelectEntity(cMyRobot);
}
This simply means that you need to add an #include statement to tell the compiler about the missing class symbol:"Expected type-specifier before CQTOpenGLRender"
"CQTOpenGLRender was not declared in this scope"
Code: Select all
#include <argos3/plugins/simulator/visualizations/qt-opengl/qtopengl_render.h>
As I don't have your code, I can't understand why this happens. The general idea is that GetSimulator() is a method of CLoopFunctions, so if you're calling it from the wrong place (e.g., not within the loop functions) you need to also include the loop function object."GetSimulator was not declared in this scope"