💾 Archived View for alaskalinuxuser.ddns.net › 2023-12-12.gmi captured on 2024-12-17 at 10:12:00. Gemini links have been rewritten to link to archived content
⬅️ Previous capture (2024-09-29)
-=-=-=-=-=-=-
">
33w, https://alaskalinuxuser3.ddns.net/wp-content/uploads/2023/12/godot3_2_3_b-
300x300.png 300w, https://alaskalinuxuser3.ddns.net/wp-content/uploads/2023/12/
godot3_2_3_b-150x150.png 150w" sizes="(max-width: 633px) 100vw, 633px" /
One of my side hobbies is learning how to make video games in Godot. I was
going through a great tutorial, but I got sidetracked due to the usual life
circumstances. Now I have a little more free time again, and I want to get back
into learning Godot. One problem that I ran into though, is that my old laptop
was giving me openGL errors….
When I launch Godot3, it loads like normal, allows me to download templates and
projects, edit them (with a 3D editor) and all the usual functions. Knowing
that my old laptop doesn’t support GLES3, I choose GLES2, but, when I tried to
launch any program, it would give me a popup saying it couldn’t run.
Specifically, there was a popup stating this:
Your video card driver does not support any of the supported OpenGL
versions.\nPlease update your drivers or if you have a very old or integrated
GPU upgrade it.
I thought this was rather strange. I’m using Ubuntu 22.04 LTS, and the
repository has Godot version 3.2.3 in it by default. While I do want to upgrade
and try out Godot4, this older version is perfect for the online tutorial that
I am following, which used Godot3 when it was made.
A quick check of my system revealed:
$ lspci |grep Display\n00:02.1 Display controller: Intel Corporation Mobile
GM965/GL960 Integrated Graphics Controller (secondary) (rev 03)
So, my graphics card was an Intel GM965. A quick search to make sure the driver
was loaded confirmed that it was properly loaded:
$ lsmod |grep video\nvideo 73728 2 i915,panasonic_laptop\nwmi
40960 1 video\n$ lsmod |grep i915\ni915 3899392 11\ndrm_buddy
20480 1 i915\nttm 110592 1 i915\ndrm_display_helper
212992 1 i915\ncec 94208 2
drm_display_helper,i915\ndrm_kms_helper 249856 2
drm_display_helper,i915\ni2c_algo_bit 16384 1 i915\ndrm
700416 15 drm_kms_helper,drm_display_helper,drm_buddy,i915,ttm\nvideo
73728 2 i915,panasonic_laptop
Which I confirmed online was the appropriate driver. Checking with glxinfo also
shows that OpenGL version is 2.1, and OpenGL ES is 2.0:
$ glxinfo | grep OpenGL\nOpenGL vendor string: Intel\nOpenGL renderer string:
Mesa Intel(R) 965GM (CL)\nOpenGL version string: 2.1 Mesa 23.0.4-
0ubuntu1~22.04.1\nOpenGL shading language version string: 1.20\nOpenGL
extensions:\nOpenGL ES profile version string: OpenGL ES 2.0 Mesa 23.0.4-
0ubuntu1~22.04.1\nOpenGL ES profile shading language version string: OpenGL ES
GLSL ES 1.0.16\nOpenGL ES profile extensions:
So if my information is correct, my laptop supports GLES 2.0, but for some
reason Godot3 was not working, reporting that no version of OpenGL was
available on my system. Not taking this at face value, I decided to run Godot
from the terminal and see what the stdout says, which was quite a bit, but here
is the relevant part:
Godot Engine v3.2.3.stable.custom_build - https://godotengine.org\nX Error of
failed request: GLXBadFBConfig\n Major opcode of failed request: 152 (GLX)\n
Minor opcode of failed request: 0 ()\n Serial number of failed request: 31\n
Current serial number in output stream: 31\nX Error of failed request:
GLXBadFBConfig\n Major opcode of failed request: 152 (GLX)\n Minor opcode of
failed request: 0 ()\n Serial number of failed request: 31\n Current serial
number in output stream: 31\nERROR: initialize: Condition "ctxErrorOccurred
|| !p->glx_context" is true. Returned: ERR_UNCONFIGURED\n At: platform/x11/
context_gl_x11.cpp:190.\nERROR: is_viable: Error initializing GLAD\n At:
drivers/gles3/rasterizer_gles3.cpp:141.
So despite being OpenGL 2.0 on my machine, and despite Godot allowing GLES 2.0
to be used, it was giving the error because it could not find GLES 3.0!
Interesting. With this knowledge, I decided to try a different approach. I made
a new project, choosing GLES 2.0 for the project, and then created a small 3D
world with one camera and one cube. It launched flawlessly.
Odd. This is when I came to the realization that choosing GLES 2.0 or GLES 3.0
from the top right runtime menu really doesn’t do anything. Loading a project
and choosing GLES 2.0 doesn’t make that project a 2.0 project if it was built
using GLES 3.0. I found several demo projects that were older, written in GLES
2.0 which worked perfectly. However, if the project was built originally
choosing GLES 3.0, it will only run as GLES 3.0, despite you choosing to build
and run it as GLES 2.0 from the runtime menu.
I also found that every project has a setting for GLES 2/3 in:
Project -> Project Settings -> Rendering -> Quality\n\nDriver name -> GLES3 or
GLES2\nFallback to GLES2 yes/no
And if you use a GLES 3.0 project, and change it to GLES 2.0, with/or a
fallback to GLES 2, it will no longer give the error for not finding GLES 3 in
the terminal, and it will not give the popup for wrong or missing OpenGL,
however, under all the test projects I tried, they would all crash immediately.
The only logical conclusion that I can come to is that when a project is
created, you have to choose GLES 2 or 3, and your choice will ultimately make
that project permanently a 2 or 3, regardless of which runtime renderer is
chosen while developing.
An example project that was built with GLES 2.0 is “Github Cube Characters”
found under the community templates. It will run flawlessly, because it was a
3D project built from the ground up on GLES 2.0. An example project built with
GLES 3 that will only work with GLES 3 is the “Kinematic Character 3D” project
which is also found under the community templates.
In the end, I simply learned that choosing GLES 2 or 3 from the runtime menu
was irrelevant. The project has to be built as a GLES 2.0 project to work on my
old machine. Which, for the purposes of my tutorial will not make much
difference.
Linux – keep it simple.
P.S. As an interesting side note, the Intel GM965 when used with Windows only
supports OpenGL version 1.5, but under Linux can support 2.0, which I find very
odd.