Comments (21)
Can you upgrade mesa and retest?
https://launchpad.net/ubuntu/cosmic/+source/mesa says most recent version is 18.2.8.
What's the complete output of LIBGL_DEBUG=1 rwgame/rwgame
? mesa environment variables
from openrw.
I have installed mesa 18.3.3 and the same thing happened.
Should I retest with 18.2.8 version?
Output of LIBGL_DEBUG=1 ./rwgame:
$ LIBGL_DEBUG=1 ./rwgame
I [Game] Build: 11432194
libGL: Can't open configuration file /home/popov/.drirc: No such file or directory.
libGL: Can't open configuration file /home/popov/.drirc: No such file or directory.
libGL: Can't open configuration file /home/popov/.drirc: No such file or directory.
libGL: Can't open configuration file /home/popov/.drirc: No such file or directory.
libGL: Can't open configuration file /home/popov/.drirc: No such file or directory.
libGL: Can't open configuration file /home/popov/.drirc: No such file or directory.
libGL: Can't open configuration file /home/popov/.drirc: No such file or directory.
/home/popov/projects/openrw/rwengine/src/render/OpenGLRenderer.cpp:22: [OGL] Failed to create shader object
I [Game] Done cleaning up
E [exception] Compiling shader failed
from openrw.
Thanks for testing and providing the output!
I don't think testing 18.2.8 is necessary. I just wanted to rule out an outdated gl driver.
I'm still thinking you are suffering from a driver issue.
Can you please fetch the glerror_698
branch from my fork, compile and run?
git fetch https://github.com/madebr/openrw.git glerror_698
git checkout glerror_698
rwgame
will probably generate a lot of noise, so better output it to a temporary file.
I've added some extra tests which you can filter out by grepping for ERROR
.
Also, can you please try running the game with the MESA_DEBUG
environment variable set?
Again many thanks for doing this!
from openrw.
Running the game from your branch didn't generate a lot of output, but only one error:
ERROR: OpenGL implementation does not support shader compilation (throw?)
It is very strange, because docs say:
GL_SHADER_COMPILER data returns a single boolean value indicating whether an online shader compiler is present in the implementation. All desktop OpenGL implementations must support online shader compilations, and therefore the value of GL_SHADER_COMPILER will always be GL_TRUE.
MESA_DEBUG flag didn't generate any additional output:(
from openrw.
I've pushed a new commit at my fork which allowed me to see the difference between OpenGL_GL_PREFERENCE
set to GLVND
and LEGACY
.
You'll have to manually change the OpenGL_GL_PREFERENCE
variable.
For reference, on my Fedora 28 system, the variables are:
OpenGL_GL_PREFERENCE = GLVND
OPENGL_INCLUDE_DIR: /usr/include
OPENGL_EGL_INCLUDE_DIRS: /usr/include
OPENGL_LIBRARIES: /usr/lib64/libOpenGL.so;/usr/lib64/libGLX.so;/usr/lib64/libGLU.so
OPENGL_egl_LIBRARY: /usr/lib64/libEGL.so
OPENGL_glu_LIBRARY: /usr/lib64/libGLU.so
OPENGL_glx_LIBRARY: /usr/lib64/libGLX.so
OPENGL_opengl_LIBRARY: /usr/lib64/libOpenGL.so
OPENGL_gl_LIBRARY:
OpenGL_GL_PREFERENCE = LEGACY
OPENGL_INCLUDE_DIR: /usr/include
OPENGL_EGL_INCLUDE_DIRS: /usr/include
OPENGL_LIBRARIES: /usr/lib64/libGL.so;/usr/lib64/libGLU.so
OPENGL_egl_LIBRARY: /usr/lib64/libEGL.so
OPENGL_glu_LIBRARY: /usr/lib64/libGLU.so
OPENGL_glx_LIBRARY: /usr/lib64/libGLX.so
OPENGL_opengl_LIBRARY: /usr/lib64/libOpenGL.so
OPENGL_gl_LIBRARY: /usr/lib64/libGL.so
Can you post yours?
Also, does ubuntu have a glvnd
or libglvnd
library and have you installed it?
On fedora, this libglvnd
library is provided by https://github.com/NVIDIA/libglvnd
.
I don't really know what is causing it, so I would suggest opening a bug report at https://bugs.freedesktop.org or https://github.com/NVIDIA/libglvnd
I think opening an issue on the NVIDIA bug tracker and referencing this issue might help you further.
from openrw.
My OpenGL variables are similar to yours:
OpenGL_GL_PREFERENCE = GLVND
OPENGL_INCLUDE_DIR: /usr/include
OPENGL_EGL_INCLUDE_DIRS: /usr/include
OPENGL_LIBRARIES: /usr/lib/x86_64-linux-gnu/libOpenGL.so;/usr/lib/x86_64-linux-gnu/libGLX.so;/usr/lib/x86_64-linux-gnu/libGLU.so
OPENGL_egl_LIBRARY: /usr/lib/x86_64-linux-gnu/libEGL.so
OPENGL_glu_LIBRARY: /usr/lib/x86_64-linux-gnu/libGLU.so
OPENGL_glx_LIBRARY: /usr/lib/x86_64-linux-gnu/libGLX.so
OPENGL_opengl_LIBRARY: /usr/lib/x86_64-linux-gnu/libOpenGL.so
OPENGL_gl_LIBRARY:
OpenGL_GL_PREFERENCE = LEGACY
OPENGL_INCLUDE_DIR: /usr/include
OPENGL_EGL_INCLUDE_DIRS: /usr/include
OPENGL_LIBRARIES: /usr/lib/x86_64-linux-gnu/libGL.so;/usr/lib/x86_64-linux-gnu/libGLU.so
OPENGL_egl_LIBRARY: /usr/lib/x86_64-linux-gnu/libEGL.so
OPENGL_glu_LIBRARY: /usr/lib/x86_64-linux-gnu/libGLU.so
OPENGL_glx_LIBRARY: /usr/lib/x86_64-linux-gnu/libGLX.so
OPENGL_opengl_LIBRARY: /usr/lib/x86_64-linux-gnu/libOpenGL.so
OPENGL_gl_LIBRARY: /usr/lib/x86_64-linux-gnu/libGL.so
I have installed libglvnd0 libglvnd-dev and libglvnd-core-dev packages from my Ubuntu repos
I'll submit a bug to https://github.com/NVIDIA/libglvnd!
Thank you for help!
from openrw.
I've found similar issue on GLVND:
NVIDIA/libglvnd#165
There is also a bug on freedesktop where the problem was explaned.
https://bugs.freedesktop.org/show_bug.cgi?id=107990#c8
And this pull request solves the glew issue.
https://github.com/nigels-com/glew/
from openrw.
I saw those issues too yesterday and dismissed them at first because we are not using GLEW.
Anyway, I have some branches for you to test:
- updated opengl bindings by glloadgen:
git fetch https://github.com/madebr/openrw.git glerror_698
- using GLEW as opengl wrangler:
git fetch https://github.com/madebr/openrw.git glerror_698_glew
- using glad as opengl wrangler:
git fetch https://github.com/madebr/openrw.git glerror_698_glad
You might have to install libglew-dev
.
Also make sure you're testing GLVND
.
Do all bindings fail on GL_SHADER_COMPILER
?
from openrw.
glerror_698
fails on shader compilation
glerror_698_glew
gives:
OpenGLRenderer.cpp:235: glewInit() failed: Missing GL version
glerror_698_glad
cmake output:
CMake Error at cmake/modules/GenerateGlad.cmake:8 (message): Cannot find glad program
Should I install something for glad to work?
from openrw.
I've modified glerror_698_glad
to allow it to work without the glad generator.
Also, I've added an extra commit to glerror_698
, glerror_698_glew
and glerror_698_glad_2
by explicitly making the newly created gl context current.
Can you retest these? Does glew and glad work using LEGACY
?
So 4 branches for you to test + difference GLVND/LEGACY.
Again, many thanks for the testing!
glad can be installed using pypi: python3 -m pip install --user glad
.
But that should not be necessary after my changes.
from openrw.
glerror_698_glad
is working on my PC! Both on LEGACY and GLVND
glerror_698_glew
gives
OpenGLRenderer.cpp:235: glewInit() failed: Missing GL version
glerror_698
gives
E [exception] Missing GL version
So glad is seem to be a solution of the problem.
from openrw.
GLEW_ERROR_NO_GL_VERSION
is due to either failing to find the glGetString
entry point or returning an empty or unexpected version string. In turn, GLEW is using dlopen
for glXGetProcAddress
, which perhaps isn't succeeding.
from openrw.
@JorgenPo Can you post the output of glxinfo
to a gist and post a link to it here?
I've looked at the glad source and found out it hard codes the name of the libGL.so.1
library.
So it is not really a fix (or so I think).
I've replaced the NAMES
array (in glad.c
) with {"libOpenGL.so.0"}
on my machine and subsequently got a gladLoadGL
error because glad could not find the glxGetProcAddressARB
symbol.
I've also tried to let it search for glxGetProcAddress
but that failed too.
I'm probably misunderstanding how libglvnd works.
@nigels-com Do you have any suggestions how to triage this problem?
from openrw.
@JorgenPo I've created a branch with glew as a submodule:
git fetch https://github.com/madebr/openrw.git glerror_698_glew_submodule
Can you test whether your LEGACY
vs GLVND
problem is still present in that branch?
Using this branch, you can test @nigels-com 's hypothesis.
from openrw.
That's my glxinfo output: https://gist.github.com/JorgenPo/6a11369b0d8e6c787599cbea586625c3
from openrw.
glerror_698_glew_submodule
branch:
Missing GL version
on GLVND- Working on LEGACY
from openrw.
Can you try git fetch https://github.com/madebr/openrw.git glerror_698_glew_embedded
?
Can you post the complete output here (or in a gist)?
from openrw.
I've tried new branch, that's the results:
Runing with "Legacy"
22:55:08: Starting /home/popov/projects/build-openrw-test-Desktop_Qt_5_12_1_GCC_64bit-Release/rwgame/rwgame...
I [Game] Build: 9a5b205b
I [Renderer] OpenGL Renderer Version: 4.2 (Core Profile) Mesa 18.3.3 (GLSL 4.20) Vendor: Intel Open Source Technology Center
I [Game] Game directory: /home/popov/Games/Grand Theft Auto 3/
I [Game] Started
Running with "GLVND"
23:12:18: Starting /home/popov/projects/build-openrw-test-Desktop_Qt_5_12_1_GCC_64bit-Release/rwgame/rwgame...
I [Game] Build: 58bc35ab
glewContextInit GLEW_DEBUG: glewGetProcAddress("glGetString") returned 0xb61ee440
GLEW_DEBUG: getString(GL_VERSION) returned 0x0
glewContextInit GLEW_DEBUG: dot == _glewStrCLen(getString(GL_VERSION), '.') == 0x0
glewInit GLEW_DEBUG glewContextInit() returned 0x1
I [Game] Done cleaning up
E [exception] Missing GL version
23:12:21: /home/popov/projects/build-openrw-test-Desktop_Qt_5_12_1_GCC_64bit-Release/rwgame/rwgame exited with code 255
from openrw.
@nigels-com
The output shows glewGetProcAddres("glGetString")
succeeded, and getString
is found.
getString(GL_VERSION)
returned 0x0
. (instead of 0x2265b80
that is does on my system)
What would be the next appropriate step to debug this issue?
Thanks
from openrw.
@JorgenPo
What is the output ldd $LIB
for the libraries in the OPENGL_LIBRARIES
cmake list in your message above?
Mine were OPENGL_LIBRARIES=/usr/lib64/libOpenGL.so;/usr/lib64/libGLX.so;/usr/lib64/libGLU.so
.
$ ldd /usr/lib64/libOpenGL.so
linux-vdso.so.1 (0x00007ffeeb9db000)
libGLdispatch.so.0 => /lib64/libGLdispatch.so.0 (0x00007fab8c8e4000)
libdl.so.2 => /lib64/libdl.so.2 (0x00007fab8c6e0000)
libc.so.6 => /lib64/libc.so.6 (0x00007fab8c321000)
/lib64/ld-linux-x86-64.so.2 (0x00007fab8cdcc000)
$ ldd /usr/lib64/libGLX.so
linux-vdso.so.1 (0x00007fffa2bef000)
libX11.so.6 => /lib64/libX11.so.6 (0x00007fe701e99000)
libXext.so.6 => /lib64/libXext.so.6 (0x00007fe701c87000)
libGLdispatch.so.0 => /lib64/libGLdispatch.so.0 (0x00007fe7019cd000)
libdl.so.2 => /lib64/libdl.so.2 (0x00007fe7017c9000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x00007fe7015aa000)
libc.so.6 => /lib64/libc.so.6 (0x00007fe7011eb000)
libxcb.so.1 => /lib64/libxcb.so.1 (0x00007fe700fc2000)
/lib64/ld-linux-x86-64.so.2 (0x00007fe70240c000)
libXau.so.6 => /lib64/libXau.so.6 (0x00007fe700dbe000)
$ ldd /usr/lib64/libGLU.so
linux-vdso.so.1 (0x00007ffe0fd77000)
libGL.so.1 => /lib64/libGL.so.1 (0x00007fcd3fb39000)
libstdc++.so.6 => /lib64/libstdc++.so.6 (0x00007fcd3f7a6000)
libm.so.6 => /lib64/libm.so.6 (0x00007fcd3f412000)
libc.so.6 => /lib64/libc.so.6 (0x00007fcd3f053000)
libgcc_s.so.1 => /lib64/libgcc_s.so.1 (0x00007fcd3ee3b000)
libGLX.so.0 => /lib64/libGLX.so.0 (0x00007fcd3ec09000)
libX11.so.6 => /lib64/libX11.so.6 (0x00007fcd3e8c8000)
libXext.so.6 => /lib64/libXext.so.6 (0x00007fcd3e6b6000)
libGLdispatch.so.0 => /lib64/libGLdispatch.so.0 (0x00007fcd3e3fc000)
libdl.so.2 => /lib64/libdl.so.2 (0x00007fcd3e1f8000)
libpthread.so.0 => /lib64/libpthread.so.0 (0x00007fcd3dfd9000)
/lib64/ld-linux-x86-64.so.2 (0x00007fcd40039000)
libxcb.so.1 => /lib64/libxcb.so.1 (0x00007fcd3ddb0000)
libXau.so.6 => /lib64/libXau.so.6 (0x00007fcd3dbac000)
from openrw.
@JorgenPo I'm closing this issue. Re-open or comment if you have more information.
from openrw.
Related Issues (20)
- Vehicles passing from the opposite direction can lock
- SFX lacks reverb
- [Discussion] aap's librw integration
- Failed to Compile on Ubuntu 18.04 (ARM64) HOT 2
- Building the Viewer HOT 2
- Map viewer tool HOT 6
- Camera falls through walls
- Distribute openrw in a Flatpak HOT 4
- Can compile, but i get many warnings. Plus OpenAL wont get linked HOT 2
- [MacOS Catalina] [graphics] GLviewport is half the size of the game window HOT 2
- Unable to build in mingw64, undefined boost references HOT 1
- Texture flickering (Windows 10)
- no longer builds on openbsd. HOT 2
- [Windows][Conan] Conan errors out whilst trying to create vs solution HOT 2
- How compile under Slackware(64) 14.2 HOT 5
- Failing to build on linux HOT 2
- Failing to build on linux pt2 HOT 2
- librwengine.so: Could not resolve symbol HOT 2
- About Grand Theft Auto III decompiled HOT 6
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from openrw.