GLBasic forum

Codesnippets => Inline / 3rd party => Topic started by: Schranz0r on 2020-May-02

Title: GLFW 3.3.2 wrapper start
Post by: Schranz0r on 2020-May-02
Hi my friends,

here is the start of a GLFW 3.3.2 Wrapper for GLBasic, maybe someone need it?!

!!!: Make sure to set the Path right in PROJECTS -> OPTIONS -> INK:
Code: (glbasic) [Select]
-L "PATH_TO_\lib-mingw" -lglfw3 -lgdi32 -lopengl32
Example:
Code: (glbasic) [Select]
-L "F:\Programmierung\GLBasic\GLFW_Bindings\lib-mingw" -lglfw3 -lgdi32 -lopengl32

Example Code in GLBasic:

Code: (glbasic) [Select]
glfwInit()


LOCAL win = glfwCreateWindow(800,600,"MyWindow!")

glfwMakeContextCurrent(win)



WHILE NOT glfwWindowShouldClose(win)



glfwSwapBuffers(win)
glfwPollEvents()
WEND

glfwTerminate()
END

Happy coding :)
Title: Re: GLFW 3.3.2 wrapper start
Post by: bigsofty on 2020-May-02
Wow, very cool, thanks Schranz0r!

I enjoy messing around with other APIs in GLB, this should be interesting.  :booze:
Title: Re: GLFW 3.3.2 wrapper start
Post by: dreamerman on 2020-May-03
Nice, was there any glfw wrapper/include examaple or only straight OpenGL stuff?
btw. You are on some quest? First SDL2 now GLFW, what's next? ;) Vulcan/Metal :D
Title: Re: GLFW 3.3.2 wrapper start
Post by: Schranz0r on 2020-May-03
Raylib 3.0 at the moment ^^
Already linked it static, it's Crossplatform-Ready :)
Title: Re: GLFW 3.3.2 wrapper start
Post by: bigsofty on 2020-May-04
Ooh, Raylib + GLB could be the perfect match!
Title: Re: GLFW 3.3.2 wrapper start
Post by: Schranz0r on 2020-Jun-06
Had not much time lately, to bring it further...