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

QOpenGLShaderProgram shader errors - black window #3106

Closed
niki-sp opened this issue Oct 13, 2017 · 13 comments
Closed

QOpenGLShaderProgram shader errors - black window #3106

niki-sp opened this issue Oct 13, 2017 · 13 comments

Comments

@niki-sp
Copy link

@niki-sp niki-sp commented Oct 13, 2017

I get black window and errors:

$ qutebrowser
13:53:04 INFO: Run :adblock-update to get adblock lists.
13:53:04 WARNING: QOpenGLShaderProgram: could not create shader program
13:53:04 WARNING: QOpenGLShader: could not create shader
13:53:04 WARNING: Could not link shader program:
""
13:53:04 WARNING: QOpenGLShaderProgram: could not create shader program
13:53:04 WARNING: QOpenGLShader: could not create shader
13:53:04 WARNING: QOpenGLShader: could not create shader
13:53:04 WARNING: shader compilation failed:
""
13:53:04 WARNING: QOpenGLShaderProgram::uniformLocation( matrix ): shader program is not linked
13:53:04 WARNING: QOpenGLShaderProgram::uniformLocation( color ): shader program is not linked
13:53:04 WARNING: QOpenGLShaderProgram: could not create shader program
13:53:04 WARNING: QOpenGLShader: could not create shader
13:53:04 WARNING: QOpenGLShader: could not create shader
13:53:04 WARNING: shader compilation failed:
""

$ qutebrowser --version
qutebrowser v1.0.1
Git commit:
Backend: QtWebEngine (Chromium 49.0.2623.111)

CPython: 3.5.3
Qt: 5.7.1
PyQt: 5.7

sip: 4.18.1
colorama: no
pypeg2: 2.15
jinja2: 2.9.5
pygments: 2.2.0
yaml: 3.12
cssutils: no
attr: 17.2.0
PyQt5.QtWebEngineWidgets: yes
PyQt5.QtWebKitWidgets: yes
pdf.js: no
sqlite: 3.16.2
QtNetwork SSL: OpenSSL 1.0.2g 1 Mar 2016

Style: QFusionStyle
Platform: Linux-4.10.0-37-generic-x86_64-with-Ubuntu-17.04-zesty, 64bit
Linux distribution: Ubuntu 17.04 (ubuntu)
Frozen: False

@The-Compiler

This comment has been minimized.

Copy link
Member

@The-Compiler The-Compiler commented Oct 13, 2017

Can you show glxinfo -B please (might to install it first)? Also, if you recently did an upgrade of your graphic drivers or kernel, did you reboot since then?

@dllu

This comment has been minimized.

Copy link

@dllu dllu commented Oct 13, 2017

I have a similar problem here on Ubuntu 16.04. I installed Qutebrowser from tox as per the instructions at https://www.qutebrowser.org/INSTALL.html#tox.

qutebrowser
12:59:39 WARNING: QOpenGLShaderProgram: could not create shader program
12:59:39 WARNING: QOpenGLShader: could not create shader
12:59:39 WARNING: Could not link shader program:
 ""
12:59:39 WARNING: QOpenGLShaderProgram: could not create shader program
12:59:39 WARNING: QOpenGLShader: could not create shader
12:59:39 WARNING: QOpenGLShader: could not create shader
12:59:39 WARNING: shader compilation failed: 
""
12:59:39 WARNING: QOpenGLShaderProgram::uniformLocation(matrix): shader program is not linked
12:59:39 WARNING: QOpenGLShaderProgram::uniformLocation(opacity): shader program is not linked
12:59:39 WARNING: QOpenGLShaderProgram: could not create shader program
12:59:39 WARNING: QOpenGLShader: could not create shader
12:59:39 WARNING: QOpenGLShader: could not create shader
12:59:39 WARNING: shader compilation failed: 
""
12:59:39 WARNING: QOpenGLShaderProgram::uniformLocation(matrix): shader program is not linked
12:59:39 WARNING: QOpenGLShaderProgram::uniformLocation(opacity): shader program is not linked
12:59:39 WARNING: QOpenGLShaderProgram: could not create shader program
12:59:39 WARNING: QOpenGLShader: could not create shader
12:59:39 WARNING: QOpenGLShader: could not create shader
12:59:39 WARNING: shader compilation failed: 
""

These messages just keep repeating until I close it.

qutebrowser --version
qutebrowser v1.0.1
Git commit: v1.0.1-1-gdb8fa5f (2017-10-13 10:45:40 +0200)
Backend: QtWebEngine (Chromium 56.0.2924.122)

CPython: 3.5.2
Qt: 5.9.1
PyQt: 5.9

sip: 4.19.3
colorama: 0.3.9
pypeg2: 2.15
jinja2: 2.9.6
pygments: 2.2.0
yaml: 3.12
cssutils: 1.0.2 $Id$
attr: 17.2.0
PyQt5.QtWebEngineWidgets: yes
PyQt5.QtWebKitWidgets: no
pdf.js: no
sqlite: 3.16.2
QtNetwork SSL: OpenSSL 1.0.2g  1 Mar 2016

