Skip to content
Discussion options

You must be logged in to vote

Well, there catch - you cannot run window in any different than main thread. But you can run context on different thread. In WindowOptions you need to specify flag IsContextControlDisabled as true. Then, when Load event is triggered, you create new thread in it and inside new thread create context. Then call glMakeCurrent, and do default renderloop afterwards. But do not forget to glSwapBuffers inside that custom render loop! And do anything related to OpenGL only and only inside that thread. And switch back to main, to do anything to glfw window.

So, from my perspective in kinda pointless?

Replies: 1 comment 4 replies

Comment options

You must be logged in to vote
4 replies
@ArtjomP
Comment options

@ArtjomP
Comment options

@poglad-ds
Comment options

@ArtjomP
Comment options

Answer selected by ArtjomP
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants