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

Force Qt to use xcb plugin on Wayland #2526

Merged
merged 2 commits into from
Aug 16, 2024
Merged

Force Qt to use xcb plugin on Wayland #2526

merged 2 commits into from
Aug 16, 2024

Conversation

iche033
Copy link
Contributor

@iche033 iche033 commented Aug 16, 2024

🦟 Bug fix

Summary

More and more users are running into the same issue on Wayland. We recently updated the troubleshooting guide for Wayland in https://gazebosim.org/docs/latest/troubleshooting/#wayland-issues. This PR just does the step described in the guide for the users. It sets Qt to use the xcb plugin if a) wayland is detected and b) only if the user has not explicitly set the QT_QPA_PLATFORM env var.

This is more of a quality of life fix to improve user experience and save them from having to go through the troubleshooting process.

Similar fix was done in rviz: ros2/rviz#1253

Checklist

  • Signed all commits for DCO
  • Added tests
  • Updated documentation (as needed)
  • Updated migration guide (as needed)
  • Consider updating Python bindings (if the library has them)
  • codecheck passed (See contributing)
  • All tests passed (See test coverage)
  • While waiting for a review on your PR, please help review another open pull request to support the maintainers

Note to maintainers: Remember to use Squash-Merge and edit the commit message to match the pull request summary while retaining Signed-off-by messages.

Signed-off-by: Ian Chen <[email protected]>
@iche033 iche033 requested a review from jennuine as a code owner August 16, 2024 03:21
@github-actions github-actions bot added the 🎵 harmonic Gazebo Harmonic label Aug 16, 2024
Copy link
Contributor

@arjo129 arjo129 left a comment

Choose a reason for hiding this comment

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

Minor knit about logging. Otherwise LGTM.

Copy link
Contributor

@azeey azeey left a comment

Choose a reason for hiding this comment

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

I've heard this workaround also has poor performance, so we should definitely be thinking about a more long term solution.

I think X is needed to create a dummy window, but I've never understood why we need a dummy window in the first place.

@iche033
Copy link
Contributor Author

iche033 commented Aug 16, 2024

one option to try is run the gui with ogre2 + EGL

@iche033 iche033 merged commit 9e31084 into gz-sim8 Aug 16, 2024
9 checks passed
@iche033 iche033 deleted the gui_wayland branch August 16, 2024 20:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🎵 harmonic Gazebo Harmonic
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

4 participants