GhostNaN / mpvpaper

A video wallpaper program for wlroots based wayland compositors.
GNU General Public License v3.0
713 stars 21 forks source link

Nvidia blackscreen/window and not background #70

Closed Rodrigo-Matuz closed 3 months ago

Rodrigo-Matuz commented 3 months ago

hyprland + wayland + Nvidia-dkms (1050 Ti) + arch (btw)

I already tried the f65700a branch but then I get the video displayed as window

(which I did tried hyprwinwrap) plugin to get the window and set as background but not working: I've set an issue there too

for the main branch I get black screen some commands I tried image

Logs: image output.txt

Note: I'm wondering if a animated waifu wallpaper is worth this much effort lol

GhostNaN commented 3 months ago

I already tried the f65700a branch but then I get the video displayed as window

Yes, thanks to the mpv 0.38 update it made "libmpv" not the default VO which was fixed here: https://github.com/GhostNaN/mpvpaper/commit/8fe75d88505b0fd857f8efea3750586ae5ffc096 And that old commit is starting to rot because of that.

For now you could use that old commit but just set the VO manually to "libmpv" like so: mpvpaper -o "--vo=libmpv" HDMI-A-1 ~/Pictures/wallpaper.mp4

But I must admit it's getting a bit silly with the workarounds here. I'll consider adding back the old render loop as an option.

for the main branch I get black screen OpenGL error INVALID_OPERATION.

Yep, same old Nvidia proprietary driver issue. I don't have a Nvidia GPU to properly dive into making a fix. As for the OpenGL error, I don't know what is going on there. I tried looking into it here: https://github.com/GhostNaN/mpvpaper/issues/54

( I did tried hyprwinwrap) plugin to get the window and set as background but not working: I've set an issue there too

I would close that issue there, as it's not their fault.

Last thing, I have a little theory I would like you to try for me. The problems arose when the EGL initalization was changed here: https://github.com/GhostNaN/mpvpaper/commit/0475df808f302c11c2d69ad1bd32fd2acb9cf2cf But I found the issue to be the eglMakeCurrent(egl_display, EGL_NO_SURFACE, EGL_NO_SURFACE, egl_context) That was fixed by adding glDrawBuffer(GL_BACK) afterward. So, I'm wondering if this problem is just with the EGL init or it's the actual render loop as well. Please try this patch version of the old commit that broke Nvidia pro support: old_mpvpaper.zip

And let me know what happens. Thanks.

Rodrigo-Matuz commented 3 months ago

Removed mpvpaper and mpvpaper-holder from binaries manually just in case

build the old_mpvpaper.zip project with, output here: output.txt meson setup build --prefix=/user/local & ninja -C build image

Rodrigo-Matuz commented 3 months ago

as for your suggestion, it works perfectly image

GhostNaN commented 3 months ago

Wait. So the "old_mpvpaper.zip" worked?

Rodrigo-Matuz commented 3 months ago

Wait. So the "old_mpvpaper.zip" worked?

No, the old_mpvpaper.zip is above

what worked for me was your comment reffering to that branch https://github.com/GhostNaN/mpvpaper/commit/f65700a3ecc9ecd8ca501e18a807ee18845f9441

For now you could use that old commit but just set the VO manually to "libmpv" like so: mpvpaper -o "--vo=libmpv" HDMI-A-1 ~/Pictures/wallpaper.mp4

GhostNaN commented 3 months ago

No, the old_mpvpaper.zip is above

Yes, yes, It's a window because you forgot the --vo=libmpv try again please.

Rodrigo-Matuz commented 3 months ago

Still black screen, heres the log: output.txt

image

GhostNaN commented 3 months ago

Dammit, so close... I hate this black box crap.

I appreciate the effort.

Rodrigo-Matuz commented 3 months ago

Dammit, so close... I hate this black box crap.

I appreciate the effort.

All good, let me know if I can help in testing, don't mind at all :D

Thanks to you I can now have my animated waifu on my desktop.

GhostNaN commented 3 months ago

By some miracle I remembered I had an old work laptop that has a crappy "Quadro P1000". And after countless wasted hours with the Nvidia pro driver, I was able to find some fixes.

Please try the latest commits and compile from master. Then let me know if I can finally rest this issue.

Rodrigo-Matuz commented 3 months ago

It works! output.txt

image

GhostNaN commented 3 months ago

After 2 years it's finally over... I'll let the others know.

GhostNaN commented 3 months ago

Wait. It seems it's still getting stuck. I see a bunch of "mpv_render_context_render() not being called or stuck." errors. Make sure it's running smoothly.

Rodrigo-Matuz commented 3 months ago

GPU usage around the same with some stuttering but not that much

https://youtu.be/8MOzcef-aa8

GhostNaN commented 3 months ago

GPU usage around the same with some stuttering but not that much

No, it's a real issue. I was able to replicate it by speeding up the video. I found a workaround for this issue, but it's more of a hack than a proper fix. I'll let you know if I need more help.

GhostNaN commented 3 months ago

Go ahead and try again. It should be flawless.

Rodrigo-Matuz commented 3 months ago

Awesome, no stuttering for sure. output.txt