hajimehoshi / ebiten

Ebitengine - A dead simple 2D game engine for Go
https://ebitengine.org
Apache License 2.0
10.78k stars 651 forks source link

games should work on ChromeOS's Debian Linux without setting `MESA_GL_VERSION_OVERRIDE` #3053

Open hajimehoshi opened 1 month ago

hajimehoshi commented 1 month ago

Ebitengine Version

af6072c1b4e2ba6f491b215092795c7687ea81e5

Operating System

Go Version (go version)

go version go1.22.5 linux/arm64

What steps will reproduce the problem?

Enable Linux (Debian) on ChromeOS and run an example like go run ./examples/blocks

What is the expected result?

The example runs

What happens instead?

The example failed to launch

2024/08/03 23:06:32 glfw: GLX: Failed to create context: GLXBadFBConfig: the requested API version is unavailable

Anything else you feel useful to add?

       _,met$$$$$gg.          hajimehoshi@penguin 
    ,g$$$$$$$$$$$$$$$P.       ------------------- 
  ,g$$P"     """Y$$.".        OS: Debian GNU/Linux 11 (bullseye) on Chrome OS aarch64 
 ,$$P'              `$$$.     Kernel: 5.15.117-19680-g54e910f94133 
',$$P       ,ggs.     `$$b:   Uptime: 28 mins 
`d$$'     ,$P"'   .    $$$    Packages: 668 (dpkg) 
 $$P      d$'     ,    $$P    Shell: bash 5.1.4 
 $$:      $$.   -    ,d$$'    DE: Generic 
 $$;      Y$b._   _,d$P'      Theme: CrosAdapta [GTK2/3] 
 Y$$.    `.`"Y$$$$P"'         Icons: Adwaita [GTK2/3] 
 `$$b      "-.__              Terminal: ld-linux-aarch6 
  `Y$$                        CPU: (8) 
   `Y$$.                      Memory: 104MiB / 2783MiB 
     `$$b.
       `Y$$b.                                         
          `"Y$b._                                     
              `"""
hajimehoshi commented 1 month ago
MESA_GL_VERSION_OVERRIDE=3.2 go run ./examples/blocks/

worked. Probably this is an issue in the environment, not Ebitengine. See also https://forum.winehq.org/viewtopic.php?t=34889

hajimehoshi commented 1 month ago

This should work even without setting MESA_GL_VERSION_OVERRIDE, maybe? Chrome actually works without setting anything.