Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Drop Mesa workaround #1714

Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 0 additions & 14 deletions src/rviz/ogre_helpers/render_system.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,6 @@ void RenderSystem::loadOgrePlugins()

void RenderSystem::detectGlVersion()
{
bool mesa_workaround = false;
if (force_gl_version_)
{
gl_version_ = force_gl_version_;
Expand All @@ -184,10 +183,6 @@ void RenderSystem::detectGlVersion()
int major = caps->getDriverVersion().major;
int minor = caps->getDriverVersion().minor;
gl_version_ = major * 100 + minor * 10;

std::string gl_version_string = (const char*)glGetString(GL_VERSION);
// The "Mesa 2" string is intended to match "Mesa 20.", "Mesa 21." and so on
mesa_workaround = gl_version_string.find("Mesa 2") != std::string::npos && gl_version_ >= 320;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My suggestion would have been to just change this to "Mesa 20"

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was the Mesa 20 part of some HWE or part of the stock 18.04, ie are there likely going to be people with non HWE systems running into this again?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

$ LANG=C apt-cache policy mesa-va-drivers 
mesa-va-drivers:
  Installed: 21.3.6~kisak1~b
  Candidate: 21.3.6~kisak1~b
  Version table:
 *** 21.3.6~kisak1~b 500
        500 http://ppa.launchpad.net/kisak/kisak-mesa/ubuntu bionic/main amd64 Packages
        100 /var/lib/dpkg/status
     20.0.8-0ubuntu1~18.04.1 500
        500 http://cz.archive.ubuntu.com/ubuntu bionic-updates/universe amd64 Packages
     19.2.8-0ubuntu0~18.04.2 500
        500 http://security.ubuntu.com/ubuntu bionic-security/universe amd64 Packages
     18.0.0~rc5-1ubuntu1 500
        500 http://cz.archive.ubuntu.com/ubuntu bionic/universe amd64 Packages

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's on Bionic HWE with kisak-mesa PPA. So it seems 20.x is available via bionic-updates for everyone.

}

switch (gl_version_)
Expand Down Expand Up @@ -218,15 +213,6 @@ void RenderSystem::detectGlVersion()
}
break;
}
if (mesa_workaround)
{ // https://github.com/ros-visualization/rviz/issues/1508
ROS_INFO("OpenGl version: %.1f (GLSL %.1f) limited to GLSL 1.4 on Mesa system.",
(float)gl_version_ / 100.0, (float)glsl_version_ / 100.0);

gl_version_ = 310;
glsl_version_ = 140;
return;
}
ROS_INFO("OpenGl version: %.1f (GLSL %.1f).", (float)gl_version_ / 100.0, (float)glsl_version_ / 100.0);
}

Expand Down