danielfvm / shadow

A live and interactive wallpaper "engine" for Linux and Windows. It supports mixing various formats like glsl-shaders, images, videos and GIFs to create an amazing wallpaper. Additionally you can expand it's functionality with scripts.
GNU General Public License v3.0
54 stars 7 forks source link

error on ubuntu #28

Open zty2004 opened 7 months ago

zty2004 commented 7 months ago

I type

$ poetry run shadow /media/fztym/E/screen/sunflowergirl.mp4 -m background

and then the terminal returns

DEBUG:shadow.shadow:requiring modern OpenGL without any legacy features
DEBUG:shadow.shadow:creating window
DEBUG:shadow.shadow:making created window opengl context
/home/fztym/.cache/pypoetry/virtualenvs/shadow_engine-PLsjlACQ-py3.10/lib/python3.10/site-packages/glfw/__init__.py:916: GLFWError: (65544) b'Wayland: Window position setting not supported'
  warnings.warn(message, GLFWError)
DEBUG:shadow.shadow:creating and binding the vertex array (VAO)
DEBUG:shadow.shadow:creating and binding the vertex buffer (VBO)
DEBUG:shadow.shadow:setting the vertex attributes
DEBUG:shadow.shadow:creating framebuffers
DEBUG:shadow.shadow:loading shaders and locations
DEBUG:shadow.shader:creating the shader program
DEBUG:shadow.shader:compiling the GL_VERTEX_SHADER (GL_VERTEX_SHADER) shader
DEBUG:shadow.shader:compiling the GL_FRAGMENT_SHADER (GL_FRAGMENT_SHADER) shader
DEBUG:shadow.shader:linking shader program
DEBUG:shadow.shader:installing shader program into rendering state
DEBUG:shadow.shadow:initializing components
DEBUG:shadow.shader:creating the shader program
DEBUG:shadow.shader:compiling the GL_VERTEX_SHADER (GL_VERTEX_SHADER) shader
DEBUG:shadow.shader:compiling the GL_FRAGMENT_SHADER (GL_FRAGMENT_SHADER) shader
DEBUG:shadow.shader:linking shader program
DEBUG:shadow.shader:installing shader program into rendering state
Traceback (most recent call last):
  File "<string>", line 1, in <module>
  File "/home/fztym/shadow/shadow/main.py", line 86, in main
    show = ShadowBackground(monitor, files)
  File "/home/fztym/shadow/shadow/shadow.py", line 240, in __init__
    set_window_to_background(conn, glfw.get_x11_window(self.window))
AttributeError: module 'glfw' has no attribute 'get_x11_window'
DEBUG:shadow.shadow:cleaning up components
DEBUG:shadow.shader:cleaning up shader program
DEBUG:shadow.shadow:cleaning up vertex buffer
DEBUG:shadow.shadow:cleaning up vertex array
DEBUG:shadow.shadow:deleting framebuffer and texture
DEBUG:shadow.shadow:closing glfw
Segmentation fault (core dumped)
danielfvm commented 7 months ago

Yes I can replicate the error. This seams to be a problem with Wayland. Either use x11 or try running the program with this env variable:

$ PYOPENGL_PLATFORM="glx" poetry run shadow /media/fztym/E/screen/sunflowergirl.mp4 -m background