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

Failed to create GBM buffer of size 3440x1440: Invalid argument #22

Open
Hisayoo opened this issue Jul 10, 2024 · 5 comments
Open

Failed to create GBM buffer of size 3440x1440: Invalid argument #22

Hisayoo opened this issue Jul 10, 2024 · 5 comments

Comments

@Hisayoo
Copy link

Hisayoo commented Jul 10, 2024

When I try to run hudkit it gives me the error: Failed to create GBM buffer of size 3440x1440: Invalid argument and doesn't display anything. The rest of the log is just this:

CONSOLE LOG [
  {
    "name": "DP-0",
    "x": 0,
    "y": 0,
    "width": 3440,
    "height": 1440
  }
]

I am on Arch/KDE/X11

@Symulation12
Copy link

Ran into this same issue today. After looking into it for a bit, I found this reddit comment.
Setting the env variable before running the program fixed it for me: WEBKIT_DISABLE_DMABUF_RENDERER=1 ./example/run.sh

@Hisayoo
Copy link
Author

Hisayoo commented Jul 15, 2024

Ran into this same issue today. After looking into it for a bit, I found this reddit comment. Setting the env variable before running the program fixed it for me: WEBKIT_DISABLE_DMABUF_RENDERER=1 ./example/run.sh

Thank you! It works now with no errors, but for some reason it doesn't show the overlay. When I use --inspect it shows the inspect window but the blue screen that is supposed to appear like in the readme doesn't. Would you know a fix for that?

@Symulation12
Copy link

I'm not sure about that one, I didn't run into that problem. I'm also using Arch and X11, but I'm using Cinnamon. I definitely wouldn't consider myself knowledgeable on the subject, but it could have something to do with how the different DEs handle compositing. If the inspect window is appearing, that would imply that the engine is loading, so it would make sense for the issue to be in displaying it. You could try testing different kde settings relating to the compositor.

@wjoe
Copy link

wjoe commented Oct 26, 2024

Can confirm the same issue. Similarly I got that error, and the suggested env var did get rid of the error, but still nothing was displayed.

This occurs in KDE/Plasma on X11 on Arch, but on the same system it works for me in Plasma on Wayland, or Cinnamon on X. I wasn't able to find any settings within Plasma that helped, though I didn't dig too deep so far.

@Ennea
Copy link

Ennea commented Nov 22, 2024

Looking for a solution to nothing showing up, I've stumbled upon a fork of hudkit that had added a sleep right before the call to gtk_main(), with a long explanation on why that exists and what alternatives have been tried. I gave this a quick whirl, and it appears to be working:

diff --git a/main.c b/main.c
index f2ed21e..8a5bd88 100644
--- a/main.c
+++ b/main.c
@@ -885,6 +885,8 @@ next:
                 WEBKIT_USER_SCRIPT_INJECT_AT_DOCUMENT_START,
                 NULL, NULL));
 
+    sleep(2);
+
     // Start main UI loop
     gtk_main();
     return 0;

Here's the fork and the comment in question: https://github.com/valarnin/hudkit/blob/master/webkit/main.c#L126

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants