For a long time (roughly since Ignition Edifice release, i.e. April 2021), gz-sim had problems with running under WSLg with GPU support. A workaround that at this point was suggested in the community was to force software rendering when running gz sim on WSLg, by setting the environment variable
As tracked in No camera/render on ubuntu (WSLg + vGPU) · Issue #920 · gazebosim/gz-sim · GitHub, thanks to several fixes that were applied in ogre-next and gz-rendering,
export LIBGL_ALWAYS_SOFTWARE=1 (i.e. forcing software rendering) is not necessary anymore when running the latest version of Gazebo Garden and Harmonic on Ubuntu 22.04 on WSLg.
If instead you are still experiencing problems with Gazebo Garden or Harmonic, please open a new issue in Sign in to GitHub · GitHub, providing all the graphics-related information requested in the template.
Note that WSLg is still not an officially tested platform for Gazebo, and so regression may happen. Also in this case, feel free to open issue if you experience regressions.