• prettydarknwild@lemmy.worldOP
    link
    fedilink
    arrow-up
    1
    ·
    9 months ago

    It also throws an error code: 65543, i didnt add it because i thought it was an error in my code that i wasnt able to see, im sorry, anyway, do you need more info about my system?

    • NikkiNikkiNikki@kbin.social
      link
      fedilink
      arrow-up
      2
      ·
      edit-2
      9 months ago

      Try doing what e0qdk suggests in this comment as it seems to be an issue with how GLFW creates windows in wayland. You’re technically creating an eGL window through it and the profile version is different (egl2 is opengl4.x compatible while egl1 is opengl 3.x compatible I think?), so just remove the window calls to glfwWindowHint and see what version it tries to use by default

      • prettydarknwild@lemmy.worldOP
        link
        fedilink
        arrow-up
        1
        ·
        9 months ago

        i commented all the calls to glfwWindowHint, and now it just exits inmediately with code 0, so i think it is working, although it doesnt create any window either, there is a way to see which version is using by default?

    • e0qdk@kbin.social
      link
      fedilink
      arrow-up
      2
      ·
      edit-2
      9 months ago

      65543 seems to be the constant defined for GLFW_VERSION_UNAVAILABLE passed back from the error handling code I was looking at in egl_context.c – that helps confirm I’m looking at the right chunk of code in GLFW’s guts, thanks.

      As I suggested in my other comment, try commenting out the hint lines and see if a window shows up at all. (Your program doesn’t do anything other than quit after making the window, so it should just flash a window briefly, I’d expect.)

        • NikkiNikkiNikki@kbin.social
          link
          fedilink
          arrow-up
          2
          ·
          9 months ago

          That’s because you need to run an event loop, your window is being created successfully, but your program immediately exits after the fact because the line directly after glfwCreateWindow is return EXIT_SUCCESS. You’re probably good to follow the rest of the tutorial now