Style: QFusionStyle
Platform: Linux-4.4.0-97-generic-x86_64-with-Ubuntu-16.04-xenial, 64bit
Linux distribution: Ubuntu 16.04.3 LTS (ubuntu)
Frozen: False
Imported from /home/dllu/Proj/qutebrowser/qutebrowser
Qt library executable path: /home/dllu/Proj/qutebrowser/.venv/lib/python3.5/site-packages/PyQt5/Qt/libexec, data path: /home/dllu/Proj/qutebrowser/.venv/lib/python3.5/site-packages/PyQt5/Qt

Paths:
cache: /home/dllu/.cache/qutebrowser
config: /home/dllu/.config/qutebrowser
data: /home/dllu/.local/share/qutebrowser
runtime: /run/user/1000/qutebrowser

As for glxinfo -B

glxinfo -B
name of display: :0
display: :0  screen: 0
direct rendering: Yes
OpenGL vendor string: NVIDIA Corporation
OpenGL renderer string: GeForce GTX 1070/PCIe/SSE2
OpenGL core profile version string: 4.5.0 NVIDIA 381.22
OpenGL core profile shading language version string: 4.50 NVIDIA
OpenGL core profile context flags: (none)
OpenGL core profile profile mask: core profile

OpenGL version string: 4.5.0 NVIDIA 381.22
OpenGL shading language version string: 4.50 NVIDIA
OpenGL context flags: (none)
OpenGL profile mask: (none)

OpenGL ES profile version string: OpenGL ES 3.2 NVIDIA 381.22
OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.20

And nvidia info:

nvidia-smi
Fri Oct 13 13:02:42 2017       
+-----------------------------------------------------------------------------+
| NVIDIA-SMI 381.22                 Driver Version: 381.22                    |
|-------------------------------+----------------------+----------------------+
| GPU  Name        Persistence-M| Bus-Id        Disp.A | Volatile Uncorr. ECC |
| Fan  Temp  Perf  Pwr:Usage/Cap|         Memory-Usage | GPU-Util  Compute M. |
|===============================+======================+======================|
|   0  GeForce GTX 1070    Off  | 0000:01:00.0      On |                  N/A |
| 28%   41C    P8    13W / 151W |    707MiB /  8110MiB |      3%      Default |
+-------------------------------+----------------------+----------------------+
@jgkamat

This comment has been minimized.

Copy link
Member

@jgkamat jgkamat commented Oct 13, 2017

Some people who have the same issue as you seem to recently found a workaround (I'm not sure why it helps, but it's worth a shot): #2554

@dllu

This comment has been minimized.

Copy link

@dllu dllu commented Oct 13, 2017

oh, that works, thanks!

@jgkamat

This comment has been minimized.

Copy link
Member

@jgkamat jgkamat commented Oct 13, 2017

I have a nvidia card as well (and I think everyone else has this problem as well), but I have the LTS nvidia driver. Perhaps a recent driver change caused this to break somehow? I'm not sure why it would be a difference.

In any case, perhaps we should add that import to the next release as a quirk?

@The-Compiler

This comment has been minimized.

Copy link
Member

@The-Compiler The-Compiler commented Oct 13, 2017

qutebrowser did have that workaround until v1.0.0, but it was replaced by a simpler one which apparently doesn't seem to work for all people...?

@daniel-lawrence-lu @aramiscd @kimat If you remove that import again, and do this at the exact same place, does that help in any way?

import ctypes
import ctypes.util
ctypes.CDLL(ctypes.util.find_library("GL"), mode=ctypes.RTLD_GLOBAL)
@The-Compiler The-Compiler changed the title shader error - black window QOpenGLShaderProgram shader errors - black window Oct 13, 2017
@kimat

This comment has been minimized.

Copy link
Contributor

@kimat kimat commented Oct 14, 2017

@The-Compiler, yes that fixes it for me. I could also .venv/bin/pip3 uninstall pyopengl

The-Compiler added a commit that referenced this issue Oct 14, 2017
We need to do it before utils.opengl_vendor(), and it fits better there anyway.
This was a regression in v1.0.

See #2554, #3106
@The-Compiler

This comment has been minimized.

Copy link
Member

@The-Compiler The-Compiler commented Oct 14, 2017

Can you please try the latest master branch, without any modifications?

@kimat

This comment has been minimized.

Copy link
Contributor

@kimat kimat commented Oct 14, 2017

master works fine

@The-Compiler

This comment has been minimized.

Copy link
Member

@The-Compiler The-Compiler commented Oct 14, 2017

Pushed to the v1.0.x branch as well - I'll release v1.0.2 once a few other bugs are fixed.

@The-Compiler

This comment has been minimized.

Copy link
Member

@The-Compiler The-Compiler commented Oct 14, 2017

Can others here please test the current master as well? v1.0.2 is ready otherwise, but this issue seems to show up slightly different for various people

@nwpuhq

This comment has been minimized.

Copy link

@nwpuhq nwpuhq commented Nov 9, 2018

Some people who have the same issue as you seem to recently found a workaround (I'm not sure why it helps, but it's worth a shot): #2554

Thanks,solved the problem as you said!!!!

@The-Compiler

This comment has been minimized.

Copy link
Member

@The-Compiler The-Compiler commented Nov 9, 2018

@nwpuhq What exactly did? qutebrowser should already have a workaround for this built-in since quite some while, so if that doesn't work for you, that'd be useful to know.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
6 participants
You can’t perform that action at this time